From: Luis R. Rodriguez Date: Tue, 4 Aug 2009 18:18:45 +0000 (-0700) Subject: move b44.c changes to 01-netdev.patch X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=e04d54d210423796d892290f67d499eb743f4a49;p=openwrt%2Fstaging%2Fblogic.git move b44.c changes to 01-netdev.patch Signed-off-by: Luis R. Rodriguez --- diff --git a/compat/compat.diff b/compat/compat.diff index 7352b1f30250..07b2ebbae1a1 100644 --- a/compat/compat.diff +++ b/compat/compat.diff @@ -6,51 +6,6 @@ -obj-$(CONFIG_EEPROM_LEGACY) += eeprom.o -obj-$(CONFIG_EEPROM_MAX6875) += max6875.o obj-$(CONFIG_EEPROM_93CX6) += eeprom_93cx6.o ---- a/drivers/net/b44.c -+++ b/drivers/net/b44.c -@@ -2112,6 +2112,7 @@ static int __devinit b44_get_invariants(struct b44 *bp) - return err; - } - -+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)) - static const struct net_device_ops b44_netdev_ops = { - .ndo_open = b44_open, - .ndo_stop = b44_close, -@@ -2127,6 +2128,7 @@ static const struct net_device_ops b44_netdev_ops = { - .ndo_poll_controller = b44_poll_controller, - #endif - }; -+#endif - - static int __devinit b44_init_one(struct ssb_device *sdev, - const struct ssb_device_id *ent) -@@ -2166,9 +2168,26 @@ static int __devinit b44_init_one(struct ssb_device *sdev, - bp->rx_pending = B44_DEF_RX_RING_PENDING; - bp->tx_pending = B44_DEF_TX_RING_PENDING; - -+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,29)) -+ dev->open = b44_open; -+ dev->stop = b44_close; -+ dev->hard_start_xmit = b44_start_xmit; -+ dev->get_stats = b44_get_stats; -+ dev->set_multicast_list = b44_set_rx_mode; -+ dev->set_mac_address = b44_set_mac_addr; -+ dev->do_ioctl = b44_ioctl; -+ dev->tx_timeout = b44_tx_timeout; -+ netif_napi_add(dev, &bp->napi, b44_poll, 64); -+ dev->watchdog_timeo = B44_TX_TIMEOUT; -+#ifdef CONFIG_NET_POLL_CONTROLLER -+ dev->poll_controller = b44_poll_controller; -+#endif -+ dev->change_mtu = b44_change_mtu; -+#else - dev->netdev_ops = &b44_netdev_ops; - netif_napi_add(dev, &bp->napi, b44_poll, 64); - dev->watchdog_timeo = B44_TX_TIMEOUT; -+#endif - dev->irq = sdev->irq; - SET_ETHTOOL_OPS(dev, &b44_ethtool_ops); - --- a/drivers/net/usb/Makefile 2009-07-27 08:03:34.770077174 -0700 +++ b/drivers/net/usb/Makefile 2009-07-27 08:04:22.594143560 -0700 @@ -2,24 +2,7 @@ diff --git a/compat/diffs/01-netdev.patch b/compat/diffs/01-netdev.patch index 1d90a36171e6..5391ab146a14 100644 --- a/compat/diffs/01-netdev.patch +++ b/compat/diffs/01-netdev.patch @@ -177,6 +177,51 @@ if (ieee80211_vif_is_mesh(&sdata->vif) && params && params->mesh_id_len) ieee80211_sdata_set_mesh_id(sdata, +--- a/drivers/net/b44.c ++++ b/drivers/net/b44.c +@@ -2112,6 +2112,7 @@ static int __devinit b44_get_invariants(struct b44 *bp) + return err; + } + ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)) + static const struct net_device_ops b44_netdev_ops = { + .ndo_open = b44_open, + .ndo_stop = b44_close, +@@ -2127,6 +2128,7 @@ static const struct net_device_ops b44_netdev_ops = { + .ndo_poll_controller = b44_poll_controller, + #endif + }; ++#endif + + static int __devinit b44_init_one(struct ssb_device *sdev, + const struct ssb_device_id *ent) +@@ -2166,9 +2168,26 @@ static int __devinit b44_init_one(struct ssb_device *sdev, + bp->rx_pending = B44_DEF_RX_RING_PENDING; + bp->tx_pending = B44_DEF_TX_RING_PENDING; + ++#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,29)) ++ dev->open = b44_open; ++ dev->stop = b44_close; ++ dev->hard_start_xmit = b44_start_xmit; ++ dev->get_stats = b44_get_stats; ++ dev->set_multicast_list = b44_set_rx_mode; ++ dev->set_mac_address = b44_set_mac_addr; ++ dev->do_ioctl = b44_ioctl; ++ dev->tx_timeout = b44_tx_timeout; ++ netif_napi_add(dev, &bp->napi, b44_poll, 64); ++ dev->watchdog_timeo = B44_TX_TIMEOUT; ++#ifdef CONFIG_NET_POLL_CONTROLLER ++ dev->poll_controller = b44_poll_controller; ++#endif ++ dev->change_mtu = b44_change_mtu; ++#else + dev->netdev_ops = &b44_netdev_ops; + netif_napi_add(dev, &bp->napi, b44_poll, 64); + dev->watchdog_timeo = B44_TX_TIMEOUT; ++#endif + dev->irq = sdev->irq; + SET_ETHTOOL_OPS(dev, &b44_ethtool_ops); + --- a/net/wireless/wext.c 2009-08-04 10:50:33.634995059 -0700 +++ b/net/wireless/wext.c 2009-08-04 10:50:34.175014901 -0700 @@ -1118,8 +1118,13 @@