linux/arch/powerpc
Yuanquan Chen 37f02195be powerpc/pci: fix PCI-e devices rescan issue on powerpc platform
Powerpc initializes the DMA and IRQ information in pci_scan_child_bus()->
pcibios_fixup_bus()->pcibios_setup_bus_devices(). But for the devices
which are hotpluged, bus->is added has been set for the first scan of the
PCI-e bus, so the initialization code won't be called. Then the hotpluged
devices' driver will fail to load.

For example :
The PCI-e device 0001:03:00.0 is the Intel PCI-e e1000e network card, remove
it from the system:

    # echo 1 > /sys/bus/pci/devices/0001\:03\:00.0/remove
    # e1000e 0001:03:00.0 eth0: removed PHC

Rescan it from it's bus:

    # echo 1 > /sys/bus/pci/devices/0001\:02\:00.0/rescan
    ...
    e1000e 0001:03:00.0: Disabling ASPM L0s L1
    e1000e 0001:03:00.0: No usable DMA configuration, aborting
    e1000e: probe of 0001:03:00.0 failed with error -5

So we move the DMA & IRQ initialization code from pcibios_setup_devices() and
construct a new function pcibios_enable_device. We call this function in
pcibios_enable_device, which will be called by PCI-e rescan code. At the
meanwhile, we avoid the the impact on cardbus. I also validate this patch with
silicon's PCIe-sata which encounters the IRQ issue.

Signed-off-by: Yuanquan Chen <Yuanquan.Chen@freescale.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Hiroo Matsumoto <matsumoto.hiroo@jp.fujitsu.com>
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
2013-04-18 15:59:57 +10:00
..
boot Merge remote-tracking branch 'agust/next' into next 2013-02-20 11:39:05 +11:00
configs powerpc/ps3: Update ps3_defconfig 2013-04-18 13:03:50 +10:00
crypto powerpc: Fix compile of sha1-powerpc-asm.S on 32-bit 2013-03-05 16:56:26 +11:00
include powerpc/ptrace: Add DAWR debug feature info for userspace 2013-04-18 15:59:55 +10:00
kernel powerpc/pci: fix PCI-e devices rescan issue on powerpc platform 2013-04-18 15:59:57 +10:00
kvm powerpc: Fix build errors with UP configs in HV-style KVM 2013-04-18 13:03:57 +10:00
lib uprobes/powerpc: Add dependency on single step emulation 2013-01-29 11:35:06 +11:00
math-emu
mm powerpc: fix annotation of fake_numa_create_new_node() 2013-04-18 15:59:56 +10:00
net
oprofile Merge branch 'merge' into next 2013-01-29 11:33:37 +11:00
perf perf/urgent fixes: 2013-03-18 10:00:56 +01:00
platforms powerpc/pseries: close DDW race between functions of adapter 2013-04-18 13:04:00 +10:00
sysdev powerpc: Use PTR_RET instead of IS_ERR/PTR_ERR 2013-04-18 13:03:48 +10:00
xmon powerpc: Rename set_break to avoid naming conflict 2013-01-16 05:25:47 +11:00
Kconfig memblock: kill "config MAX_ACTIVE_REGIONS" 2013-04-18 13:03:53 +10:00
Kconfig.debug
Makefile
relocs_check.pl