aboutsummaryrefslogtreecommitdiffstats
path: root/arch/parisc
diff options
context:
space:
mode:
authorJohn David Anglin <dave.anglin@bell.net>2013-02-02 18:44:59 -0500
committerHelge Deller <deller@gmx.de>2013-02-20 16:50:50 -0500
commit5ca8b91df88fa417aa7aac19494a8ae1602db2cb (patch)
tree513cd4f4cad27094c110ef9a2bd92b6d0847429e /arch/parisc
parent027f27c4eca00b4411fb1fe61c33060569ff73f6 (diff)
parisc: ensure that mmapped shared pages are aligned at SHMLBA addresses
Signed-off-by: John David Anglin <dave.anglin@bell.net> Signed-off-by: Helge Deller <deller@gmx.de>
Diffstat (limited to 'arch/parisc')
-rw-r--r--arch/parisc/kernel/sys_parisc.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/arch/parisc/kernel/sys_parisc.c b/arch/parisc/kernel/sys_parisc.c
index f76c10863c62..a047b3227e50 100644
--- 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,
94{ 94{
95 if (len > TASK_SIZE) 95 if (len > TASK_SIZE)
96 return -ENOMEM; 96 return -ENOMEM;
97 /* Might want to check for cache aliasing issues for MAP_FIXED case 97 if (flags & MAP_FIXED) {
98 * like ARM or MIPS ??? --BenH. 98 if ((flags & MAP_SHARED) &&
99 */ 99 (addr - (pgoff << PAGE_SHIFT)) & (SHMLBA - 1))
100 if (flags & MAP_FIXED) 100 return -EINVAL;
101 return addr; 101 return addr;
102 }
102 if (!addr) 103 if (!addr)
103 addr = TASK_UNMAPPED_BASE; 104 addr = TASK_UNMAPPED_BASE;
104 105