[PATCH v4 bpf-next 3/5] bpf: Introduce path iterator

Andrii Nakryiko andrii.nakryiko at gmail.com
Thu Jun 12 23:11:22 UTC 2025


On Wed, Jun 11, 2025 at 3:02 PM Song Liu <song at kernel.org> wrote:
>
> Introduce a path iterator, which walks a struct path toward the root.
> This path iterator is based on path_walk_parent. A fixed zero'ed root
> is passed to path_walk_parent(). Therefore, unless the user terminates
> it earlier, the iterator will terminate at the real root.
>
> Signed-off-by: Song Liu <song at kernel.org>
> ---
>  fs/bpf_fs_kfuncs.c    | 72 +++++++++++++++++++++++++++++++++++++++++++
>  kernel/bpf/verifier.c |  5 +++
>  2 files changed, 77 insertions(+)
>

LGTM from BPF and open-coded contract POV.

Acked-by: Andrii Nakryiko <andrii at kernel.org>

[...]



More information about the Linux-security-module-archive mailing list