Commit d1c5947e authored by YueHaibing's avatar YueHaibing Committed by James Morris

security: Make capability_hooks static

Fix sparse warning:

security/commoncap.c:1347:27: warning:
 symbol 'capability_hooks' was not declared. Should it be static?
Reported-by: default avatarHulk Robot <hulkci@huawei.com>
Signed-off-by: default avatarYueHaibing <yuehaibing@huawei.com>
Signed-off-by: default avatarJames Morris <jamorris@linux.microsoft.com>
parent e93c9c99
...@@ -1344,7 +1344,7 @@ int cap_mmap_file(struct file *file, unsigned long reqprot, ...@@ -1344,7 +1344,7 @@ int cap_mmap_file(struct file *file, unsigned long reqprot,
#ifdef CONFIG_SECURITY #ifdef CONFIG_SECURITY
struct security_hook_list capability_hooks[] __lsm_ro_after_init = { static struct security_hook_list capability_hooks[] __lsm_ro_after_init = {
LSM_HOOK_INIT(capable, cap_capable), LSM_HOOK_INIT(capable, cap_capable),
LSM_HOOK_INIT(settime, cap_settime), LSM_HOOK_INIT(settime, cap_settime),
LSM_HOOK_INIT(ptrace_access_check, cap_ptrace_access_check), LSM_HOOK_INIT(ptrace_access_check, cap_ptrace_access_check),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment