public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: "Liang, Kan" <kan.liang@intel.com>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"kvm@vger.kernel.org" <kvm@vger.kernel.org>,
	"Kleen, Andi" <andi.kleen@intel.com>
Subject: Re: [PATCH 1/2] perf: ignore LBR and offcore_rsp.
Date: Wed, 18 Jun 2014 17:59:16 +0200	[thread overview]
Message-ID: <20140618155916.GZ6758@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <37D7C6CF3E00A74B8858931C1DB2F0770148F513@SHSMSX103.ccr.corp.intel.com>

[-- Attachment #1: Type: text/plain, Size: 1213 bytes --]

On Wed, Jun 18, 2014 at 03:52:55PM +0000, Liang, Kan wrote:
>     perf ignore LBR and offcore_rsp.
> 
>     x86, perf: Protect LBR and offcore rsp against KVM lying
> 
>     With -cpu host, KVM reports LBR and offcore support, if the host has support.
>     When the guest perf driver tries to access LBR or offcore_rsp MSR,
>     it #GPs all MSR accesses,since KVM doesn't handle LBR and offcore support.
>     So LBR and offcore rsp MSRs are needed to be protected by _safe().
> 
>     For reproducing the issue, please build the kernel with CONFIG_KVM_INTEL = y.
>     And CONFIG_PARAVIRT = n and CONFIG_KVM_GUEST = n.
>     Start the guest with -cpu host.
>     Run perf record with --branch-any or --branch-filter in guest to trigger LBR #GP.
>     Run perf stat offcore events (E.g. LLC-loads/LLC-load-misses ...) in guest to trigger offcore_rsp #GP
> 
>     Signed-off-by: Andi Kleen <ak@linux.intel.com>

This order indicates Andi is the author; but there's no corresponding
From.

>     Signed-off-by: Kan Liang <kan.liang@intel.com>

And here I thought that Andi was of the opinion that if you set CPUID to
indicate a particular CPU you had better also handle all its MSRs.



[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

       reply	other threads:[~2014-06-18 15:59 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <37D7C6CF3E00A74B8858931C1DB2F0770148F513@SHSMSX103.ccr.corp.intel.com>
2014-06-18 15:59 ` Peter Zijlstra [this message]
2014-06-18 16:04   ` [PATCH 1/2] perf: ignore LBR and offcore_rsp Andi Kleen
2014-06-19 17:52     ` Andi Kleen
2014-06-23  9:19       ` Peter Zijlstra
2014-06-23  9:29 ` Peter Zijlstra
2014-06-23 15:56   ` Andi Kleen

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=20140618155916.GZ6758@twins.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=andi.kleen@intel.com \
    --cc=kan.liang@intel.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox