DragonFly BSD
DragonFly bugs List (threaded) for 2004-08
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

8254 timer woes

From: "Simon 'corecode' Schubert" <corecode@xxxxxxxxxxxx>
Date: Tue, 31 Aug 2004 02:52:47 +0200


I'm wondering... did we yet find a way to prevent bios calls from trashing our timer? Currently XOrg is freezing my machine (VIA EPIA M10k) when via_drv init reads the VBE EDID. Sure, I could just disable that, but a more clean solution would be to fix this situation.

Short info what happens: system freezes (a little bit) delayed (at least so it seems) when XOrg/via_drv/vbe calls int 0x10/ax=0x4f15/bx=0x01/cx=0x0. I disassembled bits of the VGA BIOS (VGA is a integrated VIA CLE266 unichrome chipset), and it does, besides spooky register handling, set i8254 time counter 2 to divisor 0x4a9, i.e. 1kHz (if I'm not wrong) and then busy loops for a certain time.

Freezing my system means: nothing works any more, I can only break to ddb (if I'm lucky). Time freezes (for DragonFly): nanouptime() always reports the same. calling timer_restore() from ddb/gdb fixes everything: X starts as desired and system works again.

Problem here is that the system completely freezes and not "just" has funny time. The cause of this is that the VGA BIOS (card is an integrated VIA CLE266 unichrome) disables the timer 2 gate. A hackaround for me would be to (unconditionally) set the gate bit in cputimer_count(), but that can't be the real solution.

Is is possible to fault on special port IO so that we can prevent legacy BIOS/programs to destroy our timing?


\ /
 \     ASCII Ribbon Campaign
/ \  Against HTML Mail and News

Attachment: PGP.sig
Description: This is a digitally signed message part

[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]