Home
last modified time | relevance | path

Searched refs:__sk_buff (Results 1 – 25 of 35) sorted by relevance

12

/Linux-v4.19/samples/bpf/
Dtcbpf1_kern.c15 static inline void set_dst_mac(struct __sk_buff *skb, char *mac) in set_dst_mac()
23 static inline void set_ip_tos(struct __sk_buff *skb, __u8 new_tos) in set_ip_tos()
36 static inline void set_tcp_ip_src(struct __sk_buff *skb, __u32 new_ip) in set_tcp_ip_src()
46 static inline void set_tcp_dest_port(struct __sk_buff *skb, __u16 new_port) in set_tcp_dest_port()
55 int bpf_prog1(struct __sk_buff *skb) in bpf_prog1()
69 int _redirect_xmit(struct __sk_buff *skb) in _redirect_xmit()
74 int _redirect_recv(struct __sk_buff *skb) in _redirect_recv()
79 int _clone_redirect_xmit(struct __sk_buff *skb) in _clone_redirect_xmit()
85 int _clone_redirect_recv(struct __sk_buff *skb) in _clone_redirect_recv()
Dtest_lwt_bpf.c37 int do_nop(struct __sk_buff *skb) in do_nop()
44 int do_test_ctx(struct __sk_buff *skb) in do_test_ctx()
57 int do_test_cb(struct __sk_buff *skb) in do_test_cb()
68 int do_test_data(struct __sk_buff *skb) in do_test_data()
92 static inline int rewrite(struct __sk_buff *skb, uint32_t old_ip, in rewrite()
149 int do_test_rewrite(struct __sk_buff *skb) in do_test_rewrite()
168 static inline int __do_push_ll_and_redirect(struct __sk_buff *skb) in __do_push_ll_and_redirect()
193 int do_push_ll_and_redirect_silent(struct __sk_buff *skb) in do_push_ll_and_redirect_silent()
199 int do_push_ll_and_redirect(struct __sk_buff *skb) in do_push_ll_and_redirect()
210 static inline void __fill_garbage(struct __sk_buff *skb) in __fill_garbage()
[all …]
Dsockex3_kern.c39 static inline void parse_eth_proto(struct __sk_buff *skb, u32 proto) in parse_eth_proto()
74 static inline int ip_is_fragment(struct __sk_buff *ctx, __u64 nhoff) in ip_is_fragment()
80 static inline __u32 ipv6_addr_hash(struct __sk_buff *ctx, __u64 off) in ipv6_addr_hash()
122 static void update_stats(struct __sk_buff *skb, struct globals *g) in update_stats()
138 static __always_inline void parse_ip_proto(struct __sk_buff *skb, in parse_ip_proto()
189 PROG(PARSE_IP)(struct __sk_buff *skb) in PROG()
217 PROG(PARSE_IPV6)(struct __sk_buff *skb) in PROG()
240 PROG(PARSE_VLAN)(struct __sk_buff *skb) in PROG()
256 PROG(PARSE_MPLS)(struct __sk_buff *skb) in PROG()
280 int main_prog(struct __sk_buff *skb) in main_prog()
Dsockex2_kern.c45 static inline int ip_is_fragment(struct __sk_buff *ctx, __u64 nhoff) in ip_is_fragment()
51 static inline __u32 ipv6_addr_hash(struct __sk_buff *ctx, __u64 off) in ipv6_addr_hash()
61 static inline __u64 parse_ip(struct __sk_buff *skb, __u64 nhoff, __u64 *ip_proto, in parse_ip()
85 static inline __u64 parse_ipv6(struct __sk_buff *skb, __u64 nhoff, __u64 *ip_proto, in parse_ipv6()
99 static inline bool flow_dissector(struct __sk_buff *skb, struct bpf_flow_keys *flow) in flow_dissector()
199 int bpf_prog2(struct __sk_buff *skb) in bpf_prog2()
Dparse_ldabs.c20 static inline int ip_is_fragment(struct __sk_buff *ctx, __u64 nhoff) in ip_is_fragment()
27 int handle_ingress(struct __sk_buff *skb) in handle_ingress()
Dtc_l2_redirect_kern.c59 int _l2_to_iptun_ingress_forward(struct __sk_buff *skb) in _l2_to_iptun_ingress_forward()
110 int _l2_to_iptun_ingress_redirect(struct __sk_buff *skb) in _l2_to_iptun_ingress_redirect()
151 int _l2_to_ip6tun_ingress_redirect(struct __sk_buff *skb) in _l2_to_ip6tun_ingress_redirect()
206 int _drop_non_tun_vip(struct __sk_buff *skb) in _drop_non_tun_vip()
Dcookie_uid_helper_example.c127 offsetof(struct __sk_buff, len)), in prog_load()
153 offsetof(struct __sk_buff, len)), in prog_load()
157 offsetof(struct __sk_buff, len)), in prog_load()
Dsockex1_kern.c15 int bpf_prog1(struct __sk_buff *skb) in bpf_prog1()
Dparse_simple.c27 int handle_ingress(struct __sk_buff *skb) in handle_ingress()
Dxdp2skb_meta_kern.c63 int _tc_mark(struct __sk_buff *ctx) in _tc_mark()
Dtest_cgrp2_tc_kern.c42 int handle_egress(struct __sk_buff *skb) in handle_egress()
Dlwt_len_hist_kern.c67 int do_len_hist(struct __sk_buff *skb) in do_len_hist()
Dtest_cgrp2_attach.c66 BPF_LDX_MEM(BPF_W, BPF_REG_1, BPF_REG_6, offsetof(struct __sk_buff, len)), /* r1 = skb->len */ in prog_load()
/Linux-v4.19/tools/testing/selftests/bpf/
Dtest_tunnel_kern.c47 int _gre_set_tunnel(struct __sk_buff *skb) in _gre_set_tunnel()
69 int _gre_get_tunnel(struct __sk_buff *skb) in _gre_get_tunnel()
86 int _ip6gretap_set_tunnel(struct __sk_buff *skb) in _ip6gretap_set_tunnel()
110 int _ip6gretap_get_tunnel(struct __sk_buff *skb) in _ip6gretap_get_tunnel()
130 int _erspan_set_tunnel(struct __sk_buff *skb) in _erspan_set_tunnel()
173 int _erspan_get_tunnel(struct __sk_buff *skb) in _erspan_get_tunnel()
214 int _ip4ip6erspan_set_tunnel(struct __sk_buff *skb) in _ip4ip6erspan_set_tunnel()
258 int _ip4ip6erspan_get_tunnel(struct __sk_buff *skb) in _ip4ip6erspan_get_tunnel()
300 int _vxlan_set_tunnel(struct __sk_buff *skb) in _vxlan_set_tunnel()
330 int _vxlan_get_tunnel(struct __sk_buff *skb) in _vxlan_get_tunnel()
[all …]
Dtest_verifier.c946 offsetof(struct __sk_buff, mark)),
1321 offsetof(struct __sk_buff, len)),
1324 offsetof(struct __sk_buff, mark)),
1327 offsetof(struct __sk_buff, pkt_type)),
1330 offsetof(struct __sk_buff, queue_mapping)),
1333 offsetof(struct __sk_buff, protocol)),
1336 offsetof(struct __sk_buff, vlan_present)),
1339 offsetof(struct __sk_buff, vlan_tci)),
1342 offsetof(struct __sk_buff, napi_id)),
1371 offsetof(struct __sk_buff, pkt_type)),
[all …]
Dtest_lwt_seg6local.c64 __attribute__((always_inline)) struct ip6_srh_t *get_srh(struct __sk_buff *skb) in get_srh()
99 int update_tlv_pad(struct __sk_buff *skb, uint32_t new_pad, in update_tlv_pad()
129 int is_valid_tlv_boundary(struct __sk_buff *skb, struct ip6_srh_t *srh, in is_valid_tlv_boundary()
188 int add_tlv(struct __sk_buff *skb, struct ip6_srh_t *srh, uint32_t tlv_off, in add_tlv()
232 int delete_tlv(struct __sk_buff *skb, struct ip6_srh_t *srh, in delete_tlv()
270 int has_egr_tlv(struct __sk_buff *skb, struct ip6_srh_t *srh) in has_egr_tlv()
297 int __encap_srh(struct __sk_buff *skb) in __encap_srh()
333 int __add_egr_x(struct __sk_buff *skb) in __add_egr_x()
371 int __pop_egr(struct __sk_buff *skb) in __pop_egr()
410 int __inspect_t(struct __sk_buff *skb) in __inspect_t()
Dtest_skb_cgroup_id_kern.c20 static __always_inline void log_nth_level(struct __sk_buff *skb, __u32 level) in log_nth_level()
32 int log_cgroup_id(struct __sk_buff *skb) in log_cgroup_id()
Dtest_obj_id.c27 int test_obj_id(struct __sk_buff *skb) in test_obj_id()
Dsockmap_parse_prog.c16 int bpf_prog1(struct __sk_buff *skb) in bpf_prog1()
Dtest_pkt_md_access.c34 int process(struct __sk_buff *skb) in process()
Dtest_pkt_access.c24 int process(struct __sk_buff *skb) in process()
Dsockmap_verdict_prog.c44 int bpf_prog2(struct __sk_buff *skb) in bpf_prog2()
Dtest_xdp_meta.c12 int ing_cls(struct __sk_buff *ctx) in ing_cls()
Dtest_sockmap_kern.h95 int bpf_prog1(struct __sk_buff *skb) in bpf_prog1()
101 int bpf_prog2(struct __sk_buff *skb) in bpf_prog2()
/Linux-v4.19/net/core/
Dfilter.c5197 if (off < 0 || off >= sizeof(struct __sk_buff)) in bpf_skb_is_valid_access()
5205 case bpf_ctx_range_till(struct __sk_buff, cb[0], cb[4]): in bpf_skb_is_valid_access()
5206 if (off + size > offsetofend(struct __sk_buff, cb[4])) in bpf_skb_is_valid_access()
5209 case bpf_ctx_range_till(struct __sk_buff, remote_ip6[0], remote_ip6[3]): in bpf_skb_is_valid_access()
5210 case bpf_ctx_range_till(struct __sk_buff, local_ip6[0], local_ip6[3]): in bpf_skb_is_valid_access()
5211 case bpf_ctx_range_till(struct __sk_buff, remote_ip4, remote_ip4): in bpf_skb_is_valid_access()
5212 case bpf_ctx_range_till(struct __sk_buff, local_ip4, local_ip4): in bpf_skb_is_valid_access()
5213 case bpf_ctx_range(struct __sk_buff, data): in bpf_skb_is_valid_access()
5214 case bpf_ctx_range(struct __sk_buff, data_meta): in bpf_skb_is_valid_access()
5215 case bpf_ctx_range(struct __sk_buff, data_end): in bpf_skb_is_valid_access()
[all …]

12