diff options
author | Daniel Lezcano <dlezcano@fr.ibm.com> | 2008-10-29 01:08:19 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-10-29 02:02:33 -0400 |
commit | bb7bba3d56963be59bc6764c8021290ed55205ad (patch) | |
tree | e9fc1c38e37f203d193d0636963ee7fc5d4ce3f8 /drivers/net | |
parent | fdb46ee752ed05c94bac71fe3decdb5175ec6e1f (diff) |
veth: Remove useless veth field
The veth private structure contains a netdev pointer refering to its peer.
This field is never used and it is pointless because if we can access,
the veth_priv, that means we already have the netdev which is stored
in veth_priv->dev.
Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/veth.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/net/veth.c b/drivers/net/veth.c index 31cd817f33f..f7ea5bcefc2 100644 --- a/drivers/net/veth.c +++ b/drivers/net/veth.c | |||
@@ -30,7 +30,6 @@ struct veth_net_stats { | |||
30 | 30 | ||
31 | struct veth_priv { | 31 | struct veth_priv { |
32 | struct net_device *peer; | 32 | struct net_device *peer; |
33 | struct net_device *dev; | ||
34 | struct list_head list; | 33 | struct list_head list; |
35 | struct veth_net_stats *stats; | 34 | struct veth_net_stats *stats; |
36 | unsigned ip_summed; | 35 | unsigned ip_summed; |
@@ -420,12 +419,10 @@ static int veth_newlink(struct net_device *dev, | |||
420 | */ | 419 | */ |
421 | 420 | ||
422 | priv = netdev_priv(dev); | 421 | priv = netdev_priv(dev); |
423 | priv->dev = dev; | ||
424 | priv->peer = peer; | 422 | priv->peer = peer; |
425 | list_add(&priv->list, &veth_list); | 423 | list_add(&priv->list, &veth_list); |
426 | 424 | ||
427 | priv = netdev_priv(peer); | 425 | priv = netdev_priv(peer); |
428 | priv->dev = peer; | ||
429 | priv->peer = dev; | 426 | priv->peer = dev; |
430 | INIT_LIST_HEAD(&priv->list); | 427 | INIT_LIST_HEAD(&priv->list); |
431 | return 0; | 428 | return 0; |