summaryrefslogtreecommitdiff
path: root/kernel/bpf/disasm.c
diff options
context:
space:
mode:
authorYang Yingliang <yangyingliang@huawei.com>2023-08-03 05:31:28 +0300
committerMartin KaFai Lau <martin.lau@kernel.org>2023-08-05 02:15:50 +0300
commit1e8e2efb34023c5113ec679eae3c59ae2cd57b13 (patch)
tree77f55f7d480cb7137f8fca8ca90d58d30b63bfe3 /kernel/bpf/disasm.c
parentdde3979bb3451c820b540151f5903bfd2e814f60 (diff)
downloadlinux-1e8e2efb34023c5113ec679eae3c59ae2cd57b13.tar.xz
bpf: change bpf_alu_sign_string and bpf_movsx_string to static
The bpf_alu_sign_string and bpf_movsx_string introduced in commit f835bb622299 ("bpf: Add kernel/bpftool asm support for new instructions") are only used in disasm.c now, change them to static. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202308050615.wxAn1v2J-lkp@intel.com/ Acked-by: Yonghong Song <yonghong.song@linux.dev> Link: https://lore.kernel.org/r/20230803023128.3753323-1-yangyingliang@huawei.com Signed-off-by: Martin KaFai Lau <martin.lau@kernel.org>
Diffstat (limited to 'kernel/bpf/disasm.c')
-rw-r--r--kernel/bpf/disasm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/bpf/disasm.c b/kernel/bpf/disasm.c
index ef7c107c7b8f..49940c26a227 100644
--- a/kernel/bpf/disasm.c
+++ b/kernel/bpf/disasm.c
@@ -87,12 +87,12 @@ const char *const bpf_alu_string[16] = {
[BPF_END >> 4] = "endian",
};
-const char *const bpf_alu_sign_string[16] = {
+static const char *const bpf_alu_sign_string[16] = {
[BPF_DIV >> 4] = "s/=",
[BPF_MOD >> 4] = "s%=",
};
-const char *const bpf_movsx_string[4] = {
+static const char *const bpf_movsx_string[4] = {
[0] = "(s8)",
[1] = "(s16)",
[3] = "(s32)",