* [PATCH 1/1] PCI: Use PCI_STD_NUM_BARS instead of 6
@ 2025-04-16 10:02 Ilpo Järvinen
2025-04-16 10:11 ` Niklas Cassel
2025-04-16 18:23 ` Bjorn Helgaas
0 siblings, 2 replies; 3+ messages in thread
From: Ilpo Järvinen @ 2025-04-16 10:02 UTC (permalink / raw)
To: Bjorn Helgaas, linux-pci, linux-kernel; +Cc: Ilpo Järvinen
pci_read_bases() is given literal 6 that means PCI_STD_NUM_BARS.
Replace the literal with the define to annotate the code better.
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
---
drivers/pci/probe.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index 364fa2a514f8..08971fca0819 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -2058,7 +2058,7 @@ int pci_setup_device(struct pci_dev *dev)
if (class == PCI_CLASS_BRIDGE_PCI)
goto bad;
pci_read_irq(dev);
- pci_read_bases(dev, 6, PCI_ROM_ADDRESS);
+ pci_read_bases(dev, PCI_STD_NUM_BARS, PCI_ROM_ADDRESS);
pci_subsystem_ids(dev, &dev->subsystem_vendor, &dev->subsystem_device);
base-commit: 0af2f6be1b4281385b618cb86ad946eded089ac8
--
2.39.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/1] PCI: Use PCI_STD_NUM_BARS instead of 6
2025-04-16 10:02 [PATCH 1/1] PCI: Use PCI_STD_NUM_BARS instead of 6 Ilpo Järvinen
@ 2025-04-16 10:11 ` Niklas Cassel
2025-04-16 18:23 ` Bjorn Helgaas
1 sibling, 0 replies; 3+ messages in thread
From: Niklas Cassel @ 2025-04-16 10:11 UTC (permalink / raw)
To: Ilpo Järvinen; +Cc: Bjorn Helgaas, linux-pci, linux-kernel
On Wed, Apr 16, 2025 at 01:02:39PM +0300, Ilpo Järvinen wrote:
> pci_read_bases() is given literal 6 that means PCI_STD_NUM_BARS.
> Replace the literal with the define to annotate the code better.
>
> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
> ---
> drivers/pci/probe.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
> index 364fa2a514f8..08971fca0819 100644
> --- a/drivers/pci/probe.c
> +++ b/drivers/pci/probe.c
> @@ -2058,7 +2058,7 @@ int pci_setup_device(struct pci_dev *dev)
> if (class == PCI_CLASS_BRIDGE_PCI)
> goto bad;
> pci_read_irq(dev);
> - pci_read_bases(dev, 6, PCI_ROM_ADDRESS);
> + pci_read_bases(dev, PCI_STD_NUM_BARS, PCI_ROM_ADDRESS);
>
> pci_subsystem_ids(dev, &dev->subsystem_vendor, &dev->subsystem_device);
>
>
> base-commit: 0af2f6be1b4281385b618cb86ad946eded089ac8
> --
> 2.39.5
>
Reviewed-by: Niklas Cassel <cassel@kernel.org>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 1/1] PCI: Use PCI_STD_NUM_BARS instead of 6
2025-04-16 10:02 [PATCH 1/1] PCI: Use PCI_STD_NUM_BARS instead of 6 Ilpo Järvinen
2025-04-16 10:11 ` Niklas Cassel
@ 2025-04-16 18:23 ` Bjorn Helgaas
1 sibling, 0 replies; 3+ messages in thread
From: Bjorn Helgaas @ 2025-04-16 18:23 UTC (permalink / raw)
To: Ilpo Järvinen; +Cc: Bjorn Helgaas, linux-pci, linux-kernel
On Wed, Apr 16, 2025 at 01:02:39PM +0300, Ilpo Järvinen wrote:
> pci_read_bases() is given literal 6 that means PCI_STD_NUM_BARS.
> Replace the literal with the define to annotate the code better.
>
> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Applied to pci/enumeration for v6.16, thanks!
> ---
> drivers/pci/probe.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
> index 364fa2a514f8..08971fca0819 100644
> --- a/drivers/pci/probe.c
> +++ b/drivers/pci/probe.c
> @@ -2058,7 +2058,7 @@ int pci_setup_device(struct pci_dev *dev)
> if (class == PCI_CLASS_BRIDGE_PCI)
> goto bad;
> pci_read_irq(dev);
> - pci_read_bases(dev, 6, PCI_ROM_ADDRESS);
> + pci_read_bases(dev, PCI_STD_NUM_BARS, PCI_ROM_ADDRESS);
>
> pci_subsystem_ids(dev, &dev->subsystem_vendor, &dev->subsystem_device);
>
>
> base-commit: 0af2f6be1b4281385b618cb86ad946eded089ac8
> --
> 2.39.5
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-04-16 18:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-16 10:02 [PATCH 1/1] PCI: Use PCI_STD_NUM_BARS instead of 6 Ilpo Järvinen
2025-04-16 10:11 ` Niklas Cassel
2025-04-16 18:23 ` Bjorn Helgaas
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox