]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
x86: tsc: deprioritize TSC on VirtualBox
authorKyle Evans <kevans@FreeBSD.org>
Mon, 8 Mar 2021 20:20:10 +0000 (14:20 -0600)
committerKyle Evans <kevans@FreeBSD.org>
Fri, 12 Mar 2021 18:43:43 +0000 (12:43 -0600)
commitec24f78e5b201ea56a69607c6e4438a2faac25c0
tree3648b347e5335c3f33cc38c4773bb036fc53e7e9
parentad259c473dc645725225cfda307323de48c87051
x86: tsc: deprioritize TSC on VirtualBox

Misbehavior has been observed with TSC under VirtualBox, where threads
doing small sleeps (~1 second) may miss their wake up and hang around
in a sleep state indefinitely.  Switching back to ACPI-fast decidedly
fixes it, so stop using TSC on VirtualBox at least for the time being.

This partially reverts 84eaf2ccc6aa, applying it only to VirtualBox and
increasing the quality to 0. Negative qualities can never be chosen and
cannot be chosen with the tunable recently added. If we do not have a
timecounter with a higher quality than 0, then TSC does at least leave
the system mostly usable.

PR: 253087

(cherry picked from commit 8cc15b0dfc2f3299662e78f18bd6127f83c14ab4)
sys/x86/x86/tsc.c