mirror of
https://github.com/joncampbell123/dosbox-x.git
synced 2025-05-09 03:41:10 +08:00
Timer: Write BIOS data area at a time that follows the BIOS zeroing the lower 32KB on first boot, so that the 8/10MHz timer clock source bit can be reflected properly
This commit is contained in:
parent
cc913aed9c
commit
24789fe685
@ -512,6 +512,13 @@ void TIMER_BIOS_INIT_Configure() {
|
||||
|
||||
PCSPEAKER_SetCounter(pit[pcspeaker_pit].cntr,pit[pcspeaker_pit].mode);
|
||||
PIC_AddEvent(PIT0_Event,pit[0].delay);
|
||||
|
||||
if (IS_PC98_ARCH) {
|
||||
/* BIOS data area at 0x501 tells the DOS application which clock rate to use */
|
||||
phys_writeb(0x501,
|
||||
((PIT_TICK_RATE == PIT_TICK_RATE_PC98_8MHZ) ? 0x80 : 0x00) /* bit 7: 1=8MHz 0=5MHz/10MHz */
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
void TIMER_OnPowerOn(Section*) {
|
||||
@ -617,11 +624,6 @@ void TIMER_OnEnterPC98_Phase2(Section*) {
|
||||
ReadHandler[1].Install(IS_PC98_ARCH ? 0x73 : 0x41,read_latch,IO_MB);
|
||||
ReadHandler[2].Install(IS_PC98_ARCH ? 0x75 : 0x42,read_latch,IO_MB);
|
||||
|
||||
/* BIOS data area at 0x501 tells the DOS application which clock rate to use */
|
||||
phys_writeb(0x501,
|
||||
((PIT_TICK_RATE == PIT_TICK_RATE_PC98_8MHZ) ? 0x80 : 0x00) /* bit 7: 1=8MHz 0=5MHz/10MHz */
|
||||
);
|
||||
|
||||
latched_timerstatus_locked=false;
|
||||
gate2 = false;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user