Lines Matching refs:rt
148 struct rtable *rt = skb_rtable(skb); in ip_build_and_send_pkt() local
159 iph->ttl = ip_select_ttl(inet, &rt->dst); in ip_build_and_send_pkt()
163 if (ip_dont_fragment(sk, &rt->dst)) { in ip_build_and_send_pkt()
173 ip_options_build(skb, &opt->opt, daddr, rt, 0); in ip_build_and_send_pkt()
188 struct rtable *rt = (struct rtable *)dst; in ip_finish_output2() local
194 if (rt->rt_type == RTN_MULTICAST) { in ip_finish_output2()
196 } else if (rt->rt_type == RTN_BROADCAST) in ip_finish_output2()
222 neigh = ip_neigh_for_gw(rt, skb, &is_v6gw); in ip_finish_output2()
363 struct rtable *rt = skb_rtable(skb); in ip_mc_output() local
364 struct net_device *dev = rt->dst.dev; in ip_mc_output()
378 if (rt->rt_flags&RTCF_MULTICAST) { in ip_mc_output()
390 ((rt->rt_flags & RTCF_LOCAL) || in ip_mc_output()
409 if (rt->rt_flags&RTCF_BROADCAST) { in ip_mc_output()
460 struct rtable *rt; in __ip_queue_xmit() local
470 rt = skb_rtable(skb); in __ip_queue_xmit()
471 if (rt) in __ip_queue_xmit()
475 rt = (struct rtable *)__sk_dst_check(sk, 0); in __ip_queue_xmit()
476 if (!rt) { in __ip_queue_xmit()
488 rt = ip_route_output_ports(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, 0); in __ip_queue_xmit()
771 struct rtable *rt = skb_rtable(skb); in ip_do_fragment() local
800 ll_rs = LL_RESERVED_SPACE(rt->dst.dev); in ip_do_fragment()
976 struct rtable *rt = (struct rtable *)cork->dst; in __ip_append_data() local
983 exthdrlen = !skb ? rt->dst.header_len : 0; in __ip_append_data()
991 hh_len = LL_RESERVED_SPACE(rt->dst.dev); in __ip_append_data()
1009 rt->dst.dev->features & (NETIF_F_HW_CSUM | NETIF_F_IP_CSUM) && in __ip_append_data()
1011 (!exthdrlen || (rt->dst.dev->features & NETIF_F_HW_ESP_TX_CSUM))) in __ip_append_data()
1019 if (rt->dst.dev->features & NETIF_F_SG && in __ip_append_data()
1071 !(rt->dst.dev->features&NETIF_F_SG)) in __ip_append_data()
1088 alloclen += rt->dst.trailer_len; in __ip_append_data()
1170 if (!(rt->dst.dev->features&NETIF_F_SG) && in __ip_append_data()
1239 struct rtable *rt; in ip_setup_cork() local
1241 rt = *rtp; in ip_setup_cork()
1242 if (unlikely(!rt)) in ip_setup_cork()
1262 dst_mtu(&rt->dst) : READ_ONCE(rt->dst.dev->mtu); in ip_setup_cork()
1269 cork->dst = &rt->dst; in ip_setup_cork()
1327 struct rtable *rt; in ip_append_page() local
1346 rt = (struct rtable *)cork->dst; in ip_append_page()
1350 if (!(rt->dst.dev->features&NETIF_F_SG)) in ip_append_page()
1353 hh_len = LL_RESERVED_SPACE(rt->dst.dev); in ip_append_page()
1475 struct rtable *rt = (struct rtable *)cork->dst; in __ip_make_skb() local
1510 (skb->len <= dst_mtu(&rt->dst) && in __ip_make_skb()
1511 ip_dont_fragment(sk, &rt->dst))) in __ip_make_skb()
1519 else if (rt->rt_type == RTN_MULTICAST) in __ip_make_skb()
1522 ttl = ip_select_ttl(inet, &rt->dst); in __ip_make_skb()
1536 ip_options_build(skb, opt, cork->addr, rt, 0); in __ip_make_skb()
1547 skb_dst_set(skb, &rt->dst); in __ip_make_skb()
1665 struct rtable *rt = skb_rtable(skb); in ip_send_unicast_reply() local
1698 rt = ip_route_output_key(net, &fl4); in ip_send_unicast_reply()
1699 if (IS_ERR(rt)) in ip_send_unicast_reply()
1709 len, 0, &ipc, &rt, MSG_DONTWAIT); in ip_send_unicast_reply()
1725 ip_rt_put(rt); in ip_send_unicast_reply()