Lines Matching refs:rt

154 	struct rtable *rt = skb_rtable(skb);  in ip_build_and_send_pkt()  local
165 iph->ttl = ip_select_ttl(inet, &rt->dst); in ip_build_and_send_pkt()
170 if (skb->len <= IPV4_MIN_MTU || ip_dont_fragment(sk, &rt->dst)) { in ip_build_and_send_pkt()
186 ip_options_build(skb, &opt->opt, daddr, rt); in ip_build_and_send_pkt()
201 struct rtable *rt = dst_rtable(dst); in ip_finish_output2() local
207 if (rt->rt_type == RTN_MULTICAST) { in ip_finish_output2()
209 } else if (rt->rt_type == RTN_BROADCAST) in ip_finish_output2()
229 neigh = ip_neigh_for_gw(rt, skb, &is_v6gw); in ip_finish_output2()
368 struct rtable *rt = skb_rtable(skb); in ip_mc_output() local
369 struct net_device *dev = rt->dst.dev; in ip_mc_output()
381 if (rt->rt_flags&RTCF_MULTICAST) { in ip_mc_output()
393 ((rt->rt_flags & RTCF_LOCAL) || in ip_mc_output()
412 if (rt->rt_flags&RTCF_BROADCAST) { in ip_mc_output()
468 struct rtable *rt; in __ip_queue_xmit() local
478 rt = skb_rtable(skb); in __ip_queue_xmit()
479 if (rt) in __ip_queue_xmit()
483 rt = dst_rtable(__sk_dst_check(sk, 0)); in __ip_queue_xmit()
484 if (!rt) { in __ip_queue_xmit()
494 rt = ip_route_output_flow(net, fl4, sk); in __ip_queue_xmit()
495 if (IS_ERR(rt)) in __ip_queue_xmit()
497 sk_setup_caps(sk, &rt->dst); in __ip_queue_xmit()
499 skb_dst_set_noref(skb, &rt->dst); in __ip_queue_xmit()
502 if (inet_opt && inet_opt->opt.is_strictroute && rt->rt_uses_gateway) in __ip_queue_xmit()
510 if (ip_dont_fragment(sk, &rt->dst) && !skb->ignore_df) in __ip_queue_xmit()
514 iph->ttl = ip_select_ttl(inet, &rt->dst); in __ip_queue_xmit()
522 ip_options_build(skb, &inet_opt->opt, inet->inet_daddr, rt); in __ip_queue_xmit()
765 struct rtable *rt = skb_rtable(skb); in ip_do_fragment() local
794 ll_rs = LL_RESERVED_SPACE(rt->dst.dev); in ip_do_fragment()
971 struct rtable *rt = dst_rtable(cork->dst); in __ip_append_data() local
978 exthdrlen = !skb ? rt->dst.header_len : 0; in __ip_append_data()
982 hh_len = LL_RESERVED_SPACE(rt->dst.dev); in __ip_append_data()
1000 rt->dst.dev->features & (NETIF_F_HW_CSUM | NETIF_F_IP_CSUM) && in __ip_append_data()
1002 (!exthdrlen || (rt->dst.dev->features & NETIF_F_HW_ESP_TX_CSUM))) in __ip_append_data()
1015 if ((rt->dst.dev->features & NETIF_F_SG) && in __ip_append_data()
1027 if (rt->dst.dev->features & NETIF_F_SG && in __ip_append_data()
1039 if (rt->dst.dev->features & NETIF_F_SG && in __ip_append_data()
1108 alloc_extra += rt->dst.trailer_len; in __ip_append_data()
1111 !(rt->dst.dev->features&NETIF_F_SG)) in __ip_append_data()
1115 !(rt->dst.dev->features & NETIF_F_SG))) in __ip_append_data()
1211 if (!(rt->dst.dev->features&NETIF_F_SG) && in __ip_append_data()
1294 struct rtable *rt; in ip_setup_cork() local
1296 rt = *rtp; in ip_setup_cork()
1297 if (unlikely(!rt)) in ip_setup_cork()
1301 dst_mtu(&rt->dst) : READ_ONCE(rt->dst.dev->mtu); in ip_setup_cork()
1324 cork->dst = &rt->dst; in ip_setup_cork()
1404 struct rtable *rt = dst_rtable(cork->dst); in __ip_make_skb() local
1440 (skb->len <= dst_mtu(&rt->dst) && in __ip_make_skb()
1441 ip_dont_fragment(sk, &rt->dst))) in __ip_make_skb()
1449 else if (rt->rt_type == RTN_MULTICAST) in __ip_make_skb()
1452 ttl = ip_select_ttl(inet, &rt->dst); in __ip_make_skb()
1466 ip_options_build(skb, opt, cork->addr, rt); in __ip_make_skb()
1480 skb_dst_set(skb, &rt->dst); in __ip_make_skb()
1610 struct rtable *rt = skb_rtable(skb); in ip_send_unicast_reply() local
1643 rt = ip_route_output_flow(net, &fl4, sk); in ip_send_unicast_reply()
1644 if (IS_ERR(rt)) in ip_send_unicast_reply()
1654 len, 0, &ipc, &rt, MSG_DONTWAIT); in ip_send_unicast_reply()
1676 ip_rt_put(rt); in ip_send_unicast_reply()