aboutsummaryrefslogtreecommitdiffstats
path: root/net/8021q/vlan.c
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2008-07-08 06:23:57 -0400
committerDavid S. Miller <davem@davemloft.net>2008-07-08 06:23:57 -0400
commit22d1ba74bbafa96d3f425cc12714d3fe8675183f (patch)
tree5fdc18001037a667e95229dbc34130b7210e8c8c /net/8021q/vlan.c
parent7750f403cbe56971336d575b354365190b4e3227 (diff)
vlan: move struct vlan_dev_info to private header
Hide struct vlan_dev_info from drivers to prevent them from growing more creative ways to use it. Provide accessors for the two drivers that currently use it. Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/8021q/vlan.c')
-rw-r--r--net/8021q/vlan.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c
index 8141e2dc510b..7a2625d2f9a0 100644
--- a/net/8021q/vlan.c
+++ b/net/8021q/vlan.c
@@ -543,7 +543,6 @@ static struct notifier_block vlan_notifier_block __read_mostly = {
543static int vlan_ioctl_handler(struct net *net, void __user *arg) 543static int vlan_ioctl_handler(struct net *net, void __user *arg)
544{ 544{
545 int err; 545 int err;
546 unsigned short vid = 0;
547 struct vlan_ioctl_args args; 546 struct vlan_ioctl_args args;
548 struct net_device *dev = NULL; 547 struct net_device *dev = NULL;
549 548
@@ -644,8 +643,7 @@ static int vlan_ioctl_handler(struct net *net, void __user *arg)
644 643
645 case GET_VLAN_VID_CMD: 644 case GET_VLAN_VID_CMD:
646 err = 0; 645 err = 0;
647 vlan_dev_get_vid(dev, &vid); 646 args.u.VID = vlan_dev_vlan_id(dev);
648 args.u.VID = vid;
649 if (copy_to_user(arg, &args, 647 if (copy_to_user(arg, &args,
650 sizeof(struct vlan_ioctl_args))) 648 sizeof(struct vlan_ioctl_args)))
651 err = -EFAULT; 649 err = -EFAULT;