Merge branch 'core/rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
[pandora-kernel.git] / drivers / net / macvlan.c
index f651a81..860d75d 100644 (file)
@@ -20,7 +20,7 @@
 #include <linux/errno.h>
 #include <linux/slab.h>
 #include <linux/string.h>
-#include <linux/list.h>
+#include <linux/rculist.h>
 #include <linux/notifier.h>
 #include <linux/netdevice.h>
 #include <linux/etherdevice.h>
@@ -402,7 +402,7 @@ static int macvlan_newlink(struct net_device *dev,
        if (!tb[IFLA_LINK])
                return -EINVAL;
 
-       lowerdev = __dev_get_by_index(dev->nd_net, nla_get_u32(tb[IFLA_LINK]));
+       lowerdev = __dev_get_by_index(dev_net(dev), nla_get_u32(tb[IFLA_LINK]));
        if (lowerdev == NULL)
                return -ENODEV;
 
@@ -450,7 +450,7 @@ static void macvlan_dellink(struct net_device *dev)
        unregister_netdevice(dev);
 
        if (list_empty(&port->vlans))
-               macvlan_port_destroy(dev);
+               macvlan_port_destroy(port->dev);
 }
 
 static struct rtnl_link_ops macvlan_link_ops __read_mostly = {