/linux/drivers/net/ethernet/mellanox/mlx5/core/en/ |
H A D | tc_tun_geneve.c | 79 static void mlx5e_tunnel_id_to_vni(__be64 tun_id, __u8 *vni) in mlx5e_tunnel_id_to_vni() argument 82 vni[0] = (__force __u8)(tun_id >> 16); in mlx5e_tunnel_id_to_vni() 83 vni[1] = (__force __u8)(tun_id >> 8); in mlx5e_tunnel_id_to_vni() 84 vni[2] = (__force __u8)tun_id; in mlx5e_tunnel_id_to_vni() 86 vni[0] = (__force __u8)((__force u64)tun_id >> 40); in mlx5e_tunnel_id_to_vni() 87 vni[1] = (__force __u8)((__force u64)tun_id >> 48); in mlx5e_tunnel_id_to_vni() 88 vni[2] = (__force __u8)((__force u64)tun_id >> 56); in mlx5e_tunnel_id_to_vni() 112 mlx5e_tunnel_id_to_vni(tun_info->key.tun_id, geneveh->vni); in mlx5e_gen_ip_tunnel_header_geneve()
|
H A D | tc_tun_gre.c | 33 __be32 tun_id = tunnel_id_to_key32(tun_key->tun_id); in mlx5e_gen_ip_tunnel_header_gretap() local 53 *ptr = tun_id; in mlx5e_gen_ip_tunnel_header_gretap()
|
H A D | tc_tun_vxlan.c | 88 __be32 tun_id = tunnel_id_to_key32(tun_key->tun_id); in mlx5e_gen_ip_tunnel_header_vxlan() local 101 vxh->vx_vni = vxlan_vni_field(tun_id); in mlx5e_gen_ip_tunnel_header_vxlan()
|
/linux/net/bridge/ |
H A D | br_vlan_tunnel.c | 64 struct net_bridge_vlan *vlan, u32 tun_id) in __vlan_tunnel_info_add() argument 67 __be64 key = key32_to_tunnel_id(cpu_to_be32(tun_id)); in __vlan_tunnel_info_add() 99 u32 tun_id) in nbp_vlan_tunnel_info_add() argument 111 return __vlan_tunnel_info_add(vg, vlan, tun_id); in nbp_vlan_tunnel_info_add() 177 vlan = br_vlan_tunnel_lookup(&vg->tunnel_hash, tinfo->key.tun_id); in br_handle_ingress_vlan_tunnel()
|
H A D | br_private_tunnel.h | 33 u16 vid, u32 tun_id, bool *changed); 41 u32 tun_id); 63 u16 vid, u32 tun_id) in nbp_vlan_tunnel_info_add() argument
|
H A D | br_netlink_tunnel.c | 200 u16 vid, u32 tun_id, bool *changed) in br_vlan_tunnel_info() argument 209 err = nbp_vlan_tunnel_info_add(p, vid, tun_id); in br_vlan_tunnel_info() 226 u32 tun_id; in br_parse_vlan_tunnel_info() local 241 tun_id = nla_get_u32(tb[IFLA_BRIDGE_VLAN_TUNNEL_ID]); in br_parse_vlan_tunnel_info() 249 tinfo->tunid = tun_id; in br_parse_vlan_tunnel_info()
|
H A D | br_vlan_options.c | 144 u32 tun_id = 0; in br_vlan_modify_tunnel() local 174 tun_id = nla_get_u32(tun_tb[BRIDGE_VLANDB_TINFO_ID]); in br_vlan_modify_tunnel() 181 tun_id += v->vid - vinfo->vid; in br_vlan_modify_tunnel() 190 return br_vlan_tunnel_info(p, cmd, v->vid, tun_id, changed); in br_vlan_modify_tunnel()
|
/linux/net/core/ |
H A D | fib_rules.c | 40 if (rule->iifindex || rule->oifindex || rule->mark || rule->tun_id || in fib_rule_matchall() 275 if (rule->tun_id && (rule->tun_id != fl->flowi_tun_key.tun_id)) in fib_rule_match() 459 if (rule->tun_id && r->tun_id != rule->tun_id) in rule_find() 596 nlrule->tun_id = nla_get_be64(tb[FRA_TUN_ID]); in fib_nl2rule() 719 if (r->tun_id != rule->tun_id) in rule_exists() 867 if (rule->tun_id) in fib_nl_newrule() 934 if (rule->tun_id) in fib_nl_delrule() 1061 (rule->tun_id && in fib_nl_fill_rule() 1062 nla_put_be64(skb, FRA_TUN_ID, rule->tun_id, FRA_PAD)) || in fib_nl_fill_rule()
|
/linux/include/net/ |
H A D | ip_tunnels.h | 58 __be64 tun_id; member 283 __be64 tun_id, in ip_tunnel_key_init() argument 286 key->tun_id = tun_id; in ip_tunnel_key_init() 335 static inline __be32 tunnel_id_to_key32(__be64 tun_id) in tunnel_id_to_key32() argument 338 return (__force __be32)tun_id; in tunnel_id_to_key32() 340 return (__force __be32)((__force u64)tun_id >> 32); in tunnel_id_to_key32()
|
H A D | flow.h | 27 __be64 tun_id; member 109 fl4->flowi4_tun_key.tun_id = 0; in flowi4_init_output()
|
H A D | dst_metadata.h | 250 info->key.tun_id = tunnel_id; in __ipv6_tun_set_dst()
|
/linux/drivers/net/ |
H A D | geneve.c | 108 static void tunnel_id_to_vni(__be64 tun_id, __u8 *vni) in tunnel_id_to_vni() argument 111 vni[0] = (__force __u8)(tun_id >> 16); in tunnel_id_to_vni() 112 vni[1] = (__force __u8)(tun_id >> 8); in tunnel_id_to_vni() 113 vni[2] = (__force __u8)tun_id; in tunnel_id_to_vni() 115 vni[0] = (__force __u8)((__force u64)tun_id >> 40); in tunnel_id_to_vni() 116 vni[1] = (__force __u8)((__force u64)tun_id >> 48); in tunnel_id_to_vni() 117 vni[2] = (__force __u8)((__force u64)tun_id >> 56); in tunnel_id_to_vni() 121 static bool eq_tun_id_and_vni(u8 *tun_id, u8 *vni) in eq_tun_id_and_vni() argument 123 return !memcmp(vni, &tun_id[5], 3); in eq_tun_id_and_vni() 142 if (eq_tun_id_and_vni((u8 *)&node->geneve->cfg.info.key.tun_id, vni) && in geneve_lookup() [all …]
|
/linux/drivers/net/ethernet/netronome/nfp/flower/ |
H A D | cmsg.h | 223 __be64 tun_id __packed; 448 __be32 tun_id; member 484 __be32 tun_id; member
|
H A D | match.c | 508 nfp_flower_compile_tun_udp_key(&ext->tun_id, &msk->tun_id, rule); in nfp_flower_compile_ipv4_udp_tun() 518 nfp_flower_compile_tun_udp_key(&ext->tun_id, &msk->tun_id, rule); in nfp_flower_compile_ipv6_udp_tun()
|
H A D | action.c | 461 set_tun->tun_id = ip_tun->key.tun_id; in nfp_fl_set_tun()
|
/linux/net/ipv4/ |
H A D | ip_gre.c | 318 __be64 tun_id; in erspan_rcv() local 322 tun_id = key32_to_tunnel_id(tpi->key); in erspan_rcv() 325 tun_id, sizeof(*md)); in erspan_rcv() 389 __be64 tun_id; in __ipgre_rcv() local 395 tun_id = key32_to_tunnel_id(tpi->key); in __ipgre_rcv() 396 tun_dst = ip_tun_rx_dst(skb, flags, tun_id, 0); in __ipgre_rcv() 523 tunnel_id_to_key32(tun_info->key.tun_id), in gre_fb_xmit() 594 erspan_build_header(skb, ntohl(tunnel_id_to_key32(key->tun_id)), in erspan_fb_xmit() 599 ntohl(tunnel_id_to_key32(key->tun_id)), in erspan_fb_xmit() 633 tunnel_id_to_key32(key->tun_id), in gre_fill_metadata_dst()
|
H A D | ip_tunnel_core.c | 142 dst->key.tun_id = src->key.tun_id; in iptunnel_metadata_reply() 695 tun_info->key.tun_id = nla_get_be64(tb[LWTUNNEL_IP_ID]); in ip_tun_build_state() 850 if (nla_put_be64(skb, LWTUNNEL_IP_ID, tun_info->key.tun_id, in ip_tun_fill_encap_info() 981 tun_info->key.tun_id = nla_get_be64(tb[LWTUNNEL_IP6_ID]); in ip6_tun_build_state() 1020 if (nla_put_be64(skb, LWTUNNEL_IP6_ID, tun_info->key.tun_id, in ip6_tun_fill_encap_info()
|
H A D | route.c | 2257 fl4.flowi4_tun_key.tun_id = tun_info->key.tun_id; in ip_route_input_slow() 2259 fl4.flowi4_tun_key.tun_id = 0; in ip_route_input_slow()
|
/linux/net/ipv6/ |
H A D | ip6_gre.c | 501 __be64 tun_id; in ip6gre_rcv() local 504 tun_id = key32_to_tunnel_id(tpi->key); in ip6gre_rcv() 506 tun_dst = ipv6_tun_rx_dst(skb, flags, tun_id, 0); in ip6gre_rcv() 558 __be64 tun_id; in ip6erspan_rcv() local 562 tun_id = key32_to_tunnel_id(tpi->key); in ip6erspan_rcv() 564 tun_dst = ipv6_tun_rx_dst(skb, flags, tun_id, in ip6erspan_rcv() 782 fl6->fl6_gre_key = tunnel_id_to_key32(key->tun_id); in __gre6_xmit() 797 tunnel_id_to_key32(tun_info->key.tun_id), in __gre6_xmit() 1004 __be32 tun_id; in ip6erspan_tunnel_xmit() local 1017 fl6.fl6_gre_key = tunnel_id_to_key32(key->tun_id); in ip6erspan_tunnel_xmit() [all …]
|
/linux/net/netfilter/ |
H A D | nft_tunnel.c | 58 *dest = ntohl(tunnel_id_to_key32(tun_info->key.tun_id)); in nft_tunnel_get_eval() 459 info.key.tun_id = key32_to_tunnel_id(nla_get_be32(tb[NFTA_TUNNEL_KEY_ID])); in nft_tunnel_obj_init() 685 tunnel_id_to_key32(info->key.tun_id)) || in nft_tunnel_obj_dump()
|
/linux/drivers/net/ethernet/sfc/ |
H A D | tc_encap_actions.c | 325 vxlan->vx_vni = vxlan_vni_field(tunnel_id_to_key32(key->tun_id)); in efx_gen_tun_header_vxlan() 341 vni = ntohl(tunnel_id_to_key32(key->tun_id)); in efx_gen_tun_header_geneve()
|
/linux/drivers/net/ethernet/mellanox/mlx5/core/ |
H A D | en_tc.c | 2263 u32 tun_id, enc_opts_id = 0; in mlx5e_get_flow_tunnel_id() local 2288 err = mapping_add(uplink_priv->tunnel_mapping, &tunnel_key, &tun_id); in mlx5e_get_flow_tunnel_id() 2313 value = tun_id << ENC_OPTS_BITS | enc_opts_id; in mlx5e_get_flow_tunnel_id() 2339 mapping_remove(uplink_priv->tunnel_mapping, tun_id); in mlx5e_get_flow_tunnel_id() 2346 u32 tun_id = flow->attr->tunnel_id >> ENC_OPTS_BITS; in mlx5e_put_flow_tunnel_id() local 2355 if (tun_id) in mlx5e_put_flow_tunnel_id() 2356 mapping_remove(uplink_priv->tunnel_mapping, tun_id); in mlx5e_put_flow_tunnel_id() 5588 u32 tun_id, enc_opts_id; in mlx5e_tc_restore_tunnel() local 5595 tun_id = tunnel_id >> ENC_OPTS_BITS; in mlx5e_tc_restore_tunnel() 5597 if (!tun_id) in mlx5e_tc_restore_tunnel() [all …]
|
/linux/drivers/net/ethernet/broadcom/bnxt/ |
H A D | bnxt_tc.c | 488 flow->tun_key.tun_id = key32_to_tunnel_id(match.key->keyid); in bnxt_tc_parse_flow() 489 flow->tun_mask.tun_id = key32_to_tunnel_id(match.mask->keyid); in bnxt_tc_parse_flow() 818 req->tunnel_id = tunnel_id_to_key32(tun_key->tun_id); in hwrm_cfa_decap_filter_alloc() 918 encap->vni = tunnel_id_to_key32(encap_key->tun_id); in hwrm_cfa_encap_record_alloc()
|
/linux/net/psample/ |
H A D | psample.c | 225 nla_put_be64(skb, PSAMPLE_TUNNEL_KEY_ATTR_ID, tun_key->tun_id, in __psample_ip_tun_to_nlattr()
|
/linux/net/sched/ |
H A D | act_tunnel_key.c | 742 __be32 key_id = tunnel_id_to_key32(key->tun_id); in tunnel_key_dump()
|