Lines Matching refs:net

87 ip_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
89 int (*output)(struct net *, struct sock *, struct sk_buff *));
99 int __ip_local_out(struct net *net, struct sock *sk, struct sk_buff *skb) in __ip_local_out() argument
106 net, sk, skb, NULL, skb_dst(skb)->dev, in __ip_local_out()
110 int ip_local_out(struct net *net, struct sock *sk, struct sk_buff *skb) in ip_local_out() argument
114 err = __ip_local_out(net, sk, skb); in ip_local_out()
116 err = dst_output(net, sk, skb); in ip_local_out()
140 struct net *net = sock_net(sk); in ip_build_and_send_pkt() local
159 __ip_select_ident(net, iph, 1); in ip_build_and_send_pkt()
171 return ip_local_out(net, skb->sk, skb); in ip_build_and_send_pkt()
175 static int ip_finish_output2(struct net *net, struct sock *sk, struct sk_buff *skb) in ip_finish_output2() argument
185 IP_UPD_PO_STATS(net, IPSTATS_MIB_OUTMCAST, skb->len); in ip_finish_output2()
187 IP_UPD_PO_STATS(net, IPSTATS_MIB_OUTBCAST, skb->len); in ip_finish_output2()
223 static int ip_finish_output_gso(struct net *net, struct sock *sk, in ip_finish_output_gso() argument
233 return ip_finish_output2(net, sk, skb); in ip_finish_output_gso()
257 err = ip_fragment(net, sk, segs, mtu, ip_finish_output2); in ip_finish_output_gso()
267 static int ip_finish_output(struct net *net, struct sock *sk, struct sk_buff *skb) in ip_finish_output() argument
275 return dst_output(net, sk, skb); in ip_finish_output()
280 return ip_finish_output_gso(net, sk, skb, mtu); in ip_finish_output()
283 return ip_fragment(net, sk, skb, mtu, ip_finish_output2); in ip_finish_output()
285 return ip_finish_output2(net, sk, skb); in ip_finish_output()
288 int ip_mc_output(struct net *net, struct sock *sk, struct sk_buff *skb) in ip_mc_output() argument
296 IP_UPD_PO_STATS(net, IPSTATS_MIB_OUT, skb->len); in ip_mc_output()
324 net, sk, newskb, NULL, newskb->dev, in ip_mc_output()
340 net, sk, newskb, NULL, newskb->dev, in ip_mc_output()
345 net, sk, skb, NULL, skb->dev, in ip_mc_output()
350 int ip_output(struct net *net, struct sock *sk, struct sk_buff *skb) in ip_output() argument
354 IP_UPD_PO_STATS(net, IPSTATS_MIB_OUT, skb->len); in ip_output()
360 net, sk, skb, NULL, dev, in ip_output()
383 struct net *net = sock_net(sk); in ip_queue_xmit() local
414 rt = ip_route_output_ports(net, fl4, sk, in ip_queue_xmit()
451 ip_select_ident_segs(net, skb, sk, in ip_queue_xmit()
458 res = ip_local_out(net, sk, skb); in ip_queue_xmit()
464 IP_INC_STATS(net, IPSTATS_MIB_OUTNOROUTES); in ip_queue_xmit()
493 static int ip_fragment(struct net *net, struct sock *sk, struct sk_buff *skb, in ip_fragment() argument
495 int (*output)(struct net *, struct sock *, struct sk_buff *)) in ip_fragment() argument
500 return ip_do_fragment(net, sk, skb, output); in ip_fragment()
505 IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS); in ip_fragment()
512 return ip_do_fragment(net, sk, skb, output); in ip_fragment()
522 int ip_do_fragment(struct net *net, struct sock *sk, struct sk_buff *skb, in ip_do_fragment() argument
523 int (*output)(struct net *, struct sock *, struct sk_buff *)) in ip_do_fragment() argument
630 err = output(net, sk, skb); in ip_do_fragment()
633 IP_INC_STATS(net, IPSTATS_MIB_FRAGCREATES); in ip_do_fragment()
643 IP_INC_STATS(net, IPSTATS_MIB_FRAGOKS); in ip_do_fragment()
652 IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS); in ip_do_fragment()
767 err = output(net, sk, skb2); in ip_do_fragment()
771 IP_INC_STATS(net, IPSTATS_MIB_FRAGCREATES); in ip_do_fragment()
774 IP_INC_STATS(net, IPSTATS_MIB_FRAGOKS); in ip_do_fragment()
779 IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS); in ip_do_fragment()
1356 struct net *net = sock_net(sk); in __ip_make_skb() local
1415 ip_select_ident(net, skb, sk); in __ip_make_skb()
1432 icmp_out_count(net, ((struct icmphdr *) in __ip_make_skb()
1440 int ip_send_skb(struct net *net, struct sk_buff *skb) in ip_send_skb() argument
1444 err = ip_local_out(net, skb->sk, skb); in ip_send_skb()
1449 IP_INC_STATS(net, IPSTATS_MIB_OUTDISCARDS); in ip_send_skb()
1549 struct net *net = sock_net(sk); in ip_send_unicast_reply() local
1571 if (!oif && netif_index_is_l3_master(net, skb->skb_iif)) in ip_send_unicast_reply()
1575 IP4_REPLY_MARK(net, skb->mark), in ip_send_unicast_reply()
1582 rt = ip_route_output_key(net, &fl4); in ip_send_unicast_reply()