]> git.openfabrics.org - ~emulex/tmp/compat/.git/commitdiff
Fix build with CONFIG_USB disabled
authorLuis R. Rodriguez <lrodriguez@atheros.com>
Tue, 19 Jan 2010 23:59:13 +0000 (15:59 -0800)
committerLuis R. Rodriguez <lrodriguez@atheros.com>
Tue, 19 Jan 2010 23:59:13 +0000 (15:59 -0800)
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
compat/compat-2.6.28.c
compat/compat-2.6.29.c
include/linux/compat-2.6.28.h
include/linux/compat-2.6.29.h

index e3f3a1be37eacd665b93c1577a4bde647501f150..a141859f70b381a43f30527c0c6f07ae40d14c32 100644 (file)
@@ -17,6 +17,7 @@
 /* 2.6.28 compat code goes here */
 
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,23))
+#if defined(CONFIG_USB)
 /*
  * Compat-wireless notes for USB backport stuff:
  *
@@ -84,6 +85,7 @@ void usb_poison_urb(struct urb *urb)
 }
 EXPORT_SYMBOL_GPL(usb_poison_urb);
 #endif
+#endif /* CONFIG_USB */
 
 #if defined(CONFIG_PCMCIA) || defined(CONFIG_PCMCIA_MODULE)
 
@@ -164,6 +166,8 @@ EXPORT_SYMBOL(pcmcia_loop_config);
 
 #endif /* CONFIG_PCMCIA */
 
+#if defined(CONFIG_USB)
+
 void usb_unpoison_urb(struct urb *urb)
 {
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,28))
@@ -286,9 +290,9 @@ int usb_anchor_empty(struct usb_anchor *anchor)
 }
 
 EXPORT_SYMBOL_GPL(usb_anchor_empty);
+#endif /* CONFIG_USB */
 #endif
 
-
 void __iomem *pci_ioremap_bar(struct pci_dev *pdev, int bar)
 {
        /*
index 50100d9a9cf886c54f460b66fb70107784436ab5..48e72a352c45ff250eccbb821cecd3f48ae1160f 100644 (file)
@@ -16,6 +16,7 @@
 #include <linux/etherdevice.h>
 
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,23))
+#if defined(CONFIG_USB)
 /**
  * usb_unpoison_anchored_urbs - let an anchor be used successfully again
  * @anchor: anchor the requests are bound to
@@ -36,6 +37,7 @@ void usb_unpoison_anchored_urbs(struct usb_anchor *anchor)
        spin_unlock_irqrestore(&anchor->lock, flags);
 }
 EXPORT_SYMBOL_GPL(usb_unpoison_anchored_urbs);
+#endif /* CONFIG_USB */
 #endif
 
 /**
index c7dcb798c6e1aa8565d55f13bd47f97446144cee..13a036749129800512edb3c549f421ca4961db27 100644 (file)
@@ -51,6 +51,8 @@ int pcmcia_loop_config(struct pcmcia_device *p_dev,
 
 /* USB anchors were added as of 2.6.23 */
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,23))
+
+#if defined(CONFIG_USB)
 #if 0
 extern void usb_poison_urb(struct urb *urb);
 #endif
@@ -63,6 +65,7 @@ extern void usb_poison_anchored_urbs(struct usb_anchor *anchor);
 extern struct urb *usb_get_from_anchor(struct usb_anchor *anchor);
 extern void usb_scuttle_anchored_urbs(struct usb_anchor *anchor);
 extern int usb_anchor_empty(struct usb_anchor *anchor);
+#endif /* CONFIG_USB */
 #endif
 
 
index 318cdf435ab59fd51665c4e4cc0b69f48cc0b25a..27f1325253e420e874f7f027e647801d87c113ba 100644 (file)
@@ -47,7 +47,9 @@ static inline struct net_device_stats *dev_get_stats(struct net_device *dev)
 }
 
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,23))
+#if defined(CONFIG_USB)
 extern void usb_unpoison_anchored_urbs(struct usb_anchor *anchor);
+#endif /* CONFIG_USB */
 #endif
 
 #define DIV_ROUND_CLOSEST(x, divisor)(                 \