未验证 提交 c69d334b 编写于 作者: O openeuler-ci-bot 提交者: Gitee

!300 bpf: Fix build error: linux/kabi.h: No such file or directory

Merge Pull Request from: @barry19901226 
 
 The build error as follows:

 In file included from net/bpfilter/main.c:9:
 net/bpfilter/../../include/uapi/linux/bpf.h:13:10: fatal error: linux/kabi.h: No such file or directory
    13 | #include <linux/kabi.h>
       |          ^~~~~~~~~~~~~~

 kabi.h can not be find in user mode code, so remove
 <include/kabi.h> from include/uapi/linux/bpf.h. And
 use __GENKSYMS__ to fix kabi break. 
 
Link:https://gitee.com/openeuler/kernel/pulls/300 
Reviewed-by: Zucheng Zheng <zhengzucheng@huawei.com> 
Reviewed-by: Zheng Zengkai <zhengzengkai@huawei.com> 
Signed-off-by: Zheng Zengkai <zhengzengkai@huawei.com> 
...@@ -10,7 +10,6 @@ ...@@ -10,7 +10,6 @@
#include <linux/types.h> #include <linux/types.h>
#include <linux/bpf_common.h> #include <linux/bpf_common.h>
#include <linux/kabi.h>
/* Extended instruction set based on top of classic BPF */ /* Extended instruction set based on top of classic BPF */
...@@ -200,7 +199,9 @@ enum bpf_prog_type { ...@@ -200,7 +199,9 @@ enum bpf_prog_type {
BPF_PROG_TYPE_EXT, BPF_PROG_TYPE_EXT,
BPF_PROG_TYPE_LSM, BPF_PROG_TYPE_LSM,
BPF_PROG_TYPE_SK_LOOKUP, BPF_PROG_TYPE_SK_LOOKUP,
KABI_EXTEND_ENUM(BPF_PROG_TYPE_SCHED) #ifndef __GENKSYMS__
BPF_PROG_TYPE_SCHED,
#endif
}; };
enum bpf_attach_type { enum bpf_attach_type {
...@@ -242,7 +243,9 @@ enum bpf_attach_type { ...@@ -242,7 +243,9 @@ enum bpf_attach_type {
BPF_XDP_CPUMAP, BPF_XDP_CPUMAP,
BPF_SK_LOOKUP, BPF_SK_LOOKUP,
BPF_XDP, BPF_XDP,
KABI_BROKEN_INSERT_ENUM(BPF_SCHED) #ifndef __GENKSYMS__
BPF_SCHED,
#endif
__MAX_BPF_ATTACH_TYPE __MAX_BPF_ATTACH_TYPE
}; };
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册