Index | Thread | Search

From:
ssnf <ssnf@ssnf.xyz>
Subject:
[PATCH 0/6] vmd: improve 8254 PIT emulatiom
To:
tech@openbsd.org
Cc:
ssnf <ssnf@ssnf.xyz>
Date:
Sat, 22 Aug 2026 19:02:41 +0000

Download raw body.

Thread
This series of patches fixes several independent correctness
bugs in vmd's 8254 PIT emulation.

Guests that program the PIT according to the hardware interface
expose cases where vmd's emulation differs from the 8254
behavior.

Tested with a 9front guest under -current.

Comments and tests are welcome.

ssnf (6):
  vmd: store i8253 modes in register representation
  vmd: emulate i8253 square-wave counter correctly
  vmd: handle zero i8253 counter value as 65536
  vmd: reset i8253 input latch on new counter writes
  vmd: only assert IRQ0 for i8253 channel 0
  vmd: preserve i8253 counter load timestamp

 usr.sbin/vmd/i8253.c | 25 ++++++++++++++++---------
 usr.sbin/vmd/i8253.h |  2 +-
 2 files changed, 17 insertions(+), 10 deletions(-)

-- 
2.51.0