Commit fd8f4997 authored by Stephen Hemminger's avatar Stephen Hemminger Committed by David S. Miller

defxx: convert driver to net_device_ops

Convert this driver to net_device_ops.
Signed-off-by: default avatarStephen Hemminger <shemminger@vyatta.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 145186a3
...@@ -477,6 +477,15 @@ static void dfx_get_bars(struct device *bdev, ...@@ -477,6 +477,15 @@ static void dfx_get_bars(struct device *bdev,
} }
} }
static const struct net_device_ops dfx_netdev_ops = {
.ndo_open = dfx_open,
.ndo_stop = dfx_close,
.ndo_start_xmit = dfx_xmt_queue_pkt,
.ndo_get_stats = dfx_ctl_get_stats,
.ndo_set_multicast_list = dfx_ctl_set_multicast_list,
.ndo_set_mac_address = dfx_ctl_set_mac_address,
};
/* /*
* ================ * ================
* = dfx_register = * = dfx_register =
...@@ -573,13 +582,7 @@ static int __devinit dfx_register(struct device *bdev) ...@@ -573,13 +582,7 @@ static int __devinit dfx_register(struct device *bdev)
} }
/* Initialize new device structure */ /* Initialize new device structure */
dev->netdev_ops = &dfx_netdev_ops;
dev->get_stats = dfx_ctl_get_stats;
dev->open = dfx_open;
dev->stop = dfx_close;
dev->hard_start_xmit = dfx_xmt_queue_pkt;
dev->set_multicast_list = dfx_ctl_set_multicast_list;
dev->set_mac_address = dfx_ctl_set_mac_address;
if (dfx_bus_pci) if (dfx_bus_pci)
pci_set_master(to_pci_dev(bdev)); pci_set_master(to_pci_dev(bdev));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment