]> err.no Git - linux-2.6/commitdiff
ssb: Add pcibios_enable_device() return value check
authorYoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Fri, 29 Feb 2008 10:09:31 +0000 (11:09 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 4 Mar 2008 23:36:35 +0000 (18:36 -0500)
This patch has added pcibios_enable_device() return value check.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/ssb/driver_pcicore.c

index 07ab48d9ceab1f70e3b06abd9ad5670d719adf91..74b9a8aea52b12bbbf721a9c6f623ac2d09655b3 100644 (file)
@@ -111,7 +111,10 @@ static void __init ssb_fixup_pcibridge(struct pci_dev *dev)
 
        /* Enable PCI bridge bus mastering and memory space */
        pci_set_master(dev);
-       pcibios_enable_device(dev, ~0);
+       if (pcibios_enable_device(dev, ~0) < 0) {
+               ssb_printk(KERN_ERR "PCI: SSB bridge enable failed\n");
+               return;
+       }
 
        /* Enable PCI bridge BAR1 prefetch and burst */
        pci_write_config_dword(dev, SSB_BAR1_CONTROL, 3);