Skip to content

Commit

Permalink
powerpc: Check that TASK_SIZE does not overlap KERNEL_START
Browse files Browse the repository at this point in the history
Make sure CONFIG_TASK_SIZE does not overlap CONFIG_KERNEL_START
This could happen when overriding settings to get 1GB lowmem, and would lead
to userland mysteriousely hanging.

This setting is only used by PPC32.

Signed-off-by: Rune Torgersen <runet@innovsys.com>
Acked-by: Kumar Gala <galak@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
  • Loading branch information
Rune Torgersen authored and Paul Mackerras committed Jun 9, 2008
1 parent cec0dd9 commit 7c4f10b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions include/asm-powerpc/processor.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,10 @@ extern struct task_struct *last_task_used_altivec;
extern struct task_struct *last_task_used_spe;

#ifdef CONFIG_PPC32

#if CONFIG_TASK_SIZE > CONFIG_KERNEL_START
#error User TASK_SIZE overlaps with KERNEL_START address
#endif
#define TASK_SIZE (CONFIG_TASK_SIZE)

/* This decides where the kernel will search for a free chunk of vm
Expand Down

0 comments on commit 7c4f10b

Please sign in to comment.