Home
last modified time | relevance | path

Searched refs:user_port (Results 1 – 16 of 16) sorted by relevance

/openbmc/linux/tools/testing/selftests/bpf/progs/
H A Dbind4_prog.c103 __u16 user_port; in bind_v4_prog() local
116 ctx->user_port != bpf_htons(SERV4_PORT)) in bind_v4_prog()
128 user_port = 0; in bind_v4_prog()
129 user_port |= ((volatile __u8 *)&ctx->user_port)[0] << 0; in bind_v4_prog()
130 user_port |= ((volatile __u8 *)&ctx->user_port)[1] << 8; in bind_v4_prog()
131 if (ctx->user_port != user_port) in bind_v4_prog()
154 ctx->user_port = bpf_htons(SERV4_REWRITE_PORT); in bind_v4_prog()
H A Dconnect_force_port4.c44 if (ctx->user_port == bpf_htons(60000)) { in connect4()
51 orig->port = ctx->user_port; in connect4()
54 ctx->user_port = bpf_htons(60123); in connect4()
66 if (ctx->user_port == bpf_htons(60123)) { in getsockname4()
68 ctx->user_port = bpf_htons(60000); in getsockname4()
82 if (ctx->user_port == bpf_htons(60123)) { in getpeername4()
86 ctx->user_port = orig->port; in getpeername4()
H A Dbind6_prog.c109 __u16 user_port; in bind_v6_prog() local
126 ctx->user_port != bpf_htons(SERV6_PORT)) in bind_v6_prog()
140 user_port = 0; in bind_v6_prog()
141 user_port |= ((volatile __u8 *)&ctx->user_port)[0] << 0; in bind_v6_prog()
142 user_port |= ((volatile __u8 *)&ctx->user_port)[1] << 8; in bind_v6_prog()
143 if (ctx->user_port != user_port) in bind_v6_prog()
171 ctx->user_port = bpf_htons(SERV6_REWRITE_PORT); in bind_v6_prog()
H A Dconnect_force_port6.c43 if (ctx->user_port == bpf_htons(60000)) { in connect6()
53 orig->port = ctx->user_port; in connect6()
59 ctx->user_port = bpf_htons(60124); in connect6()
71 if (ctx->user_port == bpf_htons(60124)) { in getsockname6()
76 ctx->user_port = bpf_htons(60000); in getsockname6()
90 if (ctx->user_port == bpf_htons(60124)) { in getpeername6()
97 ctx->user_port = orig->port; in getpeername6()
H A Dsendmsg4_prog.c41 ctx->user_port == bpf_htons(DST_PORT)) { in sendmsg_v4_prog()
43 ctx->user_port = bpf_htons(DST_REWRITE_PORT4); in sendmsg_v4_prog()
H A Dconnect4_dropper.c21 if (ctx->user_port == bpf_htons(60120)) in connect_v4_dropper()
H A Drecvmsg4_prog.c35 ctx->user_port = bpf_htons(SERV4_PORT); in recvmsg4_prog()
H A Dbind_perm.c27 if (ctx->user_port == bpf_htons(111)) in bind_prog()
H A Drecvmsg6_prog.c41 ctx->user_port = bpf_htons(SERV6_PORT); in recvmsg6_prog()
H A Dsendmsg6_prog.c53 ctx->user_port = bpf_htons(DST_REWRITE_PORT6); in sendmsg_v6_prog()
H A Dconnect6_prog.c74 ctx->user_port = bpf_htons(DST_REWRITE_PORT6); in connect_v6_prog()
H A Dconnect4_prog.c195 ctx->user_port = bpf_htons(DST_REWRITE_PORT4); in connect_v4_prog()
/openbmc/linux/tools/testing/selftests/bpf/
H A Dtest_sock_addr.c789 offsetof(struct bpf_sock_addr, user_port)), in sendmsg4_rw_asm_prog_load()
851 offsetof(struct bpf_sock_addr, user_port)), in sendmsg6_rw_dst_asm_prog_load()
/openbmc/linux/tools/include/uapi/linux/
H A Dbpf.h6605 __u32 user_port; /* Allows 1,2,4-byte read and 4-byte write. member
/openbmc/linux/include/uapi/linux/
H A Dbpf.h6602 __u32 user_port; /* Allows 1,2,4-byte read and 4-byte write. member
/openbmc/linux/net/core/
H A Dfilter.c9086 case bpf_ctx_range(struct bpf_sock_addr, user_port): in sock_addr_is_valid_access()
10188 case offsetof(struct bpf_sock_addr, user_port): in sock_addr_convert_ctx_access()