aboutsummaryrefslogtreecommitdiffstats
path: root/net/core/neighbour.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/core/neighbour.c')
-rw-r--r--net/core/neighbour.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/net/core/neighbour.c b/net/core/neighbour.c
index c978bd1cd659..065fbac7ecd3 100644
--- a/net/core/neighbour.c
+++ b/net/core/neighbour.c
@@ -1478,7 +1478,7 @@ int neigh_table_clear(struct neigh_table *tbl)
1478 1478
1479static int neigh_delete(struct sk_buff *skb, struct nlmsghdr *nlh, void *arg) 1479static int neigh_delete(struct sk_buff *skb, struct nlmsghdr *nlh, void *arg)
1480{ 1480{
1481 struct net *net = skb->sk->sk_net; 1481 struct net *net = sock_net(skb->sk);
1482 struct ndmsg *ndm; 1482 struct ndmsg *ndm;
1483 struct nlattr *dst_attr; 1483 struct nlattr *dst_attr;
1484 struct neigh_table *tbl; 1484 struct neigh_table *tbl;
@@ -1544,7 +1544,7 @@ out:
1544 1544
1545static int neigh_add(struct sk_buff *skb, struct nlmsghdr *nlh, void *arg) 1545static int neigh_add(struct sk_buff *skb, struct nlmsghdr *nlh, void *arg)
1546{ 1546{
1547 struct net *net = skb->sk->sk_net; 1547 struct net *net = sock_net(skb->sk);
1548 struct ndmsg *ndm; 1548 struct ndmsg *ndm;
1549 struct nlattr *tb[NDA_MAX+1]; 1549 struct nlattr *tb[NDA_MAX+1];
1550 struct neigh_table *tbl; 1550 struct neigh_table *tbl;
@@ -1812,7 +1812,7 @@ static const struct nla_policy nl_ntbl_parm_policy[NDTPA_MAX+1] = {
1812 1812
1813static int neightbl_set(struct sk_buff *skb, struct nlmsghdr *nlh, void *arg) 1813static int neightbl_set(struct sk_buff *skb, struct nlmsghdr *nlh, void *arg)
1814{ 1814{
1815 struct net *net = skb->sk->sk_net; 1815 struct net *net = sock_net(skb->sk);
1816 struct neigh_table *tbl; 1816 struct neigh_table *tbl;
1817 struct ndtmsg *ndtmsg; 1817 struct ndtmsg *ndtmsg;
1818 struct nlattr *tb[NDTA_MAX+1]; 1818 struct nlattr *tb[NDTA_MAX+1];
@@ -1937,7 +1937,7 @@ errout:
1937 1937
1938static int neightbl_dump_info(struct sk_buff *skb, struct netlink_callback *cb) 1938static int neightbl_dump_info(struct sk_buff *skb, struct netlink_callback *cb)
1939{ 1939{
1940 struct net *net = skb->sk->sk_net; 1940 struct net *net = sock_net(skb->sk);
1941 int family, tidx, nidx = 0; 1941 int family, tidx, nidx = 0;
1942 int tbl_skip = cb->args[0]; 1942 int tbl_skip = cb->args[0];
1943 int neigh_skip = cb->args[1]; 1943 int neigh_skip = cb->args[1];
@@ -2037,7 +2037,7 @@ static void neigh_update_notify(struct neighbour *neigh)
2037static int neigh_dump_table(struct neigh_table *tbl, struct sk_buff *skb, 2037static int neigh_dump_table(struct neigh_table *tbl, struct sk_buff *skb,
2038 struct netlink_callback *cb) 2038 struct netlink_callback *cb)
2039{ 2039{
2040 struct net * net = skb->sk->sk_net; 2040 struct net * net = sock_net(skb->sk);
2041 struct neighbour *n; 2041 struct neighbour *n;
2042 int rc, h, s_h = cb->args[1]; 2042 int rc, h, s_h = cb->args[1];
2043 int idx, s_idx = idx = cb->args[2]; 2043 int idx, s_idx = idx = cb->args[2];