diff options
author | Greg Kroah-Hartman <gregkh@suse.de> | 2006-02-16 16:29:37 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-02-16 16:29:37 -0800 |
commit | d2aaf89ed8bb8f0360324bfd08d3b5bca394d0ed (patch) | |
tree | bf8b98d280c89fde01da35dc59003b02164cc328 /pci | |
parent | db5a64fd2359361ffc9e4f831f2d33f4ca14fdad (diff) | |
download | patches-d2aaf89ed8bb8f0360324bfd08d3b5bca394d0ed.tar.gz |
pci patches applied
Diffstat (limited to 'pci')
-rw-r--r-- | pci/acpiphp-add-new-bus-to-acpi.patch | 153 | ||||
-rw-r--r-- | pci/pci-device-ensure-sysdata-initialised.patch | 167 | ||||
-rw-r--r-- | pci/pci-fix-the-x86-pci-domain-support-fix.patch | 39 | ||||
-rw-r--r-- | pci/pci-give-pci-config-access-initialization-a-defined-ordering.patch | 190 | ||||
-rw-r--r-- | pci/pci-hotplug-convert-semaphores-to-mutex.patch | 10 |
5 files changed, 554 insertions, 5 deletions
diff --git a/pci/acpiphp-add-new-bus-to-acpi.patch b/pci/acpiphp-add-new-bus-to-acpi.patch new file mode 100644 index 0000000000000..0dbd6d9d5ba26 --- /dev/null +++ b/pci/acpiphp-add-new-bus-to-acpi.patch @@ -0,0 +1,153 @@ +From kristenc@cs.pdx.edu Wed Feb 1 13:28:32 2006 +Date: Wed, 1 Feb 2006 13:27:43 -0800 +From: Kristen Carlson Accardi <kristen.c.accardi@intel.com> +To: pcihp-discuss@lists.sourceforge.net +Cc: greg@kroah.com, linux-kernel@vger.kernel.org, + muneda.takahiro@jp.fujitsu.com, linux-acpi@vger.kernel.org +Subject: [patch] acpiphp: add new bus to acpi +Message-ID: <20060201212743.GB27247@nerpa> +Content-Disposition: inline + +If we add a new bridge with subordinate busses, we should call make sure +that acpi is notified so that the PRT (if present) can be read and drivers +who have registered on this bus will be notified when it is started. +Also make sure to use the max reservered bus number for the starting the bus +scan. + + +Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> +--- + drivers/pci/hotplug/acpiphp_glue.c | 106 ++++++++++++++++++++++++++++++++++++- + 1 file changed, 104 insertions(+), 2 deletions(-) + +--- gregkh-2.6.orig/drivers/pci/hotplug/acpiphp_glue.c ++++ gregkh-2.6/drivers/pci/hotplug/acpiphp_glue.c +@@ -751,6 +751,101 @@ static int power_off_slot(struct acpiphp + } + + ++ ++/** ++ * acpiphp_max_busnr - return the highest reserved bus number under ++ * the given bus. ++ * @bus: bus to start search with ++ * ++ */ ++static unsigned char acpiphp_max_busnr(struct pci_bus *bus) ++{ ++ struct list_head *tmp; ++ unsigned char max, n; ++ ++ /* ++ * pci_bus_max_busnr will return the highest ++ * reserved busnr for all these children. ++ * that is equivalent to the bus->subordinate ++ * value. We don't want to use the parent's ++ * bus->subordinate value because it could have ++ * padding in it. ++ */ ++ max = bus->secondary; ++ ++ list_for_each(tmp, &bus->children) { ++ n = pci_bus_max_busnr(pci_bus_b(tmp)); ++ if (n > max) ++ max = n; ++ } ++ return max; ++} ++ ++ ++ ++/** ++ * get_func - get a pointer to acpiphp_func given a slot, device ++ * @slot: slot to search ++ * @dev: pci_dev struct to match. ++ * ++ * This function will increase the reference count of pci_dev, ++ * so callers should call pci_dev_put when complete. ++ * ++ */ ++static struct acpiphp_func * ++get_func(struct acpiphp_slot *slot, struct pci_dev *dev) ++{ ++ struct acpiphp_func *func = NULL; ++ struct pci_bus *bus = slot->bridge->pci_bus; ++ struct pci_dev *pdev; ++ ++ list_for_each_entry(func, &slot->funcs, sibling) { ++ pdev = pci_get_slot(bus, PCI_DEVFN(slot->device, ++ func->function)); ++ if (pdev) { ++ if (pdev == dev) ++ break; ++ pci_dev_put(pdev); ++ } ++ } ++ return func; ++} ++ ++ ++/** ++ * acpiphp_bus_add - add a new bus to acpi subsystem ++ * @func: acpiphp_func of the bridge ++ * ++ */ ++static int acpiphp_bus_add(struct acpiphp_func *func) ++{ ++ acpi_handle phandle; ++ struct acpi_device *device, *pdevice; ++ int ret_val; ++ ++ acpi_get_parent(func->handle, &phandle); ++ if (acpi_bus_get_device(phandle, &pdevice)) { ++ dbg("no parent device, assuming NULL\n"); ++ pdevice = NULL; ++ } ++ ret_val = acpi_bus_add(&device, pdevice, func->handle, ++ ACPI_BUS_TYPE_DEVICE); ++ if (ret_val) ++ dbg("cannot add bridge to acpi list\n"); ++ ++ /* ++ * try to start anyway. We could have failed to add ++ * simply because this bus had previously been added ++ * on another add. Don't bother with the return value ++ * we just keep going. ++ */ ++ ret_val = acpi_bus_start(device); ++ ++ return ret_val; ++} ++ ++ ++ + /** + * enable_device - enable, configure a slot + * @slot: slot to be enabled +@@ -788,7 +883,7 @@ static int enable_device(struct acpiphp_ + goto err_exit; + } + +- max = bus->secondary; ++ max = acpiphp_max_busnr(bus); + for (pass = 0; pass < 2; pass++) { + list_for_each_entry(dev, &bus->devices, bus_list) { + if (PCI_SLOT(dev->devfn) != slot->device) +@@ -796,8 +891,15 @@ static int enable_device(struct acpiphp_ + if (dev->hdr_type == PCI_HEADER_TYPE_BRIDGE || + dev->hdr_type == PCI_HEADER_TYPE_CARDBUS) { + max = pci_scan_bridge(bus, dev, max, pass); +- if (pass && dev->subordinate) ++ if (pass && dev->subordinate) { + pci_bus_size_bridges(dev->subordinate); ++ func = get_func(slot, dev); ++ if (func) { ++ acpiphp_bus_add(func); ++ /* side effect of get_func */ ++ pci_dev_put(dev); ++ } ++ } + } + } + } diff --git a/pci/pci-device-ensure-sysdata-initialised.patch b/pci/pci-device-ensure-sysdata-initialised.patch new file mode 100644 index 0000000000000..70509a0e5688d --- /dev/null +++ b/pci/pci-device-ensure-sysdata-initialised.patch @@ -0,0 +1,167 @@ +From akpm@osdl.org Fri Feb 3 01:46:42 2006 +Message-Id: <200602030946.k139kKQj002413@shell0.pdx.osdl.net> +Subject: pci device: ensure sysdata initialised +To: greg@kroah.com +Cc: akpm@osdl.org, apw@shadowen.org, jgarzik@pobox.com, mbligh@aracnet.com +From: akpm@osdl.org +Date: Fri, 03 Feb 2006 01:46:01 -0800 + + +From: Andy Whitcroft <apw@shadowen.org> + +Ensure sysdata is valid for all busses. + +We have been seeing panic's on NUMA systems in pci_call_probe() in +2.6.15-rc5-mm2 and -mm3. It seems that some changes have occured to the +meaning of the 'sysdata' for a device such that it is no longer just an +integer containing the node, it is now a structure containing the node and +other data. However, it seems that we do not always initialise this +sysdata before we probe the device. + +Below are three examples from a boot with this checked for. The attached +patch ensures that we supply a valid sysdata for system busses. Currently +we take no account of the node for this bus for no ACPI configured systems. + This is unchanged from the -mm1 code. + + Intel(R) PRO/1000 Network Driver - version 6.1.16-k2 + Copyright (c) 1999-2005 Intel Corporation. + pci_call_probe: starting drv<c03d4be0> dev<dfd16800> id<c03d4734> + pci_call_probe: dev->bus<dfce6800> + pci_call_probe: dev->bus->sysdata<00000000> + pci_call_probe: node<-1> + e1000: eth0: e1000_probe: Intel(R) PRO/1000 Network Connection + + pci_call_probe: starting drv<c03ef220> dev<dfd17400> id<c03eed00> + pci_call_probe: dev->bus<dfce6800> + pci_call_probe: dev->bus->sysdata<00000000> + pci_call_probe: node<-1> + Linux Tulip driver version 1.1.13 (December 15, 2004) + input: AT Translated Set 2 keyboard as /class/input/input0 + tulip0: EEPROM default media type Autosense. + tulip0: Index #0 - Media 10baseT (#0) described by a + 21140 non-MII (0) block. + tulip0: Index #1 - Media 100baseTx (#3) described by a + 21140 non-MII (0) block. + tulip0: Index #2 - Media 10baseT-FDX (#4) described by a + 21140 non-MII (0) block. + tulip0: Index #3 - Media 100baseTx-FDX (#5) described by a + 21140 non-MII (0) block. + eth1: Digital DS21140 Tulip rev 33 at 0001fc00, + 00:00:BC:0F:08:96, IRQ 28. + + pci_call_probe: starting drv<c040a360> dev<dfd14400> id<c040a0fc> + pci_call_probe: dev->bus<dfce6600> + pci_call_probe: dev->bus->sysdata<dfffafa0> + pci_call_probe: node<0> + qla1280: QLA1040 found on PCI bus 0, dev 11 + +Signed-off-by: Andy Whitcroft <apw@shadowen.org> +Cc: Jeff Garzik <jgarzik@pobox.com> +Cc: "Martin J. Bligh" <mbligh@aracnet.com> +Signed-off-by: Andrew Morton <akpm@osdl.org> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> +--- + arch/i386/pci/common.c | 2 ++ + arch/i386/pci/fixup.c | 8 +++++--- + arch/i386/pci/legacy.c | 3 ++- + arch/i386/pci/numa.c | 8 +++++--- + arch/i386/pci/visws.c | 4 ++-- + include/asm-i386/pci.h | 1 + + 6 files changed, 17 insertions(+), 9 deletions(-) + +--- gregkh-2.6.orig/arch/i386/pci/common.c ++++ gregkh-2.6/arch/i386/pci/common.c +@@ -29,6 +29,8 @@ unsigned long pirq_table_addr; + struct pci_bus *pci_root_bus; + struct pci_raw_ops *raw_pci_ops; + ++struct pci_sysdata pci_default_sysdata = { .node = -1 }; ++ + static int pci_read(struct pci_bus *bus, unsigned int devfn, int where, int size, u32 *value) + { + return raw_pci_ops->read(pci_domain_nr(bus), bus->number, +--- gregkh-2.6.orig/arch/i386/pci/fixup.c ++++ gregkh-2.6/arch/i386/pci/fixup.c +@@ -25,9 +25,11 @@ static void __devinit pci_fixup_i450nx(s + pci_read_config_byte(d, reg++, &subb); + DBG("i450NX PXB %d: %02x/%02x/%02x\n", pxb, busno, suba, subb); + if (busno) +- pci_scan_bus(busno, &pci_root_ops, NULL); /* Bus A */ ++ pci_scan_bus(busno, &pci_root_ops, ++ &pci_default_sysdata); /* Bus A */ + if (suba < subb) +- pci_scan_bus(suba+1, &pci_root_ops, NULL); /* Bus B */ ++ pci_scan_bus(suba+1, &pci_root_ops, ++ &pci_default_sysdata); /* Bus B */ + } + pcibios_last_bus = -1; + } +@@ -42,7 +44,7 @@ static void __devinit pci_fixup_i450gx(s + u8 busno; + pci_read_config_byte(d, 0x4a, &busno); + printk(KERN_INFO "PCI: i440KX/GX host bridge %s: secondary bus %02x\n", pci_name(d), busno); +- pci_scan_bus(busno, &pci_root_ops, NULL); ++ pci_scan_bus(busno, &pci_root_ops, &pci_default_sysdata); + pcibios_last_bus = -1; + } + DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82454GX, pci_fixup_i450gx); +--- gregkh-2.6.orig/arch/i386/pci/legacy.c ++++ gregkh-2.6/arch/i386/pci/legacy.c +@@ -26,7 +26,8 @@ static void __devinit pcibios_fixup_peer + l != 0x0000 && l != 0xffff) { + DBG("Found device at %02x:%02x [%04x]\n", n, devfn, l); + printk(KERN_INFO "PCI: Discovered peer bus %02x\n", n); +- pci_scan_bus(n, &pci_root_ops, NULL); ++ pci_scan_bus(n, &pci_root_ops, ++ &pci_default_sysdata); + break; + } + } +--- gregkh-2.6.orig/arch/i386/pci/numa.c ++++ gregkh-2.6/arch/i386/pci/numa.c +@@ -97,9 +97,11 @@ static void __devinit pci_fixup_i450nx(s + pci_read_config_byte(d, reg++, &subb); + DBG("i450NX PXB %d: %02x/%02x/%02x\n", pxb, busno, suba, subb); + if (busno) +- pci_scan_bus(QUADLOCAL2BUS(quad,busno), &pci_root_ops, NULL); /* Bus A */ ++ pci_scan_bus(QUADLOCAL2BUS(quad,busno), &pci_root_ops, ++ &pci_default_sysdata); /* Bus A */ + if (suba < subb) +- pci_scan_bus(QUADLOCAL2BUS(quad,suba+1), &pci_root_ops, NULL); /* Bus B */ ++ pci_scan_bus(QUADLOCAL2BUS(quad,suba+1), &pci_root_ops, ++ &pci_default_sysdata); /* Bus B */ + } + pcibios_last_bus = -1; + } +@@ -124,7 +126,7 @@ static int __init pci_numa_init(void) + printk("Scanning PCI bus %d for quad %d\n", + QUADLOCAL2BUS(quad,0), quad); + pci_scan_bus(QUADLOCAL2BUS(quad,0), +- &pci_root_ops, NULL); ++ &pci_root_ops, &pci_default_sysdata); + } + return 0; + } +--- gregkh-2.6.orig/arch/i386/pci/visws.c ++++ gregkh-2.6/arch/i386/pci/visws.c +@@ -102,8 +102,8 @@ static int __init pcibios_init(void) + "bridge B (PIIX4) bus: %u\n", pci_bus1, pci_bus0); + + raw_pci_ops = &pci_direct_conf1; +- pci_scan_bus(pci_bus0, &pci_root_ops, NULL); +- pci_scan_bus(pci_bus1, &pci_root_ops, NULL); ++ pci_scan_bus(pci_bus0, &pci_root_ops, &pci_default_sysdata); ++ pci_scan_bus(pci_bus1, &pci_root_ops, &pci_default_sysdata); + pci_fixup_irqs(visws_swizzle, visws_map_irq); + pcibios_resource_survey(); + return 0; +--- gregkh-2.6.orig/include/asm-i386/pci.h ++++ gregkh-2.6/include/asm-i386/pci.h +@@ -9,6 +9,7 @@ struct pci_sysdata { + int domain; /* PCI domain */ + int node; /* NUMA node */ + }; ++extern struct pci_sysdata pci_default_sysdata; + + #ifdef CONFIG_PCI_DOMAINS + static inline int pci_domain_nr(struct pci_bus *bus) diff --git a/pci/pci-fix-the-x86-pci-domain-support-fix.patch b/pci/pci-fix-the-x86-pci-domain-support-fix.patch new file mode 100644 index 0000000000000..170025baa0f18 --- /dev/null +++ b/pci/pci-fix-the-x86-pci-domain-support-fix.patch @@ -0,0 +1,39 @@ +From akpm@osdl.org Fri Feb 3 01:46:31 2006 +Message-Id: <200602030946.k139kIW6002410@shell0.pdx.osdl.net> +Subject: PCI: fix the x86 pci domain support fix +To: greg@kroah.com +Cc: akpm@osdl.org, apw@shadowen.org, jgarzik@pobox.com, mbligh@aracnet.com +From: akpm@osdl.org +Date: Fri, 03 Feb 2006 01:45:58 -0800 + + +From: Andrew Morton <akpm@osdl.org> + +x86_64 needs this declared too.. + +arch/x86_64/pci/../../i386/pci/fixup.c: In function `pci_fixup_i450nx': +arch/x86_64/pci/../../i386/pci/fixup.c:29: error: `pci_default_sysdata' undeclared (first use in this function) +arch/x86_64/pci/../../i386/pci/fixup.c:29: error: (Each undeclared identifier is reported only once +arch/x86_64/pci/../../i386/pci/fixup.c:29: error: for each function it appears in.) +arch/x86_64/pci/../../i386/pci/fixup.c: In function `pci_fixup_i450gx': +arch/x86_64/pci/../../i386/pci/fixup.c:47: error: `pci_default_sysdata' undeclared (first use in this function) + +Cc: Andy Whitcroft <apw@shadowen.org> +Cc: Jeff Garzik <jgarzik@pobox.com> +Cc: "Martin J. Bligh" <mbligh@aracnet.com> +Signed-off-by: Andrew Morton <akpm@osdl.org> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> +--- + include/asm-x86_64/pci.h | 1 + + 1 file changed, 1 insertion(+) + +--- gregkh-2.6.orig/include/asm-x86_64/pci.h ++++ gregkh-2.6/include/asm-x86_64/pci.h +@@ -10,6 +10,7 @@ struct pci_sysdata { + int domain; /* PCI domain */ + int node; /* NUMA node */ + }; ++extern struct pci_sysdata pci_default_sysdata; + + #ifdef CONFIG_PCI_DOMAINS + static inline int pci_domain_nr(struct pci_bus *bus) diff --git a/pci/pci-give-pci-config-access-initialization-a-defined-ordering.patch b/pci/pci-give-pci-config-access-initialization-a-defined-ordering.patch new file mode 100644 index 0000000000000..6598904477ebb --- /dev/null +++ b/pci/pci-give-pci-config-access-initialization-a-defined-ordering.patch @@ -0,0 +1,190 @@ +From ak@suse.de Fri Feb 10 02:47:08 2006 +From: Andi Kleen <ak@suse.de> +To: Greg KH <greg@kroah.com> +Subject: PCI: Give PCI config access initialization a defined ordering +Date: Fri, 10 Feb 2006 11:46:29 +0100 +Cc: Stephen Hemminger <shemminger@osdl.org>, Matthew Wilcox <matthew@wil.cx> +Content-Disposition: inline +Message-Id: <200602101146.30126.ak@suse.de> + + +I moved it to a separate function which is safer. + +This avoids problems with the linker reordering them and the +less useful PCI config space access methods taking priority +over the better ones. + +Fixes some problems with broken MMCONFIG + +Signed-off-by: Andi Kleen <ak@suse.de> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + arch/i386/pci/Makefile | 2 +- + arch/i386/pci/direct.c | 15 +++++---------- + arch/i386/pci/init.c | 25 +++++++++++++++++++++++++ + arch/i386/pci/mmconfig.c | 11 +++-------- + arch/i386/pci/pcbios.c | 4 +--- + arch/i386/pci/pci.h | 3 +++ + arch/x86_64/pci/Makefile | 3 ++- + 7 files changed, 40 insertions(+), 23 deletions(-) + +--- gregkh-2.6.orig/arch/i386/pci/direct.c ++++ gregkh-2.6/arch/i386/pci/direct.c +@@ -245,7 +245,7 @@ static int __init pci_check_type2(void) + return works; + } + +-static int __init pci_direct_init(void) ++void __init pci_direct_init(void) + { + struct resource *region, *region2; + +@@ -258,16 +258,16 @@ static int __init pci_direct_init(void) + if (pci_check_type1()) { + printk(KERN_INFO "PCI: Using configuration type 1\n"); + raw_pci_ops = &pci_direct_conf1; +- return 0; ++ return; + } + release_resource(region); + + type2: + if ((pci_probe & PCI_PROBE_CONF2) == 0) +- goto out; ++ return; + region = request_region(0xCF8, 4, "PCI conf2"); + if (!region) +- goto out; ++ return; + region2 = request_region(0xC000, 0x1000, "PCI conf2"); + if (!region2) + goto fail2; +@@ -275,15 +275,10 @@ static int __init pci_direct_init(void) + if (pci_check_type2()) { + printk(KERN_INFO "PCI: Using configuration type 2\n"); + raw_pci_ops = &pci_direct_conf2; +- return 0; ++ return; + } + + release_resource(region2); + fail2: + release_resource(region); +- +- out: +- return 0; + } +- +-arch_initcall(pci_direct_init); +--- gregkh-2.6.orig/arch/i386/pci/mmconfig.c ++++ gregkh-2.6/arch/i386/pci/mmconfig.c +@@ -172,25 +172,20 @@ static __init void unreachable_devices(v + } + } + +-static int __init pci_mmcfg_init(void) ++void __init pci_mmcfg_init(void) + { + if ((pci_probe & PCI_PROBE_MMCONF) == 0) +- goto out; ++ return; + + acpi_table_parse(ACPI_MCFG, acpi_parse_mcfg); + if ((pci_mmcfg_config_num == 0) || + (pci_mmcfg_config == NULL) || + (pci_mmcfg_config[0].base_address == 0)) +- goto out; ++ return; + + printk(KERN_INFO "PCI: Using MMCONFIG\n"); + raw_pci_ops = &pci_mmcfg; + pci_probe = (pci_probe & ~PCI_PROBE_MASK) | PCI_PROBE_MMCONF; + + unreachable_devices(); +- +- out: +- return 0; + } +- +-arch_initcall(pci_mmcfg_init); +--- gregkh-2.6.orig/arch/i386/pci/pcbios.c ++++ gregkh-2.6/arch/i386/pci/pcbios.c +@@ -476,14 +476,12 @@ int pcibios_set_irq_routing(struct pci_d + } + EXPORT_SYMBOL(pcibios_set_irq_routing); + +-static int __init pci_pcbios_init(void) ++void __init pci_pcbios_init(void) + { + if ((pci_probe & PCI_PROBE_BIOS) + && ((raw_pci_ops = pci_find_bios()))) { + pci_probe |= PCI_BIOS_SORT; + pci_bios_present = 1; + } +- return 0; + } + +-arch_initcall(pci_pcbios_init); +--- gregkh-2.6.orig/arch/i386/pci/pci.h ++++ gregkh-2.6/arch/i386/pci/pci.h +@@ -80,4 +80,7 @@ extern int pci_conf1_write(unsigned int + extern int pci_conf1_read(unsigned int seg, unsigned int bus, + unsigned int devfn, int reg, int len, u32 *value); + ++extern void pci_direct_init(void); ++extern void pci_pcbios_init(void); ++extern void pci_mmcfg_init(void); + +--- gregkh-2.6.orig/arch/x86_64/pci/Makefile ++++ gregkh-2.6/arch/x86_64/pci/Makefile +@@ -7,7 +7,7 @@ CFLAGS += -Iarch/i386/pci + + obj-y := i386.o + obj-$(CONFIG_PCI_DIRECT)+= direct.o +-obj-y += fixup.o ++obj-y += fixup.o init.o + obj-$(CONFIG_ACPI) += acpi.o + obj-y += legacy.o irq.o common.o + # mmconfig has a 64bit special +@@ -22,3 +22,4 @@ irq-y += ../../i386/pci/irq.o + common-y += ../../i386/pci/common.o + fixup-y += ../../i386/pci/fixup.o + i386-y += ../../i386/pci/i386.o ++init-y += ../../i386/pci/init.o +--- /dev/null ++++ gregkh-2.6/arch/i386/pci/init.c +@@ -0,0 +1,25 @@ ++#include <linux/config.h> ++#include <linux/pci.h> ++#include <linux/init.h> ++#include "pci.h" ++ ++/* arch_initcall has too random ordering, so call the initializers ++ in the right sequence from here. */ ++static __init int pci_access_init(void) ++{ ++#ifdef CONFIG_PCI_MMCONFIG ++ pci_mmcfg_init(); ++#endif ++ if (raw_pci_ops) ++ return 0; ++#ifdef CONFIG_PCI_DIRECT ++ pci_direct_init(); ++#endif ++ if (raw_pci_ops) ++ return 0; ++#ifdef CONFIG_PCI_BIOS ++ pci_pcbios_init(); ++#endif ++ return 0; ++} ++arch_initcall(pci_access_init); +--- gregkh-2.6.orig/arch/i386/pci/Makefile ++++ gregkh-2.6/arch/i386/pci/Makefile +@@ -1,4 +1,4 @@ +-obj-y := i386.o ++obj-y := i386.o init.o + + obj-$(CONFIG_PCI_BIOS) += pcbios.o + obj-$(CONFIG_PCI_MMCONFIG) += mmconfig.o direct.o diff --git a/pci/pci-hotplug-convert-semaphores-to-mutex.patch b/pci/pci-hotplug-convert-semaphores-to-mutex.patch index 2cbbc23a6d7fd..08ccb5c24b82e 100644 --- a/pci/pci-hotplug-convert-semaphores-to-mutex.patch +++ b/pci/pci-hotplug-convert-semaphores-to-mutex.patch @@ -66,7 +66,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> #include "../pci.h" #include "pci_hotplug.h" -@@ -202,7 +202,7 @@ register_slot(acpi_handle handle, u32 lv +@@ -188,7 +188,7 @@ register_slot(acpi_handle handle, u32 lv slot->device = device; slot->sun = sun; INIT_LIST_HEAD(&slot->funcs); @@ -75,7 +75,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> slot->next = bridge->slots; bridge->slots = slot; -@@ -1428,7 +1428,7 @@ int acpiphp_enable_slot(struct acpiphp_s +@@ -1503,7 +1503,7 @@ int acpiphp_enable_slot(struct acpiphp_s { int retval; @@ -84,7 +84,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> /* wake up all functions */ retval = power_on_slot(slot); -@@ -1440,7 +1440,7 @@ int acpiphp_enable_slot(struct acpiphp_s +@@ -1515,7 +1515,7 @@ int acpiphp_enable_slot(struct acpiphp_s retval = enable_device(slot); err_exit: @@ -93,7 +93,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> return retval; } -@@ -1451,7 +1451,7 @@ int acpiphp_disable_slot(struct acpiphp_ +@@ -1526,7 +1526,7 @@ int acpiphp_disable_slot(struct acpiphp_ { int retval = 0; @@ -102,7 +102,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> /* unconfigure all functions */ retval = disable_device(slot); -@@ -1464,7 +1464,7 @@ int acpiphp_disable_slot(struct acpiphp_ +@@ -1539,7 +1539,7 @@ int acpiphp_disable_slot(struct acpiphp_ goto err_exit; err_exit: |