HELP: "reboot" and "ctrl-alt-del" causes system to hang...

HELP: "reboot" and "ctrl-alt-del" causes system to hang...

Post by Lawrence N. Shapir » Thu, 26 Sep 1996 04:00:00



Using Linux 1.2.13 on Pentium 133Mhz with AWARD BIOS

After entering "reboot" or "ctrl-alt-del" linux shuts downs correctly.
The last thing printed on the screen is "rebooting". After that nothing
happens. The only way to recover is powerdown reboot.

ANY SUGGESTION IS HELPFUL!

Larry Shapiro

 
 
 

HELP: "reboot" and "ctrl-alt-del" causes system to hang...

Post by David J. L » Fri, 27 Sep 1996 04:00:00



# Using Linux 1.2.13 on Pentium 133Mhz with AWARD BIOS
# After entering "reboot" or "ctrl-alt-del" linux shuts downs correctly.
# The last thing printed on the screen is "rebooting". After that nothing
# happens. The only way to recover is powerdown reboot.

Another way is to press the reset button.

This problem might be related to particular combinations of HW and BIOS.
It has been known for some time that the optimization program of QEMM,
which reboots the PC twice, prints a message stating that some systems
may not reboot, and that the user may have to power down and power up.

To rule out the liability of Linux, run the following test:
Boot DOS, type
  echo g=ffff:0 | debug
and if the system does not reboot, it must be a HW/BIOS problem.

 
 
 

HELP: "reboot" and "ctrl-alt-del" causes system to hang...

Post by Ray Ramsde » Fri, 27 Sep 1996 04:00:00




> # Using Linux 1.2.13 on Pentium 133Mhz with AWARD BIOS
> # After entering "reboot" or "ctrl-alt-del" linux shuts downs correctly.
> # The last thing printed on the screen is "rebooting". After that nothing
> # happens. The only way to recover is powerdown reboot.

> Another way is to press the reset button.

> This problem might be related to particular combinations of HW and BIOS.
> It has been known for some time that the optimization program of QEMM,
> which reboots the PC twice, prints a message stating that some systems
> may not reboot, and that the user may have to power down and power up.

> To rule out the liability of Linux, run the following test:
> Boot DOS, type
>   echo g=ffff:0 | debug
> and if the system does not reboot, it must be a HW/BIOS problem.

I have the same problem as he. Linux pulses the keyboard controller's
reset line to reset the system. I have *several* DOS progames that work
with the same method that work.

Here's what I did (roughly) to fix the problem:

You have to hack the kernel a bit. Instead of using the keyboard
controller, we can simply cause a processor panic (for x86es that is).

The assembly source code is:

        xor sp,sp
        inc sp
        push sp

Simple as that, works every time. It works by moving the stack pointer
to logical 1 and then pushing a register (push sp is a good way to crash
anyway). Since Intel *for some reason* made their CPUs little-endian
(why? why?) it gets halfway through the push and cannot decrement for
the next byte and crashes, causing the CPU to reset.

You have to remove the old reboot code (comment out the routine
hard_reboot_now) and put that code in someplace else. I added the new
routines to head.S and it worked fine. I *believe* that the code in
Linux is:

        xor %sp,%sp
        inc %sp
        push %sp

I'm not sure, I don't have access to my box right now (I am at work and
I forgot to leave it up). I do remember that the old code was in
process.c, so you are welcome to try it. I have yet to find a computer
that this does not work on.

DISCLAIMER: AS FAR AS I KNOW THIS CODE IS HARMLESS, I HAVE BEEN USING IT
FOR A LONG TIME, BUT IF YOU MESS UP YOUR COMPUTER IN ANY WAY, DON'T
BLAME ME!

 
 
 

HELP: "reboot" and "ctrl-alt-del" causes system to hang...

Post by Joachim Seel » Sat, 28 Sep 1996 04:00:00




: # Using Linux 1.2.13 on Pentium 133Mhz with AWARD BIOS
: # After entering "reboot" or "ctrl-alt-del" linux shuts downs correctly.
: # The last thing printed on the screen is "rebooting". After that nothing
: # happens. The only way to recover is powerdown reboot.

: This problem might be related to particular combinations of HW and BIOS.

...and to the way, You started linux. On my system (ASUS PVI-486SP3, AMD
DX4-100) I get a similar behaviour, if I started linux via loadlin. Using
reboot causes the system to hang after unmounting the filesystems. If linux
was started with lilo, everything works fine (including reboot :-)).

Gruss, Joachim

 
 
 

HELP: "reboot" and "ctrl-alt-del" causes system to hang...

Post by Keith Rohr » Mon, 30 Sep 1996 04:00:00






>: # Using Linux 1.2.13 on Pentium 133Mhz with AWARD BIOS
>: # After entering "reboot" or "ctrl-alt-del" linux shuts downs correctly.
>: # The last thing printed on the screen is "rebooting". After that nothing
>: # happens. The only way to recover is powerdown reboot.

>: This problem might be related to particular combinations of HW and BIOS.

>...and to the way, You started linux. On my system (ASUS PVI-486SP3, AMD
>DX4-100) I get a similar behaviour, if I started linux via loadlin. Using
>reboot causes the system to hang after unmounting the filesystems. If linux
>was started with lilo, everything works fine (including reboot :-)).

I always use lilo, and while mine never says "rebooting" and fails to
reboot, sometimes when I hit C-A-D it gives the first two lines about
switching to runlevel 6, then hangs; my options are poweroff, or hit
C-A-D some more, making the disk twitch each time I do so.  I know
there was a -r 3 or some such in my inittab (which I've removed from
the ctrlaltdel line), but it still happens sometimes.  Clues?  

        Keith (fsck is a four-letter word)

--
Disclaimer:  Do not taunt Happy Fun God.

 
 
 

HELP: "reboot" and "ctrl-alt-del" causes system to hang...

Post by Ray Ramsde » Tue, 08 Oct 1996 04:00:00



> Using Linux 1.2.13 on Pentium 133Mhz with AWARD BIOS

> After entering "reboot" or "ctrl-alt-del" linux shuts downs correctly.
> The last thing printed on the screen is "rebooting". After that nothing
> happens. The only way to recover is powerdown reboot.

> ANY SUGGESTION IS HELPFUL!

> Larry Shapiro


OKOK, due to several emailed requests, he're my solution...

I run the Award 4.50g bios on my Pentium. When I use Loadlin, it hangs,
but *usually* when I use Lilo, no hang. I fiddled with the reboot code,
and here's my fix:

1) edit your /usr/src/linux/arch/i386/kernel/process.c
2) comment out all code inside hard_reset_now
3) inside hard_reboot_now, add the following lines:

__asm__("xor  %esp, %esp
         inc  %esp
         push %esp");

4) Save and make zImage

Have fun!
-=Ray=-

(P.S. Credit for the code goes to Aaron Peterson, the smallest reset
code I have ever seen)