Yan Seiner wrote:
> I am having a problem rebooting the ts7200.
>
> I issue the reboot command, and it goes through the motions but then
> hangs:
>
> root:~> reboot
> The system is going down NOW !!
> Sending SIGTERM to all processes.
> Terminated
> Requesting system reboot.
>
> and nothing happens.
>
> I am currently running busybox 1.2.1, but this has happened with
> earlier versions as well.
>
> Is there a reliable way to reboot the board via software?
>
I also have this problem with busybox 1.2.1
I use the following snippet of code from busybox 1.0 to reboot the board.
int restart_system( void )
{
#ifndef RB_AUTOBOOT
#define RB_AUTOBOOT 0x01234567
#endif
/* Don't kill ourself */
signal(SIGTERM,SIG_IGN);
signal(SIGHUP,SIG_IGN);
setpgrp();
/* Allow Ctrl-Alt-Del to reboot system. */
#ifndef RB_ENABLE_CAD
#define RB_ENABLE_CAD 0x89abcdef
#endif
reboot(RB_ENABLE_CAD);
sync();
kill(-1, SIGTERM);
sleep(1);
sync();
kill(-1, SIGKILL);
sleep(1);
sync();
reboot(RB_AUTOBOOT);
return 0; /* Shrug */
}
Chris.
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/ts-7000/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/ts-7000/join
(Yahoo! ID required)
<*> To change settings via email:
<*> To unsubscribe from this group, send an email to:
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|