Re: patch for apm_bios.c (kernel 2.0.30)

Keith Rohrer (kwrohrer@uiuc.edu)
Mon, 30 Jun 1997 08:27:53 -0500 (CDT)


And lo, Dong Chen saith unto me:
> This is a patch for "drivers/char/apm_bios.c", it fixes the following
> problems:

> (1) On some notebooks (AST J series, for example), the timer on interrupt 0
> is reset to DOS default: 18 Hz. This patch re-initialize it to 100 Hz.
> Thanks to Pavel (pavel@Elf.mj.gts.cz) for pointing out to me that I should
> add some delays after the outb_p() and outb() calls.
IIRC, you should set it to HZ Hz; that's what HZ is for, right?

Related question: If I build a kernel for x86 but change HZ to, say, 200
or 500 or 1000, will I (a) get more frequent scheduling, (b) almost get
more frequent scheduling except for bugs hard-coding an HZ==100 assumption,
(c) get a total mess, or (d) get a total mess and get flamed to RTFS?

> (2) The clock is not correctly restored after a standby().
I've seen this under 2.1.29 with Award BIOS (I'm not sure if it's a
suspend or a standby, or both, that does it), so if any APM fixes
are in 2.1 but not 2.0, they didn't fix this behavior.

Keith