From: Hauke Mehrtens Date: Tue, 12 Jan 2010 22:46:27 +0000 (+0100) Subject: compat-wireless: remove device_type in usbnet.c X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=b096c03e4f00d90d247034e696e32e80a7bd9f10;p=openwrt%2Fstaging%2Fblogic.git compat-wireless: remove device_type in usbnet.c This fixes compile warning drivers/net/usb/usbnet.c:1279: warning: ‘wlan_type’ defined but not used drivers/net/usb/usbnet.c:1283: warning: ‘wwan_type’ defined but not used Signed-off-by: Hauke Mehrtens --- diff --git a/patches/14-device-type.patch b/patches/14-device-type.patch index fdd7b2339a06..5c4f4d7c4cca 100644 --- a/patches/14-device-type.patch +++ b/patches/14-device-type.patch @@ -34,3 +34,23 @@ compile warning. int bnep_add_connection(struct bnep_connadd_req *req, struct socket *sock) { +--- a/drivers/net/usb/usbnet.c ++++ b/drivers/net/usb/usbnet.c +@@ -1276,13 +1276,17 @@ static const struct net_device_ops usbne + + // precondition: never called in_interrupt + ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,32)) + static struct device_type wlan_type = { + .name = "wlan", + }; ++#endif + ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,32)) + static struct device_type wwan_type = { + .name = "wwan", + }; ++#endif + + int + usbnet_probe (struct usb_interface *udev, const struct usb_device_id *prod)