diff options
Diffstat (limited to 'arch/nds32/include/asm/uaccess.h')
-rw-r--r-- | arch/nds32/include/asm/uaccess.h | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/arch/nds32/include/asm/uaccess.h b/arch/nds32/include/asm/uaccess.h index 832d642a4068..377548d4451a 100644 --- a/arch/nds32/include/asm/uaccess.h +++ b/arch/nds32/include/asm/uaccess.h @@ -11,6 +11,7 @@ #include <asm/errno.h> #include <asm/memory.h> #include <asm/types.h> +#include <asm-generic/access_ok.h> #define __asmeq(x, y) ".ifnc " x "," y " ; .err ; .endif\n\t" @@ -33,20 +34,6 @@ struct exception_table_entry { extern int fixup_exception(struct pt_regs *regs); -#define KERNEL_DS ((mm_segment_t) { ~0UL }) -#define USER_DS ((mm_segment_t) {TASK_SIZE - 1}) - -#define get_fs() (current_thread_info()->addr_limit) -#define user_addr_max get_fs -#define uaccess_kernel() (get_fs() == KERNEL_DS) - -static inline void set_fs(mm_segment_t fs) -{ - current_thread_info()->addr_limit = fs; -} - -#include <asm-generic/access_ok.h> - /* * Single-value transfer routines. They automatically use the right * size if we just have the right pointer type. Note that the functions |