[PATCH 1/7] PowerPC64: Not to insert EA=0 entry at
benh at kernel.crashing.org
Fri Sep 28 08:20:17 EST 2007
On Thu, 2007-09-27 at 20:22 +0900, Ishizaki Kou wrote:
> > On Thu, 2007-09-27 at 17:01 +0900, kou.ishizaki at toshiba.co.jp wrote:
> > > Celleb does not set get_paca()->kstack properly (I don't know which
> > > function should set it up), so we need to workaround.
> > paca->kstack is set in asm (via the PACAKSAVE macro), from either
> > __secondary_start for non-boot CPUs or from start_here_common for the
> > boot CPU.
> > slb_flush_and_rebolt() should not be called before that happens.
> > How do you end up with kstack set to 0 ?
> I found r13 is not set before entering start_here_common for boot cpu.
> For non-boot threads, __secondary_start will set r13 properly.
> So the problem is to set r13 correct PACA address before entering
> start_here_common. Should it set before entering kernel or will some
> patch make sense?
It should have been set in setup_64.c, in setup_paca() (which is called
twice) in that statement:
local_paca = &paca[cpu];
As local_paca is defined as being a variable held in register r13. Maybe
something bad's happening with the compiler ?
More information about the Linuxppc-dev