summaryrefslogtreecommitdiff
path: root/include/linux/lsm_hook_defs.h
diff options
context:
space:
mode:
authorKhadija Kamran <kamrankhadijadj@gmail.com>2023-08-23 09:44:41 +0300
committerPaul Moore <paul@paul-moore.com>2023-09-14 00:57:01 +0300
commit25cc71d1527b55c880d333e7cc1dc37aeef9843f (patch)
tree3e59f618d4b8363bb20dea07c9c496f927197582 /include/linux/lsm_hook_defs.h
parent0bb80ecc33a8fb5a682236443c1e740d5c917d1d (diff)
downloadlinux-25cc71d1527b55c880d333e7cc1dc37aeef9843f.tar.xz
lsm: constify 'sb' parameter in security_quotactl()
SELinux registers the implementation for the "quotactl" hook. Looking at the function implementation we observe that the parameter "sb" is not changing. Mark the "sb" parameter of LSM hook security_quotactl() as "const" since it will not be changing in the LSM hook. Signed-off-by: Khadija Kamran <kamrankhadijadj@gmail.com> Signed-off-by: Paul Moore <paul@paul-moore.com>
Diffstat (limited to 'include/linux/lsm_hook_defs.h')
-rw-r--r--include/linux/lsm_hook_defs.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/lsm_hook_defs.h b/include/linux/lsm_hook_defs.h
index ac962c4cb44b..b464f9c1894f 100644
--- a/include/linux/lsm_hook_defs.h
+++ b/include/linux/lsm_hook_defs.h
@@ -43,7 +43,7 @@ LSM_HOOK(int, 0, capset, struct cred *new, const struct cred *old,
const kernel_cap_t *permitted)
LSM_HOOK(int, 0, capable, const struct cred *cred, struct user_namespace *ns,
int cap, unsigned int opts)
-LSM_HOOK(int, 0, quotactl, int cmds, int type, int id, struct super_block *sb)
+LSM_HOOK(int, 0, quotactl, int cmds, int type, int id, const struct super_block *sb)
LSM_HOOK(int, 0, quota_on, struct dentry *dentry)
LSM_HOOK(int, 0, syslog, int type)
LSM_HOOK(int, 0, settime, const struct timespec64 *ts,