Ok,
I found that I have made a mistake: "reboot -h" is not the same as "shutdown -h".

The problem with power management is twofold. One is that the reboot - h (restart) does indeed not work. This is probably because that thread finally executes

void jz_restart(char *command)
{
        __wdt_set_count(0xffffffff-32); /* reset after 1/1024 s */
        __wdt_start();
        while (1);
}

Ok, this should trigger the watchdog timer (that is to what I expand wdt). That even works if I press Fn-Ctrl-Shift so that it boots again from SD card...

Now, the halt and power-off commands end up in

void jz_halt(void)
{
        __wdt_set_count(0xffffffff-32); /* reset after 1/1024 s */
        __wdt_start();
        while (1);
}

Which is the same! So the wdt reboots the machine.

So we need to initialize the appropriate hooks in our board-minipc.c file and write our own restart/halt/power_off handlers.

Does anyone have an idea (from a 2.4 kernel?) how we can command the power management chip to turn off power for the CPU and LCM? Does this go through a GPIO?

BR,
Nikolaus

Am 05.05.2010 um 11:16 schrieb Dr. H. Nikolaus Schaller:

Just a first observation:

I have added a printk to kernel/sys.c/sys_reboot() to print the cmd parameter. On reboot -h it appears to be 19000473 (difficult to read before the screen washes out) - but I am not even sure if that value is constant.

Nikolaus

_______________________________________________
Mipsbook-devel mailing list
Mipsbook-devel@linuxtogo.org
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/mipsbook-devel


_______________________________________________
Mipsbook-devel mailing list
Mipsbook-devel@linuxtogo.org
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/mipsbook-devel

Reply via email to