Re: EDD build error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wednesday 27 June 2007, Randy Dunlap wrote:
>
> From original email:
> (This is in 2.6.22-rc4-mm2 FWIW.)

Sorry. This one should be better.
I've moved the edd_info, to avoid the -Wunused.

	Torsten
--- linux-2.6.22-rc4-mm2/drivers/firmware/edd.c.orig	2007-06-27 00:36:45.000000000 +0200
+++ linux-2.6.22-rc4-mm2/drivers/firmware/edd.c	2007-06-27 00:38:52.000000000 +0200
@@ -666,13 +666,17 @@ edd_dev_is_type(struct edd_device *edev,
 static struct pci_dev *
 edd_get_pci_dev(struct edd_device *edev)
 {
-	struct edd_info *info = edd_dev_get_info(edev);
 
 	if (edd_dev_is_type(edev, "PCI")) {
+#ifdef CONFIG_PCI
+		struct edd_info *info = edd_dev_get_info(edev);
 		return pci_get_bus_and_slot(info->params.interface_path.pci.bus,
 				     PCI_DEVFN(info->params.interface_path.pci.slot,
 					       info->params.interface_path.pci.
 					       function));
+#else
+		printk(KERN_WARNING "EDD referenced a PCI device for drive 0x%02x, but PCI is not configured\n", edev->index);
+#endif
 	}
 	return NULL;
 }

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux