aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wan
diff options
context:
space:
mode:
authorOctavian Purdila <opurdila@ixiacom.com>2009-11-25 18:14:13 -0500
committerDavid S. Miller <davem@davemloft.net>2009-11-25 18:14:13 -0500
commit09ad9bc752519cc167d0a573e1acf69b5c707c67 (patch)
tree0e190a9ffb90d7e0534136c3e9f31dce02f423c3 /drivers/net/wan
parent4ba3eb034fb6fd1990ccc5a6d71d5abcda37b905 (diff)
net: use net_eq to compare nets
Generated with the following semantic patch @@ struct net *n1; struct net *n2; @@ - n1 == n2 + net_eq(n1, n2) @@ struct net *n1; struct net *n2; @@ - n1 != n2 + !net_eq(n1, n2) applied over {include,net,drivers/net}. Signed-off-by: Octavian Purdila <opurdila@ixiacom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wan')
-rw-r--r--drivers/net/wan/hdlc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wan/hdlc.c b/drivers/net/wan/hdlc.c
index cc07236ea734..9937bbab938d 100644
--- a/drivers/net/wan/hdlc.c
+++ b/drivers/net/wan/hdlc.c
@@ -57,7 +57,7 @@ static int hdlc_rcv(struct sk_buff *skb, struct net_device *dev,
57{ 57{
58 struct hdlc_device *hdlc = dev_to_hdlc(dev); 58 struct hdlc_device *hdlc = dev_to_hdlc(dev);
59 59
60 if (dev_net(dev) != &init_net) { 60 if (!net_eq(dev_net(dev), &init_net)) {
61 kfree_skb(skb); 61 kfree_skb(skb);
62 return 0; 62 return 0;
63 } 63 }
@@ -102,7 +102,7 @@ static int hdlc_device_event(struct notifier_block *this, unsigned long event,
102 unsigned long flags; 102 unsigned long flags;
103 int on; 103 int on;
104 104
105 if (dev_net(dev) != &init_net) 105 if (!net_eq(dev_net(dev), &init_net))
106 return NOTIFY_DONE; 106 return NOTIFY_DONE;
107 107
108 if (!(dev->priv_flags & IFF_WAN_HDLC)) 108 if (!(dev->priv_flags & IFF_WAN_HDLC))