Lines Matching refs:ctx
26 int sendmsg_v6_prog(struct bpf_sock_addr *ctx) in sendmsg_v6_prog() argument
28 if (ctx->type != SOCK_DGRAM) in sendmsg_v6_prog()
32 if (ctx->msg_src_ip6[3] == bpf_htonl(1) || in sendmsg_v6_prog()
33 ctx->msg_src_ip6[3] == bpf_htonl(0)) { in sendmsg_v6_prog()
34 ctx->msg_src_ip6[0] = bpf_htonl(SRC_REWRITE_IP6_0); in sendmsg_v6_prog()
35 ctx->msg_src_ip6[1] = bpf_htonl(SRC_REWRITE_IP6_1); in sendmsg_v6_prog()
36 ctx->msg_src_ip6[2] = bpf_htonl(SRC_REWRITE_IP6_2); in sendmsg_v6_prog()
37 ctx->msg_src_ip6[3] = bpf_htonl(SRC_REWRITE_IP6_3); in sendmsg_v6_prog()
44 if (ctx->user_ip6[0] == bpf_htonl(0xFACEB00C)) { in sendmsg_v6_prog()
45 ctx->user_ip6[0] = bpf_htonl(DST_REWRITE_IP6_0); in sendmsg_v6_prog()
46 ctx->user_ip6[1] = bpf_htonl(DST_REWRITE_IP6_1); in sendmsg_v6_prog()
47 ctx->user_ip6[2] = bpf_htonl(DST_REWRITE_IP6_2); in sendmsg_v6_prog()
48 ctx->user_ip6[3] = bpf_htonl(DST_REWRITE_IP6_3); in sendmsg_v6_prog()
50 ctx->user_port = bpf_htons(DST_REWRITE_PORT6); in sendmsg_v6_prog()