Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cocci: extend WRITE_ONCE detection for const script
It was suggesting that ctx should be marked const: static __always_inline __maybe_unused void bpf_clear_meta(struct __sk_buff *ctx) { __u32 zero = 0; WRITE_ONCE(ctx->cb[0], zero); WRITE_ONCE(ctx->cb[1], zero); WRITE_ONCE(ctx->cb[2], zero); WRITE_ONCE(ctx->cb[3], zero); WRITE_ONCE(ctx->cb[4], zero); } Extend to cover x->z[...]. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
- Loading branch information