提交 7623fa5d 编写于 作者: L Lu Jialin 提交者: Zheng Zengkai

kabi: reserve space for cgroup_bpf_attach_type and bpf_cgroup_storage_type

hulk inclusion
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/I4GII8?from=project-issue
CVE: NA

--------

We reserve some fields beforehand for cgroup_bpf_attach_type and bpf_cgroup_storage_type
prone to change, therefore, we can hot add/change features of bpf cgroup
with this enhancement.

After reserving, normally cache does not matter as the reserved fields
are not accessed at all.
Signed-off-by: NLu Jialin <lujialin4@huawei.com>
Reviewed-by: Nweiyang wang <wangweiyang2@huawei.com>
Reviewed-by: NWei Yongjun <weiyongjun1@huawei.com>
Reviewed-by: Wei Yongjun<weiyongjun1@huawei.com>
Reviewed-by: Nweiyang wang <wangweiyang2@huawei.com>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
上级 fac4c1ea
......@@ -49,6 +49,14 @@ enum cgroup_bpf_attach_type {
CGROUP_INET4_GETSOCKNAME,
CGROUP_INET6_GETSOCKNAME,
CGROUP_INET_SOCK_RELEASE,
CGROUP_ATTACH_TYPE_KABI_RESERVE_1,
CGROUP_ATTACH_TYPE_KABI_RESERVE_2,
CGROUP_ATTACH_TYPE_KABI_RESERVE_3,
CGROUP_ATTACH_TYPE_KABI_RESERVE_4,
CGROUP_ATTACH_TYPE_KABI_RESERVE_5,
CGROUP_ATTACH_TYPE_KABI_RESERVE_6,
CGROUP_ATTACH_TYPE_KABI_RESERVE_7,
CGROUP_ATTACH_TYPE_KABI_RESERVE_8,
MAX_CGROUP_BPF_ATTACH_TYPE
};
......
......@@ -491,6 +491,14 @@ struct bpf_prog_offload {
enum bpf_cgroup_storage_type {
BPF_CGROUP_STORAGE_SHARED,
BPF_CGROUP_STORAGE_PERCPU,
BPF_CGROUP_STORAGE_KABI_RESERVE_1,
BPF_CGROUP_STORAGE_KABI_RESERVE_2,
BPF_CGROUP_STORAGE_KABI_RESERVE_3,
BPF_CGROUP_STORAGE_KABI_RESERVE_4,
BPF_CGROUP_STORAGE_KABI_RESERVE_5,
BPF_CGROUP_STORAGE_KABI_RESERVE_6,
BPF_CGROUP_STORAGE_KABI_RESERVE_7,
BPF_CGROUP_STORAGE_KABI_RESERVE_8,
__BPF_CGROUP_STORAGE_MAX
};
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册