On Tue, 23 Jan 2001, Jamey Hicks wrote:
> Sukjae,
>
> Great work!
>
> It looks like I was the one who assigned pm_power_off, replacing
> sa1100_power_off. I think the original apm.c did that, so I did it in the
> new one. I fixed it in arch/arm/mach-sa1100/apm.c.
You may keep the original assignment, as long as the APM version (which
should call for all drivers to turn their hardware off) jumps to
sa1100_power_off() at the end.
> Before halting, we need to make sure the PWER is set up to wake on the
> suspend button. I see, that also happens in sa1100_power_off. Cool.
>
> Nicolas -- what should the bootldr do when it wakes up? Where should it
> jump?
Here is what I think it should look like:
ldr r0, =PSSR
ldr r1, [r0] @ let's find what happened
mov r2, #PSSR_SS
tst r1, r2 @ are we waking up after a suspend?
beq skip
str r2, [r0] @ clear that bit
/* ... get RAM out of self-refresh mode */
ldr r0, =PSPR
ldr pc, [r0] @ jump where the kernel is expecting us to.
skip:
/* ... go on with the usual cold boot stuff */
Then if we want the sleep mode to actually mean a real shutdown, then simply
storing 0 into PSPR would make the execution reference the reset vector
again, but with PSSR_SS cleared.
> I loaded the updated apm, and now shutdown -h powers off (as near as I can
> tell), but the power button does not seem to wake up the bootldr.
I have the same behavior on Assabet. The CPU is apparently waken up but it
doesn't get out of the boot loader.
If bootldr isn't sleep-mode aware, it should at least perform a cold boot.
For some reason it doesn't. Maybe there is something special to do when ram
is in self refresh mode for things to work properly.
Nicolas
Received on Tue Jan 23 15:58:49 2001
This archive was generated by hypermail 2.1.8 : Tue May 04 2004 - 09:43:51 EDT