bpf: Declare __bpf_free_used_maps() unconditionally
authorAndrii Nakryiko <andrii@kernel.org>
Tue, 12 Jan 2021 07:55:16 +0000 (23:55 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Mar 2021 08:04:10 +0000 (09:04 +0100)
commit4ebd8f0c82a55e337c09ec351f88e9977eb0b90a
tree19a1e44a6bc868e39337bfe7d60746608b8f4111
parent0e44f1e18398efbc726103a0d49abf8c8894dbe4
bpf: Declare __bpf_free_used_maps() unconditionally

[ Upstream commit 936f8946bdb48239f4292812d4d2e26c6d328c95 ]

__bpf_free_used_maps() is always defined in kernel/bpf/core.c, while
include/linux/bpf.h is guarding it behind CONFIG_BPF_SYSCALL. Move it out of
that guard region and fix compiler warning.

Fixes: a2ea07465c8d ("bpf: Fix missing prog untrack in release_maps")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Yonghong Song <yhs@fb.com>
Link: https://lore.kernel.org/bpf/20210112075520.4103414-4-andrii@kernel.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
include/linux/bpf.h