All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kai-Heng Feng <kai.heng.feng@canonical.com>
To: bhelgaas@google.com
Cc: Kai-Heng Feng <kai.heng.feng@canonical.com>,
	kernel test robot <lkp@intel.com>,
	linux-pci@vger.kernel.org (open list:PCI SUBSYSTEM),
	linux-kernel@vger.kernel.org (open list)
Subject: [PATCH] PCI: Add const type for comparison function parameter
Date: Sat, 29 May 2021 01:02:42 +0800	[thread overview]
Message-ID: <20210528170242.1564038-1-kai.heng.feng@canonical.com> (raw)

Commit 4f0f586bf0c8 ("treewide: Change list_sort to use const pointers")
added const on parameter "struct list_head *".

So add const to match the type.

Fixes: 276b15de5287 ("PCI: Coalesce host bridge contiguous apertures")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
---
 drivers/pci/probe.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index bf58e5dd1d82..bd862b612633 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -875,7 +875,8 @@ static void pci_set_bus_msi_domain(struct pci_bus *bus)
 	dev_set_msi_domain(&bus->dev, d);
 }
 
-static int res_cmp(void *priv, struct list_head *a, struct list_head *b)
+static int res_cmp(void *priv, const struct list_head *a,
+		   const struct list_head *b)
 {
 	struct resource_entry *entry1, *entry2;
 
-- 
2.31.1


             reply	other threads:[~2021-05-28 17:03 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-28 17:02 Kai-Heng Feng [this message]
2021-05-28 19:19 ` [PATCH] PCI: Add const type for comparison function parameter Bjorn Helgaas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210528170242.1564038-1-kai.heng.feng@canonical.com \
    --to=kai.heng.feng@canonical.com \
    --cc=bhelgaas@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lkp@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.