RE: apm in RedHat linux 6.0 on tp600

New Message Reply Date view Thread view Subject view Author view Attachment view

From: Aron Hsiao (unit_at_lgcy.com)
Date: Fri Jun 18 1999 - 16:02:35 EDT


On 18-Jun-99 Victor Kress wrote:
> I should have known not to mess with something that's working.
>
> In RH 5.2 one could get apm to work perfectly on a tp600 by undef'ing
> APM_NOINTS in
> /usr/src/linux/drivers/char/apm_bios.c. Apm doesn't work out of the box
> in RH6, so I
> went looking for this option. apm_bios.c does not seem to exist in the
> new source tree,
> and I can't find APM_NOINTS in any source file. Any tips?
>
> -Victor

Not really. Unfortunately, the APM on ThinkPads is just screwy for some
reason, and the kernel keeps changing to try to meet it. In 2.2 kernels,
there are a few things that were inserted -just for- thinkpads, but I
still can't get my 760C to do it properly.

Here's a detail of how difficult it can be: to get mine to suspend, I
first had to discover that:

1. It wouldn't restore properly if it had been suspended with X on
   the display.
2. Hardware suspend (Fn-combo) didn't work at all, and neither did
   "hood-down" suspend.

So, I developed this process:

1. Disable hardware suspends as much as possible.
2. Install apmd (not the daemon part, though -- just to get the 'apm'
   program).
3. Build a bash script which basically did this:
   a. Switch from X to a VT with 'chvt /dev/tty3'
   a1.sleep 2 seconds
   b. Software suspend with the 'apm' program.
   b1.sleep 2 seconds
   c. Switch back to X with 'chvt /dev/tty2' (which is where my X is)

Since step b. suspends the machine, when I unsuspend it by holding down
'Fn', step c. is executed and X is again displayed on the screen. I've
added this little script to my WindowMaker desktop, so that I now suspend
with a menu option rather than with any sort of hardware action. I don't
know if you'll have luck with anything similar, but it has worked for me
on a TP760C.

You can try hacking on the kernel as well; it seems like it's usually a
fairly simple problem with lost interrupts on most ThinkPads, but
unfortunately, they're not all the same, so it's hard for the kernel to
find a consistent solution. They're really great machines, but for some
reason, IBM's APM BIOS implementation seems to have always left
something to be desired. Good luck!

-Aron

--
### These opinions are mine and no one else's.
### ----------------------------------------------------------------
### L I N U X :  The choice of a GNU generation!


New Message Reply Date view Thread view Subject view Author view Attachment view

This archive was generated by hypermail 2.1.3 : Thu Jan 23 2003 - 09:55:07 EST