PCI: build Broadcom PAXC quirks unconditionally
PATCH 1/1 PCI: build Broadcom PAXC quirks unconditionally
CONFIG_PCIE_IPROC_PLATFORM only gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.
---
Alternatively, we can change the condition to:
#ifdef CONFIG_PCIE_IPROC_PLATFORM || CONFIG_PCIE_IPROC_PLATFORM_MODULE
.
I chose to remove the ifdef because that's what other quirks looked like in this file.
--- drivers/pci/quirks.c | 2 -- 1 file changed, 2 deletions(-)
drivers/pci/quirks.c +0 -2
@@ -2381,7 +2381,6 @@ DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_BROADCOM,PCI_DEVICE_ID_TIGON3_5719 , quirk_brcm_5719_limit_mrrs); -#ifdef CONFIG_PCIE_IPROC_PLATFORM static void quirk_paxc_bridge (struct pci_dev *pdev) {/*
@@ -2405,7 +2404,6 @@ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd750 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd802 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd804 , quirk_paxc_bridge); -#endif /* * Originally in EDAC sources for i82875P: Intel tells BIOS developers to
Signature · 1 line
2.24.0
Quoted 5 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>
Quoted 8 lines
---
Alternatively, we can change the condition to:#ifdef
CONFIG_PCIE_IPROC_PLATFORM||CONFIG_PCIE_IPROC_PLATFORM_MODULE
.I chose to remove the ifdef because that's what other quirks looked like in this file.
Bjorn and Ray, any comment on this trivial patch?
Wei.
Quoted 12 lines · Wei Liu
Quoted 11 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>---
Alternatively, we can change the condition to:#ifdef CONFIG_PCIE_IPROC_PLATFORM || CONFIG_PCIE_IPROC_PLATFORM_MODULE.
Quoted 7 lines
Quoted 2 lines
I chose to remove the ifdef because that's what other quirks looked like in this file.
Bjorn and Ray, any comment on this trivial patch?
Wei.
I just reviewed it and it looks good to me. Thanks!
Ray
Hi Wei,
Quoted 30 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>---
Alternatively, we can change the condition to:#ifdef CONFIG_PCIE_IPROC_PLATFORM || CONFIG_PCIE_IPROC_PLATFORM_MODULE.
I chose to remove the ifdef because that's what other quirks looked like in this file.
--- drivers/pci/quirks.c | 2 -- 1 file changed, 2 deletions(-)drivers/pci/quirks.c +0
-1@@ -2381,7 +2381,6 @@ DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_BROADCOM,PCI_DEVICE_ID_TIGON3_5719 , quirk_brcm_5719_limit_mrrs); -#ifdef CONFIG_PCIE_IPROC_PLATFORM static void quirk_paxc_bridge (struct pci_dev *pdev) {/*
drivers/pci/quirks.c DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge); · line 2409
Quoted 7 lines
drivers/pci/quirks.c +0
-1@@ -2405,7 +2404,6 @@ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd750 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd802 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd804 , quirk_paxc_bridge); -#endif /* * Originally in EDAC sources for i82875P: Intel tells BIOS developers to
The change looks good to me. Thanks!
Quoted 4 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>
Sorry, I missed this thinking it would be under drivers/pci/controller and hence handled by Lorenzo.
So I guess this doesn't fix a build problem, but without this patch, we just don't run the quirk if the driver is a module, right?
Quoted 34 lines
---
Alternatively, we can change the condition to:#ifdef CONFIG_PCIE_IPROC_PLATFORM || CONFIG_PCIE_IPROC_PLATFORM_MODULEI chose to remove the ifdef because that's what other quirks looked like in this file.
--- drivers/pci/quirks.c | 2 -- 1 file changed, 2 deletions(-)drivers/pci/quirks.c +0
-2@@ -2381,7 +2381,6 @@ DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_BROADCOM,PCI_DEVICE_ID_TIGON3_5719 , quirk_brcm_5719_limit_mrrs); -#ifdef CONFIG_PCIE_IPROC_PLATFORM static void quirk_paxc_bridge (struct pci_dev *pdev) {/* @@ -2405,7 +2404,6 @@ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd750 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd802 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd804 , quirk_paxc_bridge); -#endif /* * Originally in EDAC sources for i82875P: Intel tells BIOS developers to Signature · 1 line
2.24.0
Quoted 5 lines · Bjorn Helgaas
Quoted 3 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.
Quoted 8 lines
Quoted 1 line
Signed-off-by Wei Liu <[email protected]>Sorry, I missed this thinking it would be under
drivers/pci/controllerand hence handled by Lorenzo.So I guess this doesn't fix a build problem, but without this patch, we just don't run the quirk if the driver is a module, right?
Yes, this is correct.
Without this patch, the quirk doesn't get to run if the driver is a module.
Wei.
Quoted 12 lines · Wei Liu
Quoted 10 lines · Bjorn Helgaas
Quoted 4 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>Sorry, I missed this thinking it would be under
drivers/pci/controllerand hence handled by Lorenzo.
Quoted 8 lines
Quoted 3 lines
So I guess this doesn't fix a build problem, but without this patch, we just don't run the quirk if the driver is a module, right?
Yes, this is correct.
Without this patch, the quirk doesn't get to run if the driver is a module.
Hi Bjorn
Are you satisfied with the patch? What do I need to do to get it merged?
Thanks,
Wei.
Quoted 13 lines · Wei Liu
Quoted 12 lines · Wei Liu
Quoted 10 lines · Bjorn Helgaas
Quoted 4 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>Sorry, I missed this thinking it would be under
drivers/pci/controllerand hence handled by Lorenzo.
Quoted 8 lines
Quoted 6 lines
Quoted 2 lines
So I guess this doesn't fix a build problem, but without this patch, we just don't run the quirk if the driver is a module, right?
Yes, this is correct.
Without this patch, the quirk doesn't get to run if the driver is a module.
Are you satisfied with the patch? What do I need to do to get it merged?
You needn't do anything. I'll clarify the changelog (the patch doesn't actually *enable* building the driver as a module; it merely ensures that we include the quirk in that case).
This is too late for v5.5, so it will get merged for v5.6 unless the modular driver itself was enabled for v5.5.
Bjorn
Quoted 22 lines · Bjorn Helgaas
Quoted 20 lines · Wei Liu
Quoted 18 lines · Wei Liu
Quoted 5 lines · Bjorn Helgaas
Quoted 3 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Quoted 7 lines
Quoted 1 line
Signed-off-by Wei Liu <[email protected]>Sorry, I missed this thinking it would be under
drivers/pci/controllerand hence handled by Lorenzo.So I guess this doesn't fix a build problem, but without this patch, we just don't run the quirk if the driver is a module, right?
Yes, this is correct.
Without this patch, the quirk doesn't get to run if the driver is a module.
Quoted 9 lines
Quoted 1 line
Are you satisfied with the patch? What do I need to do to get it merged?
You needn't do anything. I'll clarify the changelog (the patch doesn't actually *enable* building the driver as a module; it merely ensures that we include the quirk in that case).
This is too late for v5.5, so it will get merged for v5.6 unless the modular driver itself was enabled for v5.5.
OK. Thanks for the clarification.
Wei.
Quoted 1 line
Bjorn
Quoted 29 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>---
Alternatively, we can change the condition to:#ifdef
CONFIG_PCIE_IPROC_PLATFORM||CONFIG_PCIE_IPROC_PLATFORM_MODULE
.I chose to remove the ifdef because that's what other quirks looked like in this file.
--- drivers/pci/quirks.c | 2 -- 1 file changed, 2 deletions(-)drivers/pci/quirks.c +0
-1@@ -2381,7 +2381,6 @@ DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_BROADCOM,PCI_DEVICE_ID_TIGON3_5719 , quirk_brcm_5719_limit_mrrs); -#ifdef CONFIG_PCIE_IPROC_PLATFORM static void quirk_paxc_bridge (struct pci_dev *pdev) {/*
drivers/pci/quirks.c DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge); · line 2408
Quoted 4 lines
drivers/pci/quirks.c +0
-1@@ -2405,7 +2404,6 @@ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd750 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd802 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd804 , quirk_paxc_bridge); -#endif
Is there a reason this quirk can't be moved to drivers/pci/controller/pcie-iproc-platform.c? That would make it much less subtle because it would be compiled if and only if the driver itself is compiled.
If it needs to be here in quirks.c, please include a note about the reason.
Quoted 5 lines
drivers/pci/quirks.c +0
-0/* * Originally in EDAC sources for i82875P: Intel tells BIOS developers to Signature · 1 line
2.24.0
Quoted 40 lines · Bjorn Helgaas
Quoted 29 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>---
Alternatively, we can change the condition to:#ifdef CONFIG_PCIE_IPROC_PLATFORM || CONFIG_PCIE_IPROC_PLATFORM_MODULE.
I chose to remove the ifdef because that's what other quirks looked like in this file.
--- drivers/pci/quirks.c | 2 -- 1 file changed, 2 deletions(-)drivers/pci/quirks.c +0
-1@@ -2381,7 +2381,6 @@ DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_BROADCOM,PCI_DEVICE_ID_TIGON3_5719 , quirk_brcm_5719_limit_mrrs); -#ifdef CONFIG_PCIE_IPROC_PLATFORM static void quirk_paxc_bridge (struct pci_dev *pdev) {/* drivers/pci/quirks.c DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge); · line 2408
Quoted 4 lines
drivers/pci/quirks.c +0
-1@@ -2405,7 +2404,6 @@ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd750 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd802 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd804 , quirk_paxc_bridge); -#endif Is there a reason this quirk can't be moved to
drivers/pci/controller/pcie-iproc-platform.c? That would make it much less subtle because it would be compiled if and only if the driver itself is compiled.
Quoted 3 lines
If it needs to be here in
quirks.c, please include a note about the reason.
There's no particular reason and yes it could be moved to pcie-iproc.c.
If that's preferred (and it sounds like it is) then we can do that.
Thanks,
Ray
Quoted 5 lines
Quoted 5 lines
drivers/pci/quirks.c +0
-0/* * Originally in EDAC sources for i82875P: Intel tells BIOS developers to Signature · 1 line
2.24.0
Quoted 42 lines · Ray Jui
Quoted 39 lines · Bjorn Helgaas
Quoted 28 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>---
Alternatively, we can change the condition to:#ifdef CONFIG_PCIE_IPROC_PLATFORM || CONFIG_PCIE_IPROC_PLATFORM_MODULE.
I chose to remove the ifdef because that's what other quirks looked like in this file.
--- drivers/pci/quirks.c | 2 -- 1 file changed, 2 deletions(-)drivers/pci/quirks.c +0
-1@@ -2381,7 +2381,6 @@ DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_BROADCOM,PCI_DEVICE_ID_TIGON3_5719 , quirk_brcm_5719_limit_mrrs); -#ifdef CONFIG_PCIE_IPROC_PLATFORM static void quirk_paxc_bridge (struct pci_dev *pdev) {/* drivers/pci/quirks.c DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge); · line 2408
Quoted 4 lines
drivers/pci/quirks.c +0
-1@@ -2405,7 +2404,6 @@ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd750 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd802 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd804 , quirk_paxc_bridge); -#endif Is there a reason this quirk can't be moved to
drivers/pci/controller/pcie-iproc-platform.c? That would make it much less subtle because it would be compiled if and only if the driver itself is compiled.
Quoted 6 lines
Quoted 2 lines
If it needs to be here in
quirks.c, please include a note about the reason.There's no particular reason and yes it could be moved to
pcie-iproc.c.If that's preferred (and it sounds like it is) then we can do that.
Yes, please, that would be great! No #ifdefs, plus the code won't be compiled into x86 and other arches that never use that driver.
Bjorn
Quoted 46 lines · Bjorn Helgaas
Quoted 45 lines · Ray Jui
Quoted 41 lines · Bjorn Helgaas
Quoted 28 lines · Wei Liu
CONFIG_PCIE_IPROC_PLATFORMonly gets defined when the driver is built in. Removing the ifdef will allow us to build the driver as a module.Signed-off-by Wei Liu <[email protected]>---
Alternatively, we can change the condition to:#ifdef CONFIG_PCIE_IPROC_PLATFORM || CONFIG_PCIE_IPROC_PLATFORM_MODULE.
I chose to remove the ifdef because that's what other quirks looked like in this file.
--- drivers/pci/quirks.c | 2 -- 1 file changed, 2 deletions(-)drivers/pci/quirks.c +0
-1@@ -2381,7 +2381,6 @@ DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_BROADCOM,PCI_DEVICE_ID_TIGON3_5719 , quirk_brcm_5719_limit_mrrs); -#ifdef CONFIG_PCIE_IPROC_PLATFORM static void quirk_paxc_bridge (struct pci_dev *pdev) {/* drivers/pci/quirks.c DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge); · line 2408
Quoted 4 lines
drivers/pci/quirks.c +0
-1@@ -2405,7 +2404,6 @@ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_BROADCOM, 0x16f0, quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd750 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd802 , quirk_paxc_bridge);DECLARE_PCI_FIXUP_EARLY (PCI_VENDOR_ID_BROADCOM ,0xd804 , quirk_paxc_bridge); -#endif Is there a reason this quirk can't be moved to
drivers/pci/controller/pcie-iproc-platform.c? That would make it much less subtle because it would be compiled if and only if the driver itself is compiled.If it needs to be here in
quirks.c, please include a note about the reason.
Quoted 9 lines
Quoted 3 lines
There's no particular reason and yes it could be moved to
pcie-iproc.c.If that's preferred (and it sounds like it is) then we can do that.
Yes, please, that would be great! No #ifdefs, plus the code won't be compiled into x86 and other arches that never use that driver.
Bjorn
Okay, Wei, let me know if you'd like to help with that? If not, I can make the change.
Thanks,
Ray