diff options
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/wan/dlci.c | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/drivers/net/wan/dlci.c b/drivers/net/wan/dlci.c index a1b0b0d7391a..e8d155c3e59f 100644 --- a/drivers/net/wan/dlci.c +++ b/drivers/net/wan/dlci.c | |||
@@ -200,7 +200,7 @@ static int dlci_transmit(struct sk_buff *skb, struct net_device *dev) | |||
200 | 200 | ||
201 | netif_stop_queue(dev); | 201 | netif_stop_queue(dev); |
202 | 202 | ||
203 | ret = dlp->slave->hard_start_xmit(skb, dlp->slave); | 203 | ret = dlp->slave->netdev_ops->ndo_start_xmit(skb, dlp->slave); |
204 | switch (ret) | 204 | switch (ret) |
205 | { | 205 | { |
206 | case DLCI_RET_OK: | 206 | case DLCI_RET_OK: |
@@ -295,11 +295,9 @@ static int dlci_dev_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) | |||
295 | 295 | ||
296 | static int dlci_change_mtu(struct net_device *dev, int new_mtu) | 296 | static int dlci_change_mtu(struct net_device *dev, int new_mtu) |
297 | { | 297 | { |
298 | struct dlci_local *dlp; | 298 | struct dlci_local *dlp = netdev_priv(dev); |
299 | |||
300 | dlp = netdev_priv(dev); | ||
301 | 299 | ||
302 | return((*dlp->slave->change_mtu)(dlp->slave, new_mtu)); | 300 | return dev_set_mtu(dlp->slave, new_mtu); |
303 | } | 301 | } |
304 | 302 | ||
305 | static int dlci_open(struct net_device *dev) | 303 | static int dlci_open(struct net_device *dev) |
@@ -479,17 +477,21 @@ static const struct header_ops dlci_header_ops = { | |||
479 | .create = dlci_header, | 477 | .create = dlci_header, |
480 | }; | 478 | }; |
481 | 479 | ||
480 | static const struct net_device_ops dlci_netdev_ops = { | ||
481 | .ndo_open = dlci_open, | ||
482 | .ndo_stop = dlci_close, | ||
483 | .ndo_do_ioctl = dlci_dev_ioctl, | ||
484 | .ndo_start_xmit = dlci_transmit, | ||
485 | .ndo_change_mtu = dlci_change_mtu, | ||
486 | }; | ||
487 | |||
482 | static void dlci_setup(struct net_device *dev) | 488 | static void dlci_setup(struct net_device *dev) |
483 | { | 489 | { |
484 | struct dlci_local *dlp = netdev_priv(dev); | 490 | struct dlci_local *dlp = netdev_priv(dev); |
485 | 491 | ||
486 | dev->flags = 0; | 492 | dev->flags = 0; |
487 | dev->open = dlci_open; | ||
488 | dev->stop = dlci_close; | ||
489 | dev->do_ioctl = dlci_dev_ioctl; | ||
490 | dev->hard_start_xmit = dlci_transmit; | ||
491 | dev->header_ops = &dlci_header_ops; | 493 | dev->header_ops = &dlci_header_ops; |
492 | dev->change_mtu = dlci_change_mtu; | 494 | dev->netdev_ops = &dlci_netdev_ops; |
493 | dev->destructor = free_netdev; | 495 | dev->destructor = free_netdev; |
494 | 496 | ||
495 | dlp->receive = dlci_receive; | 497 | dlp->receive = dlci_receive; |