From 2d67ae923d11d766d9a6cea714fa487b52579f6a Mon Sep 17 00:00:00 2001 From: Trutz Behn Date: Wed, 28 Jan 2015 18:46:52 +0100 Subject: [PATCH] move MREMAP_MAYMOVE and MREMAP_FIXED out of bits the definitions are generic for all kernel archs. exposure of these macros now only occurs on the same feature test as for the function accepting them, which is believed to be more correct. --- arch/arm/bits/mman.h | 3 --- arch/i386/bits/mman.h | 3 --- arch/microblaze/bits/mman.h | 3 --- arch/mips/bits/mman.h | 3 --- arch/or1k/bits/mman.h | 3 --- arch/powerpc/bits/mman.h | 3 --- arch/sh/bits/mman.h | 3 --- arch/x32/bits/mman.h | 3 --- arch/x86_64/bits/mman.h | 3 --- include/sys/mman.h | 2 ++ 10 files changed, 2 insertions(+), 27 deletions(-) diff --git a/arch/arm/bits/mman.h b/arch/arm/bits/mman.h index 8c4110f1..cc854aae 100644 --- a/arch/arm/bits/mman.h +++ b/arch/arm/bits/mman.h @@ -55,7 +55,4 @@ #define MADV_DODUMP 17 #define MADV_HWPOISON 100 #define MADV_SOFT_OFFLINE 101 - -#define MREMAP_MAYMOVE 1 -#define MREMAP_FIXED 2 #endif diff --git a/arch/i386/bits/mman.h b/arch/i386/bits/mman.h index add63855..0f53acb7 100644 --- a/arch/i386/bits/mman.h +++ b/arch/i386/bits/mman.h @@ -56,7 +56,4 @@ #define MADV_DODUMP 17 #define MADV_HWPOISON 100 #define MADV_SOFT_OFFLINE 101 - -#define MREMAP_MAYMOVE 1 -#define MREMAP_FIXED 2 #endif diff --git a/arch/microblaze/bits/mman.h b/arch/microblaze/bits/mman.h index 8c4110f1..cc854aae 100644 --- a/arch/microblaze/bits/mman.h +++ b/arch/microblaze/bits/mman.h @@ -55,7 +55,4 @@ #define MADV_DODUMP 17 #define MADV_HWPOISON 100 #define MADV_SOFT_OFFLINE 101 - -#define MREMAP_MAYMOVE 1 -#define MREMAP_FIXED 2 #endif diff --git a/arch/mips/bits/mman.h b/arch/mips/bits/mman.h index ac8dd5e5..3125fc2b 100644 --- a/arch/mips/bits/mman.h +++ b/arch/mips/bits/mman.h @@ -54,7 +54,4 @@ #define MADV_DONTDUMP 16 #define MADV_DODUMP 17 #define MADV_HWPOISON 100 - -#define MREMAP_MAYMOVE 1 -#define MREMAP_FIXED 2 #endif diff --git a/arch/or1k/bits/mman.h b/arch/or1k/bits/mman.h index 8c4110f1..cc854aae 100644 --- a/arch/or1k/bits/mman.h +++ b/arch/or1k/bits/mman.h @@ -55,7 +55,4 @@ #define MADV_DODUMP 17 #define MADV_HWPOISON 100 #define MADV_SOFT_OFFLINE 101 - -#define MREMAP_MAYMOVE 1 -#define MREMAP_FIXED 2 #endif diff --git a/arch/powerpc/bits/mman.h b/arch/powerpc/bits/mman.h index 15e3049e..fe8de2b9 100644 --- a/arch/powerpc/bits/mman.h +++ b/arch/powerpc/bits/mman.h @@ -55,7 +55,4 @@ #define MADV_DODUMP 17 #define MADV_HWPOISON 100 #define MADV_SOFT_OFFLINE 101 - -#define MREMAP_MAYMOVE 1 -#define MREMAP_FIXED 2 #endif diff --git a/arch/sh/bits/mman.h b/arch/sh/bits/mman.h index f199f4b4..f6fc98f0 100644 --- a/arch/sh/bits/mman.h +++ b/arch/sh/bits/mman.h @@ -56,7 +56,4 @@ #define MADV_DODUMP 17 #define MADV_HWPOISON 100 #define MADV_SOFT_OFFLINE 101 - -#define MREMAP_MAYMOVE 1 -#define MREMAP_FIXED 2 #endif diff --git a/arch/x32/bits/mman.h b/arch/x32/bits/mman.h index dcab47a4..846b7eae 100644 --- a/arch/x32/bits/mman.h +++ b/arch/x32/bits/mman.h @@ -56,7 +56,4 @@ #define MADV_DODUMP 17 #define MADV_HWPOISON 100 #define MADV_SOFT_OFFLINE 101 - -#define MREMAP_MAYMOVE 1 -#define MREMAP_FIXED 2 #endif diff --git a/arch/x86_64/bits/mman.h b/arch/x86_64/bits/mman.h index dcab47a4..846b7eae 100644 --- a/arch/x86_64/bits/mman.h +++ b/arch/x86_64/bits/mman.h @@ -56,7 +56,4 @@ #define MADV_DODUMP 17 #define MADV_HWPOISON 100 #define MADV_SOFT_OFFLINE 101 - -#define MREMAP_MAYMOVE 1 -#define MREMAP_FIXED 2 #endif diff --git a/include/sys/mman.h b/include/sys/mman.h index a34448a6..9fc2db51 100644 --- a/include/sys/mman.h +++ b/include/sys/mman.h @@ -32,6 +32,8 @@ int mlockall (int); int munlockall (void); #ifdef _GNU_SOURCE +#define MREMAP_MAYMOVE 1 +#define MREMAP_FIXED 2 void *mremap (void *, size_t, size_t, int, ...); int remap_file_pages (void *, size_t, int, size_t, int); #endif -- 2.25.1