Ronald G Minnich <[EMAIL PROTECTED]> writes:

> On Sun, 10 Feb 2002, Elias Rajczyk wrote:
> 
> >
> > Someone a clue why some systems get stuck after the "reboot" command.
> > Linux just outs "Restarting system" and freezes. Is is as if Linuxbios
> > doesn't give it a second rundown
> 
> 
> Linux doesn't quite handle reset right. We've found experimentally that
> most of the ways that Linux "reboots" involve the dreaded triple-fault.
> There's a lot of code to do restart in the kernel -- first try is the
> keyboard controller, second try is the 'go to 16-bit mode and call BIOS',
> third try is 'kick ourselves until we fall over (triple fault)'. We've
> found via tracing with the hardware In-Circuit Emulator that the 'go to
> 16-bit-mode' code is totally broken, the keyboard code is marginal, and
> that what happens most of the time is the triple-fault path.
> 
> If you have a PIIX4E I have reset code that works.
> 
> This is actually the Pentium's fault -- it has no RESET instruction,
> unlike earlier micros.

And equally interesting you have to enable tripple faults rebooting
the CPU in the southbridge.  Tripple faults natively hang the cpu.

What I have done is skipped the memory setup and then let the C code
notice this is a reboot and it calls hard_reset in hardwaremain.c.
And in hard_reset I just stick the code to do a board level reset.  

This is pretty much trivial to implement and handles the reboot cases
without a modified kernel.

Ron all the keyboard controller does is reset the cpu so in that case
there really is not difference between that code and a tripple fault.

Eric

Reply via email to