]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
get_unmapped_area handles MAP_FIXED on parisc
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Sun, 6 May 2007 21:50:09 +0000 (14:50 -0700)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Mon, 7 May 2007 19:12:56 +0000 (12:12 -0700)
Handle MAP_FIXED in parisc arch_get_unmapped_area(), just return the address.
We might want to also check for possible cache aliasing issues now that we get
called in that case (like ARM or MIPS), leave a comment for the maintainers to
pick up.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Cc: Grant Grundler <grundler@parisc-linux.org>
Cc: Matthew Wilcox <willy@debian.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/parisc/kernel/sys_parisc.c

index 512642d8f707ce7208a99b5c0e2136c02c065c5e..6fed0803c59378ef038694ed2038805516899d0a 100644 (file)
@@ -106,6 +106,11 @@ 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)
+               return addr;
        if (!addr)
                addr = TASK_UNMAPPED_BASE;