Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fe146be6 authored by Alexander Beregalov's avatar Alexander Beregalov Committed by David S. Miller
Browse files

ether3: convert to net_device_ops

parent 0b179e31
Loading
Loading
Loading
Loading
+13 −6
Original line number Diff line number Diff line
@@ -770,6 +770,18 @@ static void __devinit ether3_banner(void)
		printk(KERN_INFO "%s", version);
}

static const struct net_device_ops ether3_netdev_ops = {
	.ndo_open		= ether3_open,
	.ndo_stop		= ether3_close,
	.ndo_start_xmit		= ether3_sendpacket,
	.ndo_get_stats		= ether3_getstats,
	.ndo_set_multicast_list	= ether3_setmulticastlist,
	.ndo_tx_timeout		= ether3_timeout,
	.ndo_validate_addr	= eth_validate_addr,
	.ndo_change_mtu		= eth_change_mtu,
	.ndo_set_mac_address	= eth_mac_addr,
};

static int __devinit
ether3_probe(struct expansion_card *ec, const struct ecard_id *id)
{
@@ -846,12 +858,7 @@ ether3_probe(struct expansion_card *ec, const struct ecard_id *id)
		goto free;
	}

	dev->open		= ether3_open;
	dev->stop		= ether3_close;
	dev->hard_start_xmit	= ether3_sendpacket;
	dev->get_stats		= ether3_getstats;
	dev->set_multicast_list	= ether3_setmulticastlist;
	dev->tx_timeout		= ether3_timeout;
	dev->netdev_ops		= &ether3_netdev_ops;
	dev->watchdog_timeo	= 5 * HZ / 100;

	ret = register_netdev(dev);