aboutsummaryrefslogtreecommitdiffstats
path: root/net/netrom
diff options
context:
space:
mode:
Diffstat (limited to 'net/netrom')
-rw-r--r--net/netrom/nr_dev.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/net/netrom/nr_dev.c b/net/netrom/nr_dev.c
index 5b9a31a6e685..351372463fed 100644
--- a/net/netrom/nr_dev.c
+++ b/net/netrom/nr_dev.c
@@ -191,19 +191,21 @@ static const struct header_ops nr_header_ops = {
191 .rebuild= nr_rebuild_header, 191 .rebuild= nr_rebuild_header,
192}; 192};
193 193
194static const struct net_device_ops nr_netdev_ops = {
195 .ndo_open = nr_open,
196 .ndo_stop = nr_close,
197 .ndo_start_xmit = nr_xmit,
198 .ndo_set_mac_address = nr_set_mac_address,
199};
194 200
195void nr_setup(struct net_device *dev) 201void nr_setup(struct net_device *dev)
196{ 202{
197 dev->mtu = NR_MAX_PACKET_SIZE; 203 dev->mtu = NR_MAX_PACKET_SIZE;
198 dev->hard_start_xmit = nr_xmit; 204 dev->netdev_ops = &nr_netdev_ops;
199 dev->open = nr_open;
200 dev->stop = nr_close;
201
202 dev->header_ops = &nr_header_ops; 205 dev->header_ops = &nr_header_ops;
203 dev->hard_header_len = NR_NETWORK_LEN + NR_TRANSPORT_LEN; 206 dev->hard_header_len = NR_NETWORK_LEN + NR_TRANSPORT_LEN;
204 dev->addr_len = AX25_ADDR_LEN; 207 dev->addr_len = AX25_ADDR_LEN;
205 dev->type = ARPHRD_NETROM; 208 dev->type = ARPHRD_NETROM;
206 dev->set_mac_address = nr_set_mac_address;
207 209
208 /* New-style flags. */ 210 /* New-style flags. */
209 dev->flags = IFF_NOARP; 211 dev->flags = IFF_NOARP;