lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 25 May 2021 18:21:21 +0000
From:   Sean Christopherson <seanjc@...gle.com>
To:     Paolo Bonzini <pbonzini@...hat.com>
Cc:     "Stamatis, Ilias" <ilstam@...zon.com>,
        "mlevitsk@...hat.com" <mlevitsk@...hat.com>,
        "kvm@...r.kernel.org" <kvm@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "jmattson@...gle.com" <jmattson@...gle.com>,
        "Woodhouse, David" <dwmw@...zon.co.uk>,
        "vkuznets@...hat.com" <vkuznets@...hat.com>,
        "joro@...tes.org" <joro@...tes.org>,
        "mtosatti@...hat.com" <mtosatti@...hat.com>,
        "zamsden@...il.com" <zamsden@...il.com>,
        "wanpengli@...cent.com" <wanpengli@...cent.com>
Subject: Re: [PATCH v3 09/12] KVM: VMX: Remove vmx->current_tsc_ratio and
 decache_tsc_multiplier()

On Tue, May 25, 2021, Paolo Bonzini wrote:
> On 25/05/21 18:34, Sean Christopherson wrote:
> > > I actually like the idea of storing the expected value in kvm_vcpu and the
> > > current value in loaded_vmcs.  We might use it for other things such as
> > > reload_vmcs01_apic_access_page perhaps.
> > I'm not necessarily opposed to aggressively shadowing the VMCS, but if we go
> > that route then it should be a standalone series that implements a framework
> > that can be easily extended to arbitrary fields.  Adding fields to loaded_vmcs
> > one at a time will be tedious and error prone.  E.g. what makes TSC_MULTIPLIER
> > more special than TSC_OFFSET, GUEST_IA32_PAT, GUEST_IA32_DEBUGCTL, GUEST_BNDCFGS,
> > and other number of fields that are likely to persist for a given vmcs02?
> 
> That it can be changed via ioctls in a way that affects both vmcs01 and vmcs02.

That holds true for any MSR that is conditionally loaded/cleared on enter/exit,
e.g. userspace can stuff MSR_IA32_CR_PAT while L2 is active, and that can affect
L1 if L1 is running without VM_EXIT_LOAD_IA32_PAT.

I'm not saying that the above is likely, but neither is changing the TSC scaling
ratio while L2 is active (I assume it occurs on migration, but in the grand
scheme that's not a common operation).

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ