projects
/
platform
/
kernel
/
linux-starfive.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Linux 6.1.17
[platform/kernel/linux-starfive.git]
/
security
/
security.c
diff --git
a/security/security.c
b/security/security.c
index
79d82cb
..
75dc094
100644
(file)
--- a/
security/security.c
+++ b/
security/security.c
@@
-1591,12
+1591,13
@@
static inline unsigned long mmap_prot(struct file *file, unsigned long prot)
int security_mmap_file(struct file *file, unsigned long prot,
unsigned long flags)
{
int security_mmap_file(struct file *file, unsigned long prot,
unsigned long flags)
{
+ unsigned long prot_adj = mmap_prot(file, prot);
int ret;
int ret;
- ret = call_int_hook(mmap_file, 0, file, prot,
-
mmap_prot(file, prot)
, flags);
+
+
ret = call_int_hook(mmap_file, 0, file, prot, prot_adj
, flags);
if (ret)
return ret;
if (ret)
return ret;
- return ima_file_mmap(file, prot);
+ return ima_file_mmap(file, prot
, prot_adj, flags
);
}
int security_mmap_addr(unsigned long addr)
}
int security_mmap_addr(unsigned long addr)