Home
last modified time | relevance | path

Searched refs:h_proto (Results 1 – 9 of 9) sorted by relevance

/samples/bpf/
A Dparse_varlen.c118 uint64_t h_proto, nh_off; in handle_ingress() local
124 h_proto = eth->h_proto; in handle_ingress()
126 if (h_proto == ETH_P_8021Q || h_proto == ETH_P_8021AD) { in handle_ingress()
133 h_proto = vhdr->h_vlan_encapsulated_proto; in handle_ingress()
135 if (h_proto == ETH_P_8021Q || h_proto == ETH_P_8021AD) { in handle_ingress()
142 h_proto = vhdr->h_vlan_encapsulated_proto; in handle_ingress()
144 if (h_proto == htons(ETH_P_IP)) in handle_ingress()
146 else if (h_proto == htons(ETH_P_IPV6)) in handle_ingress()
A Dtc_l2_redirect_kern.c37 unsigned short h_proto; member
73 if (eth->h_proto == htons(ETH_P_IP)) { in _l2_to_iptun_ingress_forward()
86 } else if (eth->h_proto == htons(ETH_P_IPV6)) { in _l2_to_iptun_ingress_forward()
122 if (eth->h_proto == htons(ETH_P_IP)) { in _l2_to_iptun_ingress_redirect()
130 if (!is_vip_addr(eth->h_proto, daddr)) in _l2_to_iptun_ingress_redirect()
161 if (eth->h_proto == htons(ETH_P_IP)) { in _l2_to_ip6tun_ingress_redirect()
168 if (!is_vip_addr(eth->h_proto, iph->daddr)) in _l2_to_ip6tun_ingress_redirect()
173 } else if (eth->h_proto == htons(ETH_P_IPV6)) { in _l2_to_ip6tun_ingress_redirect()
210 if (eth->h_proto == htons(ETH_P_IP)) { in _drop_non_tun_vip()
216 if (is_vip_addr(eth->h_proto, iph->daddr)) in _drop_non_tun_vip()
[all …]
A Dxdp_fwd_kern.c51 u16 h_proto; in xdp_fwd_flags() local
61 h_proto = eth->h_proto; in xdp_fwd_flags()
62 if (h_proto == htons(ETH_P_IP)) { in xdp_fwd_flags()
79 } else if (h_proto == htons(ETH_P_IPV6)) { in xdp_fwd_flags()
133 if (h_proto == htons(ETH_P_IP)) in xdp_fwd_flags()
135 else if (h_proto == htons(ETH_P_IPV6)) in xdp_fwd_flags()
A Dxdp_router_ipv4.bpf.c81 __be16 h_proto; in xdp_router_ipv4_prog() local
91 h_proto = eth->h_proto; in xdp_router_ipv4_prog()
92 if (h_proto == bpf_htons(ETH_P_8021Q) || in xdp_router_ipv4_prog()
93 h_proto == bpf_htons(ETH_P_8021AD)) { in xdp_router_ipv4_prog()
101 h_proto = vhdr->h_vlan_encapsulated_proto; in xdp_router_ipv4_prog()
104 switch (bpf_ntohs(h_proto)) { in xdp_router_ipv4_prog()
A Dxdp_adjust_tail_kern.c55 eth->h_proto = orig_eth->h_proto; in swap_mac()
143 __u16 h_proto; in _xdp_icmp() local
148 h_proto = eth->h_proto; in _xdp_icmp()
150 if (h_proto == htons(ETH_P_IP)) in _xdp_icmp()
A Dparse_simple.c23 unsigned short h_proto; member
39 if (eth->h_proto != htons(ETH_P_IP)) in handle_ingress()
A Dxdp_tx_iptunnel_kern.c70 __be16 h_proto) in set_ethhdr() argument
74 new_eth->h_proto = h_proto; in set_ethhdr()
221 __u16 h_proto; in _xdp_tx_iptunnel() local
226 h_proto = eth->h_proto; in _xdp_tx_iptunnel()
228 if (h_proto == htons(ETH_P_IP)) in _xdp_tx_iptunnel()
230 else if (h_proto == htons(ETH_P_IPV6)) in _xdp_tx_iptunnel()
A Dparse_ldabs.c32 if (load_half(skb, offsetof(struct ethhdr, h_proto)) != ETH_P_IP) in handle_ingress()
A Dtest_lwt_bpf.c171 ehdr.h_proto = bpf_htons(ETH_P_IP); in __do_push_ll_and_redirect()

Completed in 116 milliseconds