[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20220225145304.36166-1-dwmw2@infradead.org>
Date: Fri, 25 Feb 2022 14:53:01 +0000
From: David Woodhouse <dwmw2@...radead.org>
To: kvm@...r.kernel.org, Paolo Bonzini <pbonzini@...hat.com>,
Sean Christopherson <seanjc@...gle.com>
Cc: Vitaly Kuznetsov <vkuznets@...hat.com>,
Wanpeng Li <wanpengli@...cent.com>,
Jim Mattson <jmattson@...gle.com>,
Joerg Roedel <joro@...tes.org>, linux-kernel@...r.kernel.org,
Suleiman Souhlal <suleiman@...gle.com>,
Anton Romanov <romanton@...gle.com>
Subject: [PATCH 0/3] KVM: Reduce TSC scaling race condition mess
As Sean says, we punt on a proper fix... but at least now I can create a
bunch of vCPUs with a scaled TSC and their TSC synchronization isn't
*utterly* hosed, so the test case I posted last night is actually passing.
It would still be nice for the original test case to work, where each
vCPU thread creates its own vCPU, then sets the scale and the current
TSC value. But this resolves most sane use cases.
David Woodhouse (2):
KVM: x86: Accept KVM_[GS]ET_TSC_KHZ as a VM ioctl.
KVM: x86: Test case for TSC scaling and offset sync
Sean Christopherson (1):
KVM: x86: Don't snapshot "max" TSC if host TSC is constant
Documentation/virt/kvm/api.rst | 11 +++--
arch/x86/include/asm/kvm_host.h | 2 +
arch/x86/kvm/x86.c | 54 ++++++++++++++++------
include/uapi/linux/kvm.h | 4 +-
tools/testing/selftests/kvm/Makefile | 1 +
tools/testing/selftests/kvm/x86_64/tsc_scaling_sync.c | 119 ++++++++++++++++++++++++++++++++++++++++++++++++
6 files changed, 171 insertions(+), 20 deletions(-)
Powered by blists - more mailing lists