diff options
Diffstat (limited to 'arch/mips/kernel/syscall.c')
| -rw-r--r-- | arch/mips/kernel/syscall.c | 6 | 
1 files changed, 5 insertions, 1 deletions
diff --git a/arch/mips/kernel/syscall.c b/arch/mips/kernel/syscall.c index 9587abc67f3..dd81b0f8751 100644 --- a/arch/mips/kernel/syscall.c +++ b/arch/mips/kernel/syscall.c @@ -79,7 +79,11 @@ unsigned long arch_get_unmapped_area(struct file *filp, unsigned long addr,  	int do_color_align;  	unsigned long task_size; -	task_size = STACK_TOP; +#ifdef CONFIG_32BIT +	task_size = TASK_SIZE; +#else /* Must be CONFIG_64BIT*/ +	task_size = test_thread_flag(TIF_32BIT_ADDR) ? TASK_SIZE32 : TASK_SIZE; +#endif  	if (len > task_size)  		return -ENOMEM;  |