CVSROOT:        /cvs
Module name:    src
Changes by:     chel...@cvs.openbsd.org 2023/03/08 11:05:05

Modified files:
        sys/arch/amd64/amd64: lapic.c 

Log message:
amd64: lapic_timer_rearm: don't reset mode, mask, divisor

The apic timer mode, mask, and divisor are set during lapic_timer_trigger().
We don't need to reset them when rearming the timer.  On physical hardware
the difference is too small to measure, but skipping two apic writes may be
a bit faster when we're running in a VM.

Bochs also likes to log when the apic divisor is changed:

38569516308i[APIC0 ] set timer divide factor to 1
38569517335i[APIC0 ] set timer divide factor to 1
38569518042i[APIC0 ] set timer divide factor to 1
[...]

With this change, Bochs is a lot less noisy.

Idea from mlarkin@.

ok mlarkin@

Reply via email to