/linux-6.3-rc2/include/net/ |
A D | flow.h | 100 fl4->flowi4_oif = oif; in flowi4_init_output() 102 fl4->flowi4_l3mdev = 0; in flowi4_init_output() 104 fl4->flowi4_tos = tos; in flowi4_init_output() 108 fl4->flowi4_secid = 0; in flowi4_init_output() 110 fl4->flowi4_uid = uid; in flowi4_init_output() 111 fl4->daddr = daddr; in flowi4_init_output() 112 fl4->saddr = saddr; in flowi4_init_output() 122 fl4->flowi4_oif = oif; in flowi4_update_output() 123 fl4->flowi4_tos = tos; in flowi4_update_output() 124 fl4->daddr = daddr; in flowi4_update_output() [all …]
|
A D | route.h | 159 struct flowi4 fl4 = { in ip_route_output() local 187 memset(fl4, 0, sizeof(*fl4)); in ip_route_output_gre() 188 fl4->flowi4_oif = oif; in ip_route_output_gre() 189 fl4->daddr = daddr; in ip_route_output_gre() 190 fl4->saddr = saddr; in ip_route_output_gre() 191 fl4->flowi4_tos = tos; in ip_route_output_gre() 327 flowi4_update_output(fl4, oif, fl4->flowi4_tos, fl4->daddr, in ip_route_connect() 328 fl4->saddr); in ip_route_connect() 340 fl4->fl4_dport = dport; in ip_route_newports() 341 fl4->fl4_sport = sport; in ip_route_newports() [all …]
|
A D | ip_tunnels.h | 252 memset(fl4, 0, sizeof(*fl4)); in ip_tunnel_init_flow() 257 fl4->flowi4_oif = fl4->flowi4_l3mdev ? 0 : oif; in ip_tunnel_init_flow() 260 fl4->daddr = daddr; in ip_tunnel_init_flow() 261 fl4->saddr = saddr; in ip_tunnel_init_flow() 262 fl4->flowi4_tos = tos; in ip_tunnel_init_flow() 263 fl4->flowi4_proto = proto; in ip_tunnel_init_flow() 264 fl4->fl4_gre_key = key; in ip_tunnel_init_flow() 265 fl4->flowi4_mark = mark; in ip_tunnel_init_flow() 267 fl4->flowi4_flags = flow_flags; in ip_tunnel_init_flow() 317 u8 *protocol, struct flowi4 *fl4); [all …]
|
A D | ip_fib.h | 352 struct flowi4 *fl4, in fib4_rules_early_flow_dissect() argument 413 struct flowi4 *fl4, in fib4_rules_early_flow_dissect() argument 422 fl4->fl4_sport = flkeys->ports.src; in fib4_rules_early_flow_dissect() 423 fl4->fl4_dport = flkeys->ports.dst; in fib4_rules_early_flow_dissect() 424 fl4->flowi4_proto = flkeys->basic.ip_proto; in fib4_rules_early_flow_dissect() 516 int fib_multipath_hash(const struct net *net, const struct flowi4 *fl4, 523 struct flowi4 *fl4, const struct sk_buff *skb);
|
/linux-6.3-rc2/net/ipv4/ |
A D | netfilter.c | 24 struct flowi4 fl4 = {}; in ip_route_me_harder() local 44 fl4.daddr = iph->daddr; in ip_route_me_harder() 45 fl4.saddr = saddr; in ip_route_me_harder() 46 fl4.flowi4_tos = RT_TOS(iph->tos); in ip_route_me_harder() 47 fl4.flowi4_oif = sk ? sk->sk_bound_dev_if : 0; in ip_route_me_harder() 48 fl4.flowi4_l3mdev = l3mdev_master_ifindex(dev); in ip_route_me_harder() 49 fl4.flowi4_mark = skb->mark; in ip_route_me_harder() 50 fl4.flowi4_flags = flags; in ip_route_me_harder() 51 fib4_rules_early_flow_dissect(net, skb, &fl4, &flkeys); in ip_route_me_harder() 52 rt = ip_route_output_key(net, &fl4); in ip_route_me_harder() [all …]
|
A D | route.c | 2042 u32 multipath_hash = fl4 ? fl4->flowi4_multipath_hash : 0; in fib_multipath_hash() 2540 if (!ip_check_mc_rcu(in_dev, fl4->daddr, fl4->saddr, in __mkroute_output() 2743 fl4->daddr = fl4->saddr; in ip_route_output_key_hash_rcu() 2745 fl4->daddr = fl4->saddr = htonl(INADDR_LOOPBACK); in ip_route_output_key_hash_rcu() 2758 (ipv4_is_multicast(fl4->daddr) || !fl4->flowi4_l3mdev)) { in ip_route_output_key_hash_rcu() 2792 fl4->saddr = fl4->daddr; in ip_route_output_key_hash_rcu() 2910 memset(&fl4, 0, sizeof(fl4)); in ip_route_output_tunnel() 2957 r->rtm_tos = fl4 ? fl4->flowi4_tos : 0; in rt_fill_info() 3030 if (fl4) { in rt_fill_info() 3047 fl4->saddr, fl4->daddr, in rt_fill_info() [all …]
|
A D | xfrm4_policy.c | 28 memset(fl4, 0, sizeof(*fl4)); in __xfrm4_dst_lookup() 29 fl4->daddr = daddr->a4; in __xfrm4_dst_lookup() 30 fl4->flowi4_tos = tos; in __xfrm4_dst_lookup() 32 fl4->flowi4_mark = mark; in __xfrm4_dst_lookup() 34 fl4->saddr = saddr->a4; in __xfrm4_dst_lookup() 36 rt = __ip_route_output_key(net, fl4); in __xfrm4_dst_lookup() 48 struct flowi4 fl4; in xfrm4_dst_lookup() local 58 struct flowi4 fl4; in xfrm4_get_saddr() local 64 saddr->a4 = fl4.saddr; in xfrm4_get_saddr() 73 const struct flowi4 *fl4 = &fl->u.ip4; in xfrm4_fill_dst() local [all …]
|
A D | icmp.c | 402 struct flowi4 fl4; in icmp_reply() local 438 memset(&fl4, 0, sizeof(fl4)); in icmp_reply() 439 fl4.daddr = daddr; in icmp_reply() 440 fl4.saddr = saddr; in icmp_reply() 441 fl4.flowi4_mark = mark; in icmp_reply() 477 struct flowi4 *fl4, in icmp_route_lookup() argument 489 memset(fl4, 0, sizeof(*fl4)); in icmp_route_lookup() 492 fl4->saddr = saddr; in icmp_route_lookup() 558 memcpy(fl4, &fl4_dec, sizeof(*fl4)); in icmp_route_lookup() 595 struct flowi4 fl4; in __icmp_send() local [all …]
|
A D | datagram.c | 23 struct flowi4 *fl4; in __ip4_datagram_connect() local 48 fl4 = &inet->cork.fl.u.ip4; in __ip4_datagram_connect() 49 rt = ip_route_connect(fl4, usin->sin_addr.s_addr, saddr, oif, in __ip4_datagram_connect() 65 inet->inet_saddr = fl4->saddr; /* Update source address */ in __ip4_datagram_connect() 67 inet->inet_rcv_saddr = fl4->saddr; in __ip4_datagram_connect() 71 inet->inet_daddr = fl4->daddr; in __ip4_datagram_connect() 106 struct flowi4 fl4; in ip4_datagram_release_cb() local 119 rt = ip_route_output_ports(sock_net(sk), &fl4, sk, daddr, in ip4_datagram_release_cb()
|
A D | fib_frontend.c | 292 struct flowi4 fl4 = { in fib_compute_spec_dst() local 352 struct flowi4 fl4; in __fib_validate_source() local 355 fl4.flowi4_oif = 0; in __fib_validate_source() 358 fl4.daddr = src; in __fib_validate_source() 359 fl4.saddr = dst; in __fib_validate_source() 360 fl4.flowi4_tos = tos; in __fib_validate_source() 363 fl4.flowi4_flags = 0; in __fib_validate_source() 371 fl4.flowi4_proto = 0; in __fib_validate_source() 372 fl4.fl4_sport = 0; in __fib_validate_source() 373 fl4.fl4_dport = 0; in __fib_validate_source() [all …]
|
A D | ip_output.c | 446 offsetof(typeof(*fl4), saddr) + sizeof(fl4->saddr)); in ip_copy_addrs() 448 iph->saddr = fl4->saddr; in ip_copy_addrs() 449 iph->daddr = fl4->daddr; in ip_copy_addrs() 459 struct flowi4 *fl4; in __ip_queue_xmit() local 469 fl4 = &fl->u.ip4; in __ip_queue_xmit() 516 ip_copy_addrs(iph, fl4); in __ip_queue_xmit() 960 struct flowi4 *fl4, in __ip_append_data() argument 1490 struct flowi4 *fl4, in __ip_make_skb() argument 1555 ip_copy_addrs(iph, fl4); in __ip_make_skb() 1630 struct flowi4 *fl4, in ip_make_skb() argument [all …]
|
A D | fib_rules.c | 181 struct flowi4 *fl4 = &fl->u.ip4; in fib4_rule_match() local 182 __be32 daddr = fl4->daddr; in fib4_rule_match() 183 __be32 saddr = fl4->saddr; in fib4_rule_match() 189 if (r->dscp && r->dscp != inet_dsfield_to_dscp(fl4->flowi4_tos)) in fib4_rule_match() 192 if (rule->ip_proto && (rule->ip_proto != fl4->flowi4_proto)) in fib4_rule_match() 196 !fib_rule_port_inrange(&rule->sport_range, fl4->fl4_sport)) in fib4_rule_match() 200 !fib_rule_port_inrange(&rule->dport_range, fl4->fl4_dport)) in fib4_rule_match()
|
A D | raw.c | 390 iph->saddr = fl4->saddr; in raw_send_hdrinc() 427 if (fl4->flowi4_proto != IPPROTO_ICMP) in raw_probe_proto_opt() 437 fl4->fl4_icmp_type = rfv->hdr.icmph.type; in raw_probe_proto_opt() 438 fl4->fl4_icmp_code = rfv->hdr.icmph.code; in raw_probe_proto_opt() 480 struct flowi4 fl4; in raw_sendmsg() local 613 err = raw_probe_proto_opt(&rfv, &fl4); in raw_sendmsg() 619 rt = ip_route_output_flow(net, &fl4, sk); in raw_sendmsg() 635 err = raw_send_hdrinc(sk, &fl4, msg, len, in raw_sendmsg() 640 ipc.addr = fl4.daddr; in raw_sendmsg() 648 err = ip_push_pending_frames(sk, &fl4); in raw_sendmsg() [all …]
|
A D | ip_tunnel.c | 292 struct flowi4 fl4; in ip_tunnel_bind_dev() local 299 rt = ip_route_output_key(tunnel->net, &fl4); in ip_tunnel_bind_dev() 552 struct flowi4 fl4; in ip_md_tunnel_xmit() local 589 fl4.saddr); in ip_md_tunnel_xmit() 624 iptunnel_xmit(NULL, rt, skb, fl4.saddr, fl4.daddr, proto, tos, ttl, in ip_md_tunnel_xmit() 647 struct flowi4 fl4; in ip_tunnel_xmit() local 742 &fl4.saddr); in ip_tunnel_xmit() 745 &fl4.saddr) : NULL; in ip_tunnel_xmit() 757 fl4.saddr); in ip_tunnel_xmit() 760 fl4.saddr); in ip_tunnel_xmit() [all …]
|
A D | syncookies.c | 339 struct flowi4 fl4; in cookie_v4_check() local 420 flowi4_init_output(&fl4, ireq->ir_iif, ireq->ir_mark, in cookie_v4_check() 425 security_req_classify_flow(req, flowi4_to_flowi_common(&fl4)); in cookie_v4_check() 426 rt = ip_route_output_key(sock_net(sk), &fl4); in cookie_v4_check() 453 inet_sk(ret)->cork.fl.u.ip4 = fl4; in cookie_v4_check()
|
/linux-6.3-rc2/net/ipv4/netfilter/ |
A D | nf_dup_ipv4.c | 28 struct flowi4 fl4; in nf_dup_ipv4_route() local 30 memset(&fl4, 0, sizeof(fl4)); in nf_dup_ipv4_route() 32 fl4.flowi4_oif = oif; in nf_dup_ipv4_route() 34 fl4.daddr = gw->s_addr; in nf_dup_ipv4_route() 35 fl4.flowi4_tos = RT_TOS(iph->tos); in nf_dup_ipv4_route() 36 fl4.flowi4_scope = RT_SCOPE_UNIVERSE; in nf_dup_ipv4_route() 37 fl4.flowi4_flags = FLOWI_FLAG_KNOWN_NH; in nf_dup_ipv4_route() 38 rt = ip_route_output_key(net, &fl4); in nf_dup_ipv4_route()
|
A D | nft_fib_ipv4.c | 65 struct flowi4 fl4 = { in nft_fib4_eval() local 88 fl4.flowi4_l3mdev = l3mdev_master_ifindex_rcu(oif); in nft_fib4_eval() 111 fl4.flowi4_mark = pkt->skb->mark; in nft_fib4_eval() 113 fl4.flowi4_tos = iph->tos & DSCP_BITS; in nft_fib4_eval() 116 fl4.daddr = iph->daddr; in nft_fib4_eval() 117 fl4.saddr = get_saddr(iph->saddr); in nft_fib4_eval() 121 fl4.flowi4_iif = nft_out(pkt)->ifindex; in nft_fib4_eval() 123 fl4.daddr = iph->saddr; in nft_fib4_eval() 124 fl4.saddr = get_saddr(iph->daddr); in nft_fib4_eval() 129 if (fib_lookup(nft_net(pkt), &fl4, &res, FIB_LOOKUP_IGNORE_LINKSTATE)) in nft_fib4_eval()
|
/linux-6.3-rc2/drivers/net/ |
A D | gtp.c | 242 memset(fl4, 0, sizeof(*fl4)); in ip4_route_output_gtp() 244 fl4->daddr = daddr; in ip4_route_output_gtp() 245 fl4->saddr = saddr; in ip4_route_output_gtp() 299 struct flowi4 fl4; in gtp0_send_echo_resp() local 340 fl4.saddr, fl4.daddr, in gtp0_send_echo_resp() 479 struct flowi4 fl4; in gtp1u_send_echo_resp() local 522 fl4.saddr, fl4.daddr, in gtp1u_send_echo_resp() 806 pktinfo->fl4 = *fl4; in gtp_set_pktinfo_ipv4() 816 struct flowi4 fl4; in gtp_build_skb_ip4() local 922 pktinfo.fl4.saddr, pktinfo.fl4.daddr, in gtp_dev_xmit() [all …]
|
A D | geneve.c | 795 struct flowi4 *fl4, in geneve_get_v4_rt() argument 809 memset(fl4, 0, sizeof(*fl4)); in geneve_get_v4_rt() 810 fl4->flowi4_mark = skb->mark; in geneve_get_v4_rt() 811 fl4->flowi4_proto = IPPROTO_UDP; in geneve_get_v4_rt() 812 fl4->daddr = info->key.u.ipv4.dst; in geneve_get_v4_rt() 814 fl4->fl4_dport = dport; in geneve_get_v4_rt() 815 fl4->fl4_sport = sport; in geneve_get_v4_rt() 823 fl4->flowi4_tos = RT_TOS(tos); in geneve_get_v4_rt() 912 struct flowi4 fl4; in geneve_xmit_skb() local 996 udp_tunnel_xmit_skb(rt, gs4->sock->sk, skb, fl4.saddr, fl4.daddr, in geneve_xmit_skb() [all …]
|
A D | amt.c | 620 struct flowi4 fl4; in amt_send_discovery() local 709 struct flowi4 fl4; in amt_send_request() local 1003 struct flowi4 fl4; in amt_send_membership_update() local 1041 fl4.saddr, in amt_send_membership_update() 1042 fl4.daddr, in amt_send_membership_update() 1063 struct flowi4 fl4; in amt_send_multicast_data() local 1098 fl4.saddr, in amt_send_multicast_data() 1099 fl4.daddr, in amt_send_multicast_data() 1117 struct flowi4 fl4; in amt_send_membership_query() local 1156 fl4.saddr, in amt_send_membership_query() [all …]
|
/linux-6.3-rc2/net/sctp/ |
A D | protocol.c | 292 saddr->v4.sin_addr.s_addr = fl4->saddr; in sctp_v4_dst_saddr() 423 struct flowi4 *fl4 = &_fl.u.ip4; in sctp_v4_get_dst() local 435 fl4->fl4_dport = daddr->v4.sin_port; in sctp_v4_get_dst() 436 fl4->flowi4_proto = IPPROTO_SCTP; in sctp_v4_get_dst() 444 if (!fl4->fl4_sport) in sctp_v4_get_dst() 445 fl4->fl4_sport = saddr->v4.sin_port; in sctp_v4_get_dst() 449 &fl4->saddr); in sctp_v4_get_dst() 502 fl4->fl4_sport = laddr->a.v4.sin_port; in sctp_v4_get_dst() 503 flowi4_update_output(fl4, in sctp_v4_get_dst() 1058 struct flowi4 *fl4 = &t->fl.u.ip4; in sctp_v4_xmit() local [all …]
|
/linux-6.3-rc2/net/core/ |
A D | lwt_bpf.c | 202 struct flowi4 fl4 = {}; in bpf_lwt_xmit_reroute() local 205 fl4.flowi4_oif = oif; in bpf_lwt_xmit_reroute() 206 fl4.flowi4_mark = skb->mark; in bpf_lwt_xmit_reroute() 207 fl4.flowi4_uid = sock_net_uid(net, sk); in bpf_lwt_xmit_reroute() 208 fl4.flowi4_tos = RT_TOS(iph->tos); in bpf_lwt_xmit_reroute() 209 fl4.flowi4_flags = FLOWI_FLAG_ANYSRC; in bpf_lwt_xmit_reroute() 210 fl4.flowi4_proto = iph->protocol; in bpf_lwt_xmit_reroute() 211 fl4.daddr = iph->daddr; in bpf_lwt_xmit_reroute() 212 fl4.saddr = iph->saddr; in bpf_lwt_xmit_reroute() 214 rt = ip_route_output_key(net, &fl4); in bpf_lwt_xmit_reroute()
|
/linux-6.3-rc2/drivers/net/ethernet/mellanox/mlx5/core/en/ |
A D | tc_tun.c | 21 struct flowi4 fl4; member 124 attr->fl.fl4.flowi4_oif = uplink_dev->ifindex; in mlx5e_route_lookup_ipv4_get() 156 n = dst_neigh_lookup(&rt->dst, &attr->fl.fl4.daddr); in mlx5e_route_lookup_ipv4_get() 240 attr.fl.fl4.daddr = tun_key->u.ipv4.dst; in mlx5e_tc_tun_create_header_ipv4() 241 attr.fl.fl4.saddr = tun_key->u.ipv4.src; in mlx5e_tc_tun_create_header_ipv4() 294 ip->daddr = attr.fl.fl4.daddr; in mlx5e_tc_tun_create_header_ipv4() 295 ip->saddr = attr.fl.fl4.saddr; in mlx5e_tc_tun_create_header_ipv4() 355 attr.fl.fl4.daddr = tun_key->u.ipv4.dst; in mlx5e_tc_tun_update_header_ipv4() 356 attr.fl.fl4.saddr = tun_key->u.ipv4.src; in mlx5e_tc_tun_update_header_ipv4() 398 ip->daddr = attr.fl.fl4.daddr; in mlx5e_tc_tun_update_header_ipv4() [all …]
|
/linux-6.3-rc2/net/dccp/ |
A D | ipv4.c | 52 struct flowi4 *fl4; in dccp_v4_connect() local 77 fl4 = &inet->cork.fl.u.ip4; in dccp_v4_connect() 78 rt = ip_route_connect(fl4, nexthop, inet->inet_saddr, in dccp_v4_connect() 90 daddr = fl4->daddr; in dccp_v4_connect() 93 err = inet_bhash2_update_saddr(sk, &fl4->saddr, AF_INET); in dccp_v4_connect() 119 rt = ip_route_newports(fl4, rt, orig_sport, orig_dport, in dccp_v4_connect() 471 struct flowi4 fl4 = { in dccp_v4_route_skb() local 481 security_skb_classify_flow(skb, flowi4_to_flowi_common(&fl4)); in dccp_v4_route_skb() 482 rt = ip_route_output_flow(net, &fl4, sk); in dccp_v4_route_skb() 496 struct flowi4 fl4; in dccp_v4_send_response() local [all …]
|
/linux-6.3-rc2/net/netfilter/ |
A D | xt_TCPMSS.c | 52 struct flowi4 *fl4 = &fl.u.ip4; in tcpmss_reverse_mtu() local 53 memset(fl4, 0, sizeof(*fl4)); in tcpmss_reverse_mtu() 54 fl4->daddr = ip_hdr(skb)->saddr; in tcpmss_reverse_mtu()
|