From 2d99c41f05fc2a26737aacf943db03ca89841199 Mon Sep 17 00:00:00 2001 From: Olaf Hering Date: Sat, 10 Feb 2007 21:38:37 +0100 Subject: [PATCH] [POWERPC] Mark winbond IDE PCI resources with start 0 as unassigned libata calls pci_request_regions to claim PCI BAR 0 - 5 pci_request_regions fails if one of the regions cant be claimed. bar 5 has start == 0, __request_resource will fail. Tested on a p630 in SMP mode with pata_sl82c105 00:03.1 IDE interface: Symphony Labs SL82c105 (rev 05) (prog-if 8f [Master SecP SecO PriP PriO]) Control: I/O+ Mem- BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr+ Stepping- SERR+ FastB2B- Status: Cap- 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- SERR- Signed-off-by: Paul Mackerras --- arch/powerpc/platforms/pseries/pci.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/powerpc/platforms/pseries/pci.c b/arch/powerpc/platforms/pseries/pci.c index c69bd15ced9c..fa59124ce3fe 100644 --- a/arch/powerpc/platforms/pseries/pci.c +++ b/arch/powerpc/platforms/pseries/pci.c @@ -98,6 +98,10 @@ static void fixup_winbond_82c105(struct pci_dev* dev) if (dev->resource[i].flags & IORESOURCE_IO && dev->bus->number == 0 && dev->devfn == 0x81) dev->resource[i].flags &= ~IORESOURCE_IO; + if (dev->resource[i].start == 0 && dev->resource[i].end) { + dev->resource[i].flags = 0; + dev->resource[i].end = 0; + } } } DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_WINBOND, PCI_DEVICE_ID_WINBOND_82C105,