All of lore.kernel.org
 help / color / mirror / Atom feed
From: Borislav Petkov <bp@alien8.de>
To: "Radim Krčmář" <rkrcmar@redhat.com>
Cc: linux-kernel@vger.kernel.org, kvm@vger.kernel.org,
	Paolo Bonzini <pbonzini@redhat.com>,
	Alexander Graf <agraf@suse.de>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	"Gabriel L. Somlo" <gsomlo@gmail.com>
Subject: Re: [PATCH 1/4] KVM: svm: prevent MWAIT in guest with erratum 400
Date: Thu, 4 May 2017 18:45:09 +0200	[thread overview]
Message-ID: <20170504164509.uggp7ff335hnm2zt@pd.tnic> (raw)
In-Reply-To: <20170504140243.GA26642@potion>

On Thu, May 04, 2017 at 04:02:44PM +0200, Radim Krčmář wrote:
> X86_BUG_AMD_APIC_C1E doesn't cover C3, which is why I used
> X86_BUG_AMD_E400.

Practically, the CPUs which even support C3 with E400 are single-core
devices and C3 support was removed with revision C3 (yap, the same as
the ACPI state) so I think we can safely ignore C3 here.

I mean, otherwise, we would be seeing E400 in action as our workaround
would not be sufficient. And even then, I don't think we ever go into C3
on those machines as we do HLT which enters C1.

> The host uses APIC timer when entering a guest and I assumed that MWAIT
> can change C states, but it seems that affected AMD models do not even
> support MWAIT hints and the package is in C0 the whole time.

Right, we never do MWAIT when idle on AMD but HLT.

I notice now that MWAIT text has received recent additions talking
about C-state hints but we'd need to evaluate that first and how power
consumption behaves and it probably would work the same way as it does
on Intel.

Thanks.

-- 
Regards/Gruss,
    Boris.

Good mailing practices for 400: avoid top-posting and trim the reply.

  reply	other threads:[~2017-05-04 16:45 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-03 19:37 [PATCH 0/4] KVM: x86: kvm_mwait_in_guest() cleanup and fixes Radim Krčmář
2017-05-03 19:37 ` [PATCH 1/4] KVM: svm: prevent MWAIT in guest with erratum 400 Radim Krčmář
2017-05-03 20:11   ` Borislav Petkov
2017-05-04 14:02     ` Radim Krčmář
2017-05-04 16:45       ` Borislav Petkov [this message]
2017-05-03 19:37 ` [PATCH 2/4] KVM: x86: prevent MWAIT in guest with buggy MONITOR Radim Krčmář
2017-05-03 19:37 ` [PATCH 3/4] KVM: x86: drop bogus MWAIT check Radim Krčmář
2017-05-04 10:58   ` Paolo Bonzini
2017-05-04 14:33     ` Radim Krčmář
2017-05-04 18:29       ` Michael S. Tsirkin
2017-05-04 20:03         ` Radim Krčmář
2017-05-04 18:26     ` Michael S. Tsirkin
2017-05-03 19:37 ` [PATCH 4/4] KVM: x86: simplify kvm_mwait_in_guest() Radim Krčmář
2017-05-03 19:45 ` [PATCH 0/4] KVM: x86: kvm_mwait_in_guest() cleanup and fixes Alexander Graf
2017-05-04 17:56 ` Gabriel L. Somlo
2017-05-04 18:07   ` Radim Krčmář
2017-05-05 13:02     ` Gabriel L. Somlo
2017-05-06 16:48     ` Gabriel L. Somlo
2017-05-08  7:23       ` Paolo Bonzini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170504164509.uggp7ff335hnm2zt@pd.tnic \
    --to=bp@alien8.de \
    --cc=agraf@suse.de \
    --cc=gsomlo@gmail.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=rkrcmar@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.