diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2009-03-03 13:30:03 +1100 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2009-03-03 13:30:03 +1100 |
commit | 652e8f8d579d61745094e36b4ff085026a332e73 (patch) | |
tree | 44145576f9cdf0b777dee0d0961f5499ea88bec8 /arch/powerpc/kernel/head_booke.h | |
parent | 501cb16d3cfdcca99ac26fe122079f2a43b046b8 (diff) | |
parent | 6c7120902305b3a21460cd2f0f917a39307df566 (diff) | |
download | blackbird-op-linux-652e8f8d579d61745094e36b4ff085026a332e73.tar.gz blackbird-op-linux-652e8f8d579d61745094e36b4ff085026a332e73.zip |
Merge commit 'jwb/next' into next
Diffstat (limited to 'arch/powerpc/kernel/head_booke.h')
-rw-r--r-- | arch/powerpc/kernel/head_booke.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/arch/powerpc/kernel/head_booke.h b/arch/powerpc/kernel/head_booke.h index 38e242eb0ef8..95f39f1e68d4 100644 --- a/arch/powerpc/kernel/head_booke.h +++ b/arch/powerpc/kernel/head_booke.h @@ -10,6 +10,15 @@ mtspr SPRN_IVOR##vector_number,r26; \ sync +#if (THREAD_SHIFT < 15) +#define ALLOC_STACK_FRAME(reg, val) \ + addi reg,reg,val +#else +#define ALLOC_STACK_FRAME(reg, val) \ + addis reg,reg,val@ha; \ + addi reg,reg,val@l +#endif + #define NORMAL_EXCEPTION_PROLOG \ mtspr SPRN_SPRG0,r10; /* save two registers to work with */\ mtspr SPRN_SPRG1,r11; \ @@ -20,7 +29,7 @@ beq 1f; \ mfspr r1,SPRN_SPRG3; /* if from user, start at top of */\ lwz r1,THREAD_INFO-THREAD(r1); /* this thread's kernel stack */\ - addi r1,r1,THREAD_SIZE; \ + ALLOC_STACK_FRAME(r1, THREAD_SIZE); \ 1: subi r1,r1,INT_FRAME_SIZE; /* Allocate an exception frame */\ mr r11,r1; \ stw r10,_CCR(r11); /* save various registers */\ |