aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ppp_generic.c
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2008-11-20 01:22:30 -0500
committerDavid S. Miller <davem@davemloft.net>2008-11-20 01:42:54 -0500
commit52256cfc9f81cd8713e00a0713e68347bbffba5a (patch)
treee64dcced61c3e7a2bef8219e0ac8f86888faccd4 /drivers/net/ppp_generic.c
parentacc784263b0c46f3052fb4f155fdfe39b7001c98 (diff)
ppp: convert to net_device_ops
Convert this driver to network device ops. Compile tested only. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ppp_generic.c')
-rw-r--r--drivers/net/ppp_generic.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/net/ppp_generic.c b/drivers/net/ppp_generic.c
index 274d495a1c50..c1e57c093e08 100644
--- a/drivers/net/ppp_generic.c
+++ b/drivers/net/ppp_generic.c
@@ -971,8 +971,13 @@ ppp_net_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
971 return err; 971 return err;
972} 972}
973 973
974static const struct net_device_ops ppp_netdev_ops = {
975 .ndo_do_ioctl = ppp_net_ioctl,
976};
977
974static void ppp_setup(struct net_device *dev) 978static void ppp_setup(struct net_device *dev)
975{ 979{
980 dev->netdev_ops = &ppp_netdev_ops;
976 dev->hard_header_len = PPP_HDRLEN; 981 dev->hard_header_len = PPP_HDRLEN;
977 dev->mtu = PPP_MTU; 982 dev->mtu = PPP_MTU;
978 dev->addr_len = 0; 983 dev->addr_len = 0;
@@ -2436,7 +2441,6 @@ ppp_create_interface(int unit, int *retp)
2436 dev->priv = ppp; 2441 dev->priv = ppp;
2437 2442
2438 dev->hard_start_xmit = ppp_start_xmit; 2443 dev->hard_start_xmit = ppp_start_xmit;
2439 dev->do_ioctl = ppp_net_ioctl;
2440 2444
2441 ret = -EEXIST; 2445 ret = -EEXIST;
2442 mutex_lock(&all_ppp_mutex); 2446 mutex_lock(&all_ppp_mutex);