Searched refs:bpf_net_ctx (Results 1 – 5 of 5) sorted by relevance
870 static inline struct bpf_net_context *bpf_net_ctx_set(struct bpf_net_context *bpf_net_ctx) in bpf_net_ctx_set() argument876 bpf_net_ctx->ri.kern_flags = 0; in bpf_net_ctx_set()878 tsk->bpf_net_context = bpf_net_ctx; in bpf_net_ctx_set()879 return bpf_net_ctx; in bpf_net_ctx_set()882 static inline void bpf_net_ctx_clear(struct bpf_net_context *bpf_net_ctx) in bpf_net_ctx_clear() argument884 if (bpf_net_ctx) in bpf_net_ctx_clear()895 struct bpf_net_context *bpf_net_ctx = bpf_net_ctx_get(); in bpf_net_ctx_get_ri() local897 if (!(bpf_net_ctx->ri.kern_flags & BPF_RI_F_RI_INIT)) { in bpf_net_ctx_get_ri()898 memset(&bpf_net_ctx->ri, 0, offsetof(struct bpf_net_context, ri.nh)); in bpf_net_ctx_get_ri()899 bpf_net_ctx->ri.kern_flags |= BPF_RI_F_RI_INIT; in bpf_net_ctx_get_ri()[all …]
42 struct bpf_net_context __bpf_net_ctx, *bpf_net_ctx; in run_lwt_bpf() local49 bpf_net_ctx = bpf_net_ctx_set(&__bpf_net_ctx); in run_lwt_bpf()82 bpf_net_ctx_clear(bpf_net_ctx); in run_lwt_bpf()
254 struct bpf_net_context __bpf_net_ctx, *bpf_net_ctx; in cpu_map_bpf_prog_run() local260 bpf_net_ctx = bpf_net_ctx_set(&__bpf_net_ctx); in cpu_map_bpf_prog_run()272 bpf_net_ctx_clear(bpf_net_ctx); in cpu_map_bpf_prog_run()
276 struct bpf_net_context __bpf_net_ctx, *bpf_net_ctx; in xdp_test_run_batch() local289 bpf_net_ctx = bpf_net_ctx_set(&__bpf_net_ctx); in xdp_test_run_batch()355 bpf_net_ctx_clear(bpf_net_ctx); in xdp_test_run_batch()391 struct bpf_net_context __bpf_net_ctx, *bpf_net_ctx; in bpf_test_run() local417 bpf_net_ctx = bpf_net_ctx_set(&__bpf_net_ctx); in bpf_test_run()424 bpf_net_ctx_clear(bpf_net_ctx); in bpf_test_run()
1689 struct bpf_net_context __bpf_net_ctx, *bpf_net_ctx; in tun_build_skb() local1730 bpf_net_ctx = bpf_net_ctx_set(&__bpf_net_ctx); in tun_build_skb()1764 bpf_net_ctx_clear(bpf_net_ctx); in tun_build_skb()1772 bpf_net_ctx_clear(bpf_net_ctx); in tun_build_skb()2670 struct bpf_net_context __bpf_net_ctx, *bpf_net_ctx; in tun_sendmsg() local2679 bpf_net_ctx = bpf_net_ctx_set(&__bpf_net_ctx); in tun_sendmsg()2694 bpf_net_ctx_clear(bpf_net_ctx); in tun_sendmsg()