netfilter: nfnetlink hook: dump bpf prog id
authorFlorian Westphal <fw@strlen.de>
Fri, 21 Apr 2023 17:02:56 +0000 (19:02 +0200)
committerAlexei Starovoitov <ast@kernel.org>
Fri, 21 Apr 2023 18:34:14 +0000 (11:34 -0700)
commit506a74db7e019a277e987fa65654bdd953859d5b
tree2b07ac933aca12de0c17be5a9a76947523961a31
parentfd9c663b9ad67dedfc9a3fd3429ddd3e83782b4d
netfilter: nfnetlink hook: dump bpf prog id

This allows userspace ("nft list hooks") to show which bpf program
is attached to which hook.

Without this, user only knows bpf prog is attached at prio
x, y, z at INPUT and FORWARD, but can't tell which program is where.

v4: kdoc fixups (Simon Horman)

Link: https://lore.kernel.org/bpf/ZEELzpNCnYJuZyod@corigine.com/
Signed-off-by: Florian Westphal <fw@strlen.de>
Link: https://lore.kernel.org/r/20230421170300.24115-4-fw@strlen.de
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
include/uapi/linux/netfilter/nfnetlink_hook.h
net/netfilter/nfnetlink_hook.c