diff options
author | kaloz <kaloz@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2010-02-23 10:43:53 +0000 |
---|---|---|
committer | kaloz <kaloz@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2010-02-23 10:43:53 +0000 |
commit | 250089c5e97cc8490a42e9885e429ff217dbd533 (patch) | |
tree | 3eac3e565ec64f61d64b536e14d9a001e2d02405 /target/linux/ubicom32/files/drivers/net | |
parent | 9eedef7a46e7431de4b98a808503571c1a8570eb (diff) |
[ubicom32]: add 2.6.32 support
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@19823 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/ubicom32/files/drivers/net')
-rw-r--r-- | target/linux/ubicom32/files/drivers/net/ubi32-eth.c | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/target/linux/ubicom32/files/drivers/net/ubi32-eth.c b/target/linux/ubicom32/files/drivers/net/ubi32-eth.c index e6c7392e06..e9c62f4625 100644 --- a/target/linux/ubicom32/files/drivers/net/ubi32-eth.c +++ b/target/linux/ubicom32/files/drivers/net/ubi32-eth.c @@ -634,6 +634,19 @@ void ubi32_eth_cleanup(void) } } + static const struct net_device_ops ubi32_netdev_ops = { + .ndo_open = ubi32_eth_open, + .ndo_stop = ubi32_eth_close, + .ndo_start_xmit = ubi32_eth_start_xmit, + .ndo_tx_timeout = ubi32_eth_tx_timeout, + .ndo_do_ioctl = ubi32_eth_ioctl, + .ndo_change_mtu = ubi32_eth_change_mtu, + .ndo_set_config = ubi32_eth_set_config, + .ndo_get_stats = ubi32_eth_get_stats, + .ndo_validate_addr = eth_validate_addr, + .ndo_set_mac_address = eth_mac_addr, + }; + int ubi32_eth_init_module(void) { struct ethtionode *eth_node; @@ -706,16 +719,9 @@ int ubi32_eth_init_module(void) spin_lock_init(&priv->lock); - dev->open = ubi32_eth_open; - dev->stop = ubi32_eth_close; - dev->hard_start_xmit = ubi32_eth_start_xmit; - dev->tx_timeout = ubi32_eth_tx_timeout; - dev->watchdog_timeo = UBI32_ETH_VP_TX_TIMEOUT; + dev->netdev_ops = &ubi32_netdev_ops; - dev->set_config = ubi32_eth_set_config; - dev->do_ioctl = ubi32_eth_ioctl; - dev->get_stats = ubi32_eth_get_stats; - dev->change_mtu = ubi32_eth_change_mtu; + dev->watchdog_timeo = UBI32_ETH_VP_TX_TIMEOUT; #ifdef UBICOM32_USE_NAPI netif_napi_add(dev, &priv->napi, ubi32_eth_napi_poll, UBI32_ETH_NAPI_WEIGHT); #endif |