]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - net/netrom/af_netrom.c
netns: Use net_eq() to compare net-namespaces for optimization.
[net-next-2.6.git] / net / netrom / af_netrom.c
index d41be0d66eb0f8f9f5c08b140d2db556f61224ff..fccc250f95f5e8e111d17b4dca1f0d2570e28507 100644 (file)
@@ -118,7 +118,7 @@ static int nr_device_event(struct notifier_block *this, unsigned long event, voi
 {
        struct net_device *dev = (struct net_device *)ptr;
 
-       if (dev_net(dev) != &init_net)
+       if (!net_eq(dev_net(dev), &init_net))
                return NOTIFY_DONE;
 
        if (event != NETDEV_DOWN)