aboutsummaryrefslogtreecommitdiffstats
path: root/net/decnet/dn_neigh.c
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2015-09-15 21:04:18 -0400
committerDavid S. Miller <davem@davemloft.net>2015-09-17 20:18:37 -0400
commit0c4b51f0054ce85c0ec578ab818f0631834573eb (patch)
tree73e729f58fbaf6420e0f390e36aa936ddaa219ef /net/decnet/dn_neigh.c
parent9dff2c966a0a79a4222553a851f17e679fc28a43 (diff)
netfilter: Pass net into okfn
This is immediately motivated by the bridge code that chains functions that call into netfilter. Without passing net into the okfns the bridge code would need to guess about the best expression for the network namespace to process packets in. As net is frequently one of the first things computed in continuation functions after netfilter has done it's job passing in the desired network namespace is in many cases a code simplification. To support this change the function dst_output_okfn is introduced to simplify passing dst_output as an okfn. For the moment dst_output_okfn just silently drops the struct net. Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/decnet/dn_neigh.c')
-rw-r--r--net/decnet/dn_neigh.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/net/decnet/dn_neigh.c b/net/decnet/dn_neigh.c
index 305ab2fe25cd..482730cd8a56 100644
--- a/net/decnet/dn_neigh.c
+++ b/net/decnet/dn_neigh.c
@@ -194,7 +194,7 @@ static int dn_neigh_output(struct neighbour *neigh, struct sk_buff *skb)
194 return err; 194 return err;
195} 195}
196 196
197static int dn_neigh_output_packet(struct sock *sk, struct sk_buff *skb) 197static int dn_neigh_output_packet(struct net *net, struct sock *sk, struct sk_buff *skb)
198{ 198{
199 struct dst_entry *dst = skb_dst(skb); 199 struct dst_entry *dst = skb_dst(skb);
200 struct dn_route *rt = (struct dn_route *)dst; 200 struct dn_route *rt = (struct dn_route *)dst;
@@ -334,7 +334,7 @@ static int dn_phase3_output(struct neighbour *neigh, struct sock *sk,
334 dn_neigh_output_packet); 334 dn_neigh_output_packet);
335} 335}
336 336
337int dn_to_neigh_output(struct sock *sk, struct sk_buff *skb) 337int dn_to_neigh_output(struct net *net, struct sock *sk, struct sk_buff *skb)
338{ 338{
339 struct dst_entry *dst = skb_dst(skb); 339 struct dst_entry *dst = skb_dst(skb);
340 struct dn_route *rt = (struct dn_route *) dst; 340 struct dn_route *rt = (struct dn_route *) dst;
@@ -378,7 +378,7 @@ void dn_neigh_pointopoint_hello(struct sk_buff *skb)
378/* 378/*
379 * Ethernet router hello message received 379 * Ethernet router hello message received
380 */ 380 */
381int dn_neigh_router_hello(struct sock *sk, struct sk_buff *skb) 381int dn_neigh_router_hello(struct net *net, struct sock *sk, struct sk_buff *skb)
382{ 382{
383 struct rtnode_hello_message *msg = (struct rtnode_hello_message *)skb->data; 383 struct rtnode_hello_message *msg = (struct rtnode_hello_message *)skb->data;
384 384
@@ -440,7 +440,7 @@ int dn_neigh_router_hello(struct sock *sk, struct sk_buff *skb)
440/* 440/*
441 * Endnode hello message received 441 * Endnode hello message received
442 */ 442 */
443int dn_neigh_endnode_hello(struct sock *sk, struct sk_buff *skb) 443int dn_neigh_endnode_hello(struct net *net, struct sock *sk, struct sk_buff *skb)
444{ 444{
445 struct endnode_hello_message *msg = (struct endnode_hello_message *)skb->data; 445 struct endnode_hello_message *msg = (struct endnode_hello_message *)skb->data;
446 struct neighbour *neigh; 446 struct neighbour *neigh;