diff options
Diffstat (limited to 'arch/mips/kernel/syscall.c')
-rw-r--r-- | arch/mips/kernel/syscall.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/arch/mips/kernel/syscall.c b/arch/mips/kernel/syscall.c index e96b1c30c7aa..dd81b0f87518 100644 --- a/arch/mips/kernel/syscall.c +++ b/arch/mips/kernel/syscall.c | |||
@@ -19,7 +19,6 @@ | |||
19 | #include <linux/string.h> | 19 | #include <linux/string.h> |
20 | #include <linux/syscalls.h> | 20 | #include <linux/syscalls.h> |
21 | #include <linux/file.h> | 21 | #include <linux/file.h> |
22 | #include <linux/slab.h> | ||
23 | #include <linux/utsname.h> | 22 | #include <linux/utsname.h> |
24 | #include <linux/unistd.h> | 23 | #include <linux/unistd.h> |
25 | #include <linux/sem.h> | 24 | #include <linux/sem.h> |
@@ -29,6 +28,7 @@ | |||
29 | #include <linux/module.h> | 28 | #include <linux/module.h> |
30 | #include <linux/ipc.h> | 29 | #include <linux/ipc.h> |
31 | #include <linux/uaccess.h> | 30 | #include <linux/uaccess.h> |
31 | #include <linux/slab.h> | ||
32 | 32 | ||
33 | #include <asm/asm.h> | 33 | #include <asm/asm.h> |
34 | #include <asm/branch.h> | 34 | #include <asm/branch.h> |
@@ -79,7 +79,11 @@ unsigned long arch_get_unmapped_area(struct file *filp, unsigned long addr, | |||
79 | int do_color_align; | 79 | int do_color_align; |
80 | unsigned long task_size; | 80 | unsigned long task_size; |
81 | 81 | ||
82 | task_size = STACK_TOP; | 82 | #ifdef CONFIG_32BIT |
83 | task_size = TASK_SIZE; | ||
84 | #else /* Must be CONFIG_64BIT*/ | ||
85 | task_size = test_thread_flag(TIF_32BIT_ADDR) ? TASK_SIZE32 : TASK_SIZE; | ||
86 | #endif | ||
83 | 87 | ||
84 | if (len > task_size) | 88 | if (len > task_size) |
85 | return -ENOMEM; | 89 | return -ENOMEM; |