Re: [PATCH bpf-next 4/9] bpf: Add log support for cgroup prog link_create
From: bot+bpf-ci
Date: Mon Nov 09 2026 - 09:53:02 EST
> bpf: Add log support for cgroup prog link_create
TL;DR: Nit only: the new <linux/bpf_verifier.h> include in bpf-cgroup.h may be
unnecessary, since a forward declaration would likely suffice and avoid
pulling it into tcp.h users.
> diff --git a/include/linux/bpf-cgroup.h b/include/linux/bpf-cgroup.h
> --- a/include/linux/bpf-cgroup.h
> +++ b/include/linux/bpf-cgroup.h
> @@ -4,6 +4,7 @@
>
> #include <linux/bpf.h>
> #include <linux/bpf-cgroup-defs.h>
> +#include <linux/bpf_verifier.h>
> #include <linux/errno.h>
> #include <linux/jump_label.h>
> #include <linux/percpu.h>
this isn't a bug, but is the <linux/bpf_verifier.h> include needed here?
bpf.h already forward-declares struct bpf_verifier_log, which is all the
new cgroup_bpf_link_attach() prototype and its stub need, and cgroup.c
already includes bpf_verifier.h for bpf_log().
Since bpf-cgroup.h is included from include/net/tcp.h, would a plain
forward declaration (as done for trace_events.h earlier in this series)
keep the verifier header out of those translation units?
---
AI reviewed your patch. Please fix the bug or email reply why it's not a bug.
See: https://github.com/kernel-patches/vmtest/blob/master/ci/claude/README.md
CI run summary: https://github.com/kernel-patches/bpf/actions/runs/42633880300