projects
/
GitHub
/
MotorolaMobilityLLC
/
kernel-slsi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
027f27c
)
parisc: ensure that mmapped shared pages are aligned at SHMLBA addresses
author
John David Anglin
<dave.anglin@bell.net>
Sat, 2 Feb 2013 23:44:59 +0000
(23:44 +0000)
committer
Helge Deller
<deller@gmx.de>
Wed, 20 Feb 2013 21:50:50 +0000
(22:50 +0100)
Signed-off-by: John David Anglin <dave.anglin@bell.net>
Signed-off-by: Helge Deller <deller@gmx.de>
arch/parisc/kernel/sys_parisc.c
patch
|
blob
|
blame
|
history
diff --git
a/arch/parisc/kernel/sys_parisc.c
b/arch/parisc/kernel/sys_parisc.c
index f76c10863c6266c5a4fe6a3fbbe22d022a11e8c2..a047b3227e503bf3a9fe23766d8dea14cf0ea2e8 100644
(file)
--- a/
arch/parisc/kernel/sys_parisc.c
+++ b/
arch/parisc/kernel/sys_parisc.c
@@
-94,11
+94,12
@@
unsigned long arch_get_unmapped_area(struct file *filp, unsigned long addr,
{
if (len > TASK_SIZE)
return -ENOMEM;
- /* Might want to check for cache aliasing issues for MAP_FIXED case
- * like ARM or MIPS ??? --BenH.
- */
- if (flags & MAP_FIXED)
+ if (flags & MAP_FIXED) {
+ if ((flags & MAP_SHARED) &&
+ (addr - (pgoff << PAGE_SHIFT)) & (SHMLBA - 1))
+ return -EINVAL;
return addr;
+ }
if (!addr)
addr = TASK_UNMAPPED_BASE;