]> err.no Git - linux-2.6/commitdiff
sparc: Merge asm-sparc{,64}/mman.h
authorSam Ravnborg <sam@ravnborg.org>
Fri, 6 Jun 2008 18:51:20 +0000 (20:51 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 18 Jul 2008 04:41:51 +0000 (21:41 -0700)
Renaming the function sparc64_mmap_check() to
sparc_mmap_check() was enough to make the two
header files identical.

:$ diff -u include/asm-sparc/mman.h include/asm-sparc64/mman.h
:-- include/asm-sparc/mman.h 2008-06-13 06:46:39.000000000 +0200
:++ include/asm-sparc64/mman.h 2008-06-13 06:46:39.000000000 +0200
:@@ -1,5 +1,5 @@
:-#ifndef __SPARC_MMAN_H__
:-#define __SPARC_MMAN_H__
:+#ifndef __SPARC64_MMAN_H__
:+#define __SPARC64_MMAN_H__
:
: #include <asm-generic/mman.h>
:
:@@ -23,9 +23,9 @@
:
: #ifdef __KERNEL__
: #ifndef __ASSEMBLY__
:-#define arch_mmap_check(addr,len,flags) sparc_mmap_check(addr,len)
:-int sparc_mmap_check(unsigned long addr, unsigned long len);
:+#define arch_mmap_check(addr,len,flags) sparc64_mmap_check(addr,len)
:+int sparc64_mmap_check(unsigned long addr, unsigned long len);
: #endif
: #endif
:
:-#endif /* __SPARC_MMAN_H__ */
:+#endif /* __SPARC64_MMAN_H__ */

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
arch/sparc64/kernel/sys_sparc.c
arch/sparc64/kernel/sys_sparc32.c
include/asm-sparc64/mman.h

index ac1bff58c1ac8319eb0178e0980eeda35dfb1a32..e1f4eba2e5760191a728f472345ead476fc72ba5 100644 (file)
@@ -542,7 +542,7 @@ asmlinkage long sparc64_personality(unsigned long personality)
        return ret;
 }
 
-int sparc64_mmap_check(unsigned long addr, unsigned long len)
+int sparc_mmap_check(unsigned long addr, unsigned long len)
 {
        if (test_thread_flag(TIF_32BIT)) {
                if (len >= STACK_TOP32)
@@ -614,9 +614,9 @@ asmlinkage unsigned long sys64_mremap(unsigned long addr,
                goto out;
        if (unlikely(new_len >= VA_EXCLUDE_START))
                goto out;
-       if (unlikely(sparc64_mmap_check(addr, old_len)))
+       if (unlikely(sparc_mmap_check(addr, old_len)))
                goto out;
-       if (unlikely(sparc64_mmap_check(new_addr, new_len)))
+       if (unlikely(sparc_mmap_check(new_addr, new_len)))
                goto out;
 
        down_write(&current->mm->mmap_sem);
index 590679795ce2484ab19938966349695ec7a42a7e..97b77fb5c50e8d127750bfd4dd8c5c917f137c35 100644 (file)
@@ -871,9 +871,9 @@ asmlinkage unsigned long sys32_mremap(unsigned long addr,
        unsigned long ret = -EINVAL;
        unsigned long new_addr = __new_addr;
 
-       if (unlikely(sparc64_mmap_check(addr, old_len)))
+       if (unlikely(sparc_mmap_check(addr, old_len)))
                goto out;
-       if (unlikely(sparc64_mmap_check(new_addr, new_len)))
+       if (unlikely(sparc_mmap_check(new_addr, new_len)))
                goto out;
        down_write(&current->mm->mmap_sem);
        ret = do_mremap(addr, old_len, new_len, flags, new_addr);
index d2ae67cd1bdcfca0c5cb4a11f257b5b7d93d6b6d..17ddb1724f51676be68be0c3738fa6a4ef9ed14b 100644 (file)
@@ -1,31 +1 @@
-#ifndef __SPARC64_MMAN_H__
-#define __SPARC64_MMAN_H__
-
-#include <asm-generic/mman.h>
-
-/* SunOS'ified... */
-
-#define MAP_RENAME      MAP_ANONYMOUS   /* In SunOS terminology */
-#define MAP_NORESERVE   0x40            /* don't reserve swap pages */
-#define MAP_INHERIT     0x80            /* SunOS doesn't do this, but... */
-#define MAP_LOCKED      0x100           /* lock the mapping */
-#define _MAP_NEW        0x80000000      /* Binary compatibility is fun... */
-
-#define MAP_GROWSDOWN  0x0200          /* stack-like segment */
-#define MAP_DENYWRITE  0x0800          /* ETXTBSY */
-#define MAP_EXECUTABLE 0x1000          /* mark it as an executable */
-
-#define MCL_CURRENT     0x2000          /* lock all currently mapped pages */
-#define MCL_FUTURE      0x4000          /* lock all additions to address space */
-
-#define MAP_POPULATE   0x8000          /* populate (prefault) pagetables */
-#define MAP_NONBLOCK   0x10000         /* do not block on IO */
-
-#ifdef __KERNEL__
-#ifndef __ASSEMBLY__
-#define arch_mmap_check(addr,len,flags)        sparc64_mmap_check(addr,len)
-int sparc64_mmap_check(unsigned long addr, unsigned long len);
-#endif
-#endif
-
-#endif /* __SPARC64_MMAN_H__ */
+#include <asm-sparc/mman.h>