]> git.karo-electronics.de Git - linux-beck.git/commitdiff
asm-generic headers: uaccess.h to conditionally define segment_eq()
authorVineet Gupta <vgupta@synopsys.com>
Fri, 18 Jan 2013 09:42:16 +0000 (15:12 +0530)
committerVineet Gupta <vgupta@synopsys.com>
Mon, 11 Feb 2013 14:30:31 +0000 (20:00 +0530)
This is because mm_segment_t is exported by arch code, while seqment_eq
assumes it will have .seg element.

Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
include/asm-generic/uaccess.h

index 9788568f79782befb0be7cf29d148220f9c898c4..5f6ee6138f9a338d59d12b2b8bc1d37bf7547c4e 100644 (file)
@@ -7,7 +7,6 @@
  * address space, e.g. all NOMMU machines.
  */
 #include <linux/sched.h>
-#include <linux/mm.h>
 #include <linux/string.h>
 
 #include <asm/segment.h>
@@ -32,7 +31,9 @@ static inline void set_fs(mm_segment_t fs)
 }
 #endif
 
+#ifndef segment_eq
 #define segment_eq(a, b) ((a).seg == (b).seg)
+#endif
 
 #define VERIFY_READ    0
 #define VERIFY_WRITE   1