diff options
author | Sam Ravnborg <sam@ravnborg.org> | 2008-04-29 16:38:48 -0400 |
---|---|---|
committer | Jesse Barnes <jbarnes@hobbes.lan> | 2008-04-29 16:41:59 -0400 |
commit | 98db6f193c93e9b4729215af2c9101210e11d26c (patch) | |
tree | 942e41010b70ae79897921aa13e16f372f4ea2e1 /include | |
parent | 7663c1e2792a9662b23dec6e19bfcd3d55360b8f (diff) |
x86: fix section mismatch in pci_scan_bus
Fix following section mismatch warning:
WARNING: vmlinux.o(.text+0x275616): Section mismatch in reference from the function pci_scan_bus() to the function .devinit.text:pci_scan_bus_parented()
The warning was seen with a CONFIG_DEBUG_SECTION_MISMATCH=y build.
The inline function pci_scan_bus refer to functions annotated
__devinit - so annotate it __devinit too.
This revealed a few x86 specific functions that were only
used from __init or __devinit context.
So annotate these __devinit and the warning was killed.
The added include in pci.h was not strictly required but
added to avoid being dependent on indirect includes.
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Jesse Barnes <jbarnes@hobbes.lan>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/pci.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/pci.h b/include/linux/pci.h index 96acd0dae241..a59517b4930f 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -44,6 +44,7 @@ | |||
44 | #include <linux/mod_devicetable.h> | 44 | #include <linux/mod_devicetable.h> |
45 | 45 | ||
46 | #include <linux/types.h> | 46 | #include <linux/types.h> |
47 | #include <linux/init.h> | ||
47 | #include <linux/ioport.h> | 48 | #include <linux/ioport.h> |
48 | #include <linux/list.h> | 49 | #include <linux/list.h> |
49 | #include <linux/compiler.h> | 50 | #include <linux/compiler.h> |
@@ -474,7 +475,7 @@ extern struct pci_bus *pci_find_bus(int domain, int busnr); | |||
474 | void pci_bus_add_devices(struct pci_bus *bus); | 475 | void pci_bus_add_devices(struct pci_bus *bus); |
475 | struct pci_bus *pci_scan_bus_parented(struct device *parent, int bus, | 476 | struct pci_bus *pci_scan_bus_parented(struct device *parent, int bus, |
476 | struct pci_ops *ops, void *sysdata); | 477 | struct pci_ops *ops, void *sysdata); |
477 | static inline struct pci_bus *pci_scan_bus(int bus, struct pci_ops *ops, | 478 | static inline struct pci_bus * __devinit pci_scan_bus(int bus, struct pci_ops *ops, |
478 | void *sysdata) | 479 | void *sysdata) |
479 | { | 480 | { |
480 | struct pci_bus *root_bus; | 481 | struct pci_bus *root_bus; |