You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bpf: fix "unresolved symbol" build error with resolve_btfids
Michal reported a build failure likes below:
BTFIDS vmlinux
FAILED unresolved symbol tcp_timewait_sock
make[1]: *** [/.../linux-5.9-rc7/Makefile:1176: vmlinux] Error 255
This error can be triggered when config has CONFIG_NET enabled
but CONFIG_INET disabled. In this case, there is no user of
structs inet_timewait_sock and tcp_timewait_sock and hence vmlinux BTF
types are not generated for these two structures.
To fix the problem, for two timewait structures, if CONFIG_INET=n,
use BTF_ID_UNUSED instead of BTF_ID to skip btf id generation
in resolve_btfids.
Fixes: fce557b ("bpf: Make btf_sock_ids global")
Reported-by: Michal Kubecek <[email protected]>
Signed-off-by: Yonghong Song <[email protected]>
0 commit comments