From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andi Kleen Subject: Re: [PATCH 1/2] perf: ignore LBR and offcore_rsp. Date: Thu, 19 Jun 2014 10:52:52 -0700 Message-ID: <87ha3g947f.fsf@tassilo.jf.intel.com> References: <37D7C6CF3E00A74B8858931C1DB2F0770148F513@SHSMSX103.ccr.corp.intel.com> <20140618155916.GZ6758@twins.programming.kicks-ass.net> <87lhsu8arx.fsf@tassilo.jf.intel.com> Mime-Version: 1.0 Content-Type: text/plain Cc: "Liang\, Kan" , "linux-kernel\@vger.kernel.org" , "kvm\@vger.kernel.org" , "Kleen\, Andi" To: Peter Zijlstra 5A Return-path: In-Reply-To: <87lhsu8arx.fsf@tassilo.jf.intel.com> (Andi Kleen's message of "Wed, 18 Jun 2014 09:04:02 -0700") Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org Andi Kleen writes: >> >>> Signed-off-by: Kan Liang >> >> 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. > > Yes, philosophically that would be the right way, > but we needed a short term fix to stop things from crashing, and that > was the simplest. I should add there is another reason for this patch now, and doing it in perf instead of somewhere else (this should probably go into the description). With PT on enabling LBR can #GP. So perf needs to handle this case without crashing. This can happen independently of any hypervisors. -Andi -- ak@linux.intel.com -- Speaking for myself only