!302 sched: programmable: fix build error of bpf_topology
Merge Pull Request from: @barry19901226
make ARCH="arm64" CROSS_COMPILE="aarch64-linux-gnu-",
gcc complained as follow:
In file included from ./arch/arm64/include/asm/topology.h:17:0,
from ./arch/arm64/include/asm/numa.h:5,
from ./arch/arm64/include/asm/mmzone.h:7,
from ./include/linux/mmzone.h:1025,
from ./include/linux/gfp.h:6,
from ./include/linux/umh.h:4,
from ./include/linux/kmod.h:9,
from ./include/linux/module.h:16,
from ./include/linux/bpf.h:20,
from kernel/sched/bpf_topology.c:15:
kernel/sched/bpf_topology.c: In function ‘bpf_update_cpu_topology’:
./include/linux/arch_topology.h:64:62: error: ‘struct bpf_cpu_topology’ has no member named ‘package_id’; did you mean ‘package_cpus’?
#define topology_physical_package_id(cpu) (cpu_topology[cpu].package_id)
kernel/sched/bpf_topology.c:57:20: warning: ‘bpf_cpu_topology_ids’ defined but not used [-Wunused-variable]
BTF_ID_LIST_SINGLE(bpf_cpu_topology_ids, struct, bpf_cpu_topology)
To fix this error, change local variable cpu_topology to bpf_cpu_topology and
delete the definition of bpf_cpu_topology_ids.
Link:https://gitee.com/openeuler/kernel/pulls/302
Reviewed-by: Zucheng Zheng <zhengzucheng@huawei.com>
Reviewed-by: Zheng Zengkai <zhengzengkai@huawei.com>
Signed-off-by: Zheng Zengkai <zhengzengkai@huawei.com>
Showing
想要评论请 注册 或 登录