PCI: Fix compile error with DPC disabled
PATCH 1/1 PCI: Fix compile error with DPC disabled
The alternate functions when CONFIG_PCIE_DPC is not defined need to be static inline.
--- drivers/pci/pci.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/pci/pci.h +2 -2
@@ -402,8 +402,8 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info);void pci_save_dpc_state (struct pci_dev *dev);void pci_restore_dpc_state (struct pci_dev *dev);#else -void pci_save_dpc_state (struct pci_dev *dev) {} -void pci_restore_dpc_state (struct pci_dev *dev) {} +static inline void pci_save_dpc_state (struct pci_dev *dev) {} +static inline void pci_restore_dpc_state (struct pci_dev *dev) {}#endif #ifdef CONFIG_PCI_ATS
Signature · 1 line
2.14.4
Quoted 4 lines · Keith Busch
The alternate functions when
CONFIG_PCIE_DPCis not defined need to be static inline.Signed-off-by Keith Busch <[email protected]>
If you tell me which patch, I'll fold this into it so there's no bisection hole.
Quoted 22 lines
--- drivers/pci/pci.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/pci/pci.h +2
-2@@ -402,8 +402,8 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info);void pci_save_dpc_state (struct pci_dev *dev);void pci_restore_dpc_state (struct pci_dev *dev);#else -void pci_save_dpc_state (struct pci_dev *dev) {} -void pci_restore_dpc_state (struct pci_dev *dev) {} +static inline void pci_save_dpc_state (struct pci_dev *dev) {} +static inline void pci_restore_dpc_state (struct pci_dev *dev) {}#endif #ifdef CONFIG_PCI_ATS Signature · 1 line
2.14.4
Quoted 8 lines · Bjorn Helgaas
Quoted 4 lines · Keith Busch
The alternate functions when
CONFIG_PCIE_DPCis not defined need to be static inline.Signed-off-by Keith Busch <[email protected]>If you tell me which patch, I'll fold this into it so there's no bisection hole.
Thanks, I like that plan.
Quoted 22 lines
Quoted 22 lines
--- drivers/pci/pci.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/pci/pci.h +2
-2@@ -402,8 +402,8 @@ void aer_print_error(struct pci_dev *dev, struct aer_err_info *info);void pci_save_dpc_state (struct pci_dev *dev);void pci_restore_dpc_state (struct pci_dev *dev);#else -void pci_save_dpc_state (struct pci_dev *dev) {} -void pci_restore_dpc_state (struct pci_dev *dev) {} +static inline void pci_save_dpc_state (struct pci_dev *dev) {} +static inline void pci_restore_dpc_state (struct pci_dev *dev) {}#endif #ifdef CONFIG_PCI_ATS Signature · 1 line
2.14.4
Quoted 7 lines · Keith Busch
Quoted 6 lines · Bjorn Helgaas
Quoted 4 lines · Keith Busch
The alternate functions when
CONFIG_PCIE_DPCis not defined need to be static inline.Signed-off-by Keith Busch <[email protected]>
Quoted 8 lines
Quoted 2 lines
If you tell me which patch, I'll fold this into it so there's no bisection hole.
Thanks, I like that plan.
Fixes d17964c0d81fc38c7 ("PCI/DPC: Save and restore config state")
Done, sorry to bother you, I could have figured that out in 10 seconds myself from the 0-day robot email.
Quoted 11 lines · Bjorn Helgaas
Quoted 10 lines · Keith Busch
Quoted 8 lines · Bjorn Helgaas
Quoted 4 lines · Keith Busch
The alternate functions when
CONFIG_PCIE_DPCis not defined need to be static inline.Signed-off-by Keith Busch <[email protected]>If you tell me which patch, I'll fold this into it so there's no bisection hole.
Quoted 8 lines
Quoted 5 lines
Thanks, I like that plan.
Fixes d17964c0d81fc38c7 ("PCI/DPC: Save and restore config state")Done, sorry to bother you, I could have figured that out in 10 seconds myself from the 0-day robot email.
Oh, no problem at all. The breakage was my mistake, so my apologies. I don't like getting caught by 0-day, but I'm happy it's there! :)