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

6pack: convert to net_device_ops

Signed-off-by: default avatarStephen Hemminger <shemminger@vyatta.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent bc0443fc
...@@ -322,23 +322,25 @@ static const struct header_ops sp_header_ops = { ...@@ -322,23 +322,25 @@ static const struct header_ops sp_header_ops = {
.rebuild = sp_rebuild_header, .rebuild = sp_rebuild_header,
}; };
static const struct net_device_ops sp_netdev_ops = {
.ndo_open = sp_open_dev,
.ndo_stop = sp_close,
.ndo_start_xmit = sp_xmit,
.ndo_set_mac_address = sp_set_mac_address,
};
static void sp_setup(struct net_device *dev) static void sp_setup(struct net_device *dev)
{ {
/* Finish setting up the DEVICE info. */ /* Finish setting up the DEVICE info. */
dev->mtu = SIXP_MTU; dev->netdev_ops = &sp_netdev_ops;
dev->hard_start_xmit = sp_xmit;
dev->open = sp_open_dev;
dev->destructor = free_netdev; dev->destructor = free_netdev;
dev->stop = sp_close; dev->mtu = SIXP_MTU;
dev->set_mac_address = sp_set_mac_address;
dev->hard_header_len = AX25_MAX_HEADER_LEN; dev->hard_header_len = AX25_MAX_HEADER_LEN;
dev->header_ops = &sp_header_ops; dev->header_ops = &sp_header_ops;
dev->addr_len = AX25_ADDR_LEN; dev->addr_len = AX25_ADDR_LEN;
dev->type = ARPHRD_AX25; dev->type = ARPHRD_AX25;
dev->tx_queue_len = 10; dev->tx_queue_len = 10;
dev->tx_timeout = NULL;
/* Only activated in AX.25 mode */ /* Only activated in AX.25 mode */
memcpy(dev->broadcast, &ax25_bcast, AX25_ADDR_LEN); memcpy(dev->broadcast, &ax25_bcast, AX25_ADDR_LEN);
......
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