[PATCH] sh64: task_stack_page()

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>

authored by Al Viro and committed by Linus Torvalds ee8c1dd4 7fdf0d7a

+3 -3
+2 -2
arch/sh64/kernel/process.c
··· 744 } 745 #endif 746 /* Copy from sh version */ 747 - childregs = ((struct pt_regs *)(THREAD_SIZE + (unsigned long) p->thread_info )) - 1; 748 749 *childregs = *regs; 750 ··· 752 childregs->regs[15] = usp; 753 p->thread.uregs = childregs; 754 } else { 755 - childregs->regs[15] = (unsigned long)p->thread_info + THREAD_SIZE; 756 } 757 758 childregs->regs[9] = 0; /* Set return value for child */
··· 744 } 745 #endif 746 /* Copy from sh version */ 747 + childregs = (struct pt_regs *)(THREAD_SIZE + task_stack_page(p)) - 1; 748 749 *childregs = *regs; 750 ··· 752 childregs->regs[15] = usp; 753 p->thread.uregs = childregs; 754 } else { 755 + childregs->regs[15] = (unsigned long)task_stack_page(p) + THREAD_SIZE; 756 } 757 758 childregs->regs[9] = 0; /* Set return value for child */
+1 -1
arch/sh64/lib/dbg.c
··· 174 struct ring_node *rr; 175 176 pid = current->pid; 177 - stack_bottom = (unsigned long) current->thread_info; 178 asm volatile("ori r15, 0, %0" : "=r" (sp)); 179 rr = event_ring + event_ptr; 180 rr->evt = evt;
··· 174 struct ring_node *rr; 175 176 pid = current->pid; 177 + stack_bottom = (unsigned long) task_stack_page(current); 178 asm volatile("ori r15, 0, %0" : "=r" (sp)); 179 rr = event_ring + event_ptr; 180 rr->evt = evt;