Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp940796imm; Fri, 8 Jun 2018 07:35:47 -0700 (PDT) X-Google-Smtp-Source: ADUXVKJslkbcVAgDowyNuGrC9tXz26p8eEamUnLWNb1a4xwynT0dRzuacTU/XyECBZ/EU5kv5zdi X-Received: by 2002:a17:902:be0b:: with SMTP id r11-v6mr7039405pls.182.1528468547870; Fri, 08 Jun 2018 07:35:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528468547; cv=none; d=google.com; s=arc-20160816; b=Wm454A2BTMBmWdB0pmsvSz52YjI2yG65R1xpANz4jYuqVUwkorFBwmdzK+qASmqjlB kh2wwElAKt7R/4PwiETy/HCyUjXV33A/Q/lzuXkXRrtLIpONDRi0eqWEykppActeTVHy iUZRipxi4Hcgbu45aRAq6gyBdPE4zWUiy/enkxMKTSwrg8LsavsLKeaoauGzuL+7YPiK JLjJ4k+1PVLckiTKOPFIVh9b0R4OseQyCELMSSCIdJ+Mfufer5ufe9/5zBf2jc2ZMZhq CKVamqv78KKV3MpFgHaC3YnnRbeGILUdSzqtBzw4oG7YwJ2NJ/m84/X5jyjLUSIQx7y9 6LXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from :arc-authentication-results; bh=4oCc2F74g8F25mhyvGGO1fHFKn3dfHzybH3PrUDd/V0=; b=XBbLUNhiWbAQh8TKWJo5GG+UCosd0jHo1qM9FC1yDnaLQJ/J/OUt49+RuLRVCvjb5j PAYkrmhCeDowx4qpJBI930enJ2KL0p3Qf1AYl9VhnhQkGHct71S5QukqXslHaVfkfCAO b+oPg5pffnnyn8YYyQCH+k7HRyblddxVr0iZrfxMRCU/hsQommSdVPK7e0TIzJ0odud4 WnbwaiworfcCbAwc8HrhSdtmeScbyNhchqmK15kR5D95/jcVN1Ebhz0qIDEhBtMkmzl2 rTJM/X1C4/xr3vWmyk5CtsQwS/77SSN2dlE8fiXoVouVPtJemiqtu/9lL3OY6Ik9/M9i XMyQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 31-v6si56509126plz.364.2018.06.08.07.35.33; Fri, 08 Jun 2018 07:35:47 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752869AbeFHOfC convert rfc822-to-8bit (ORCPT + 99 others); Fri, 8 Jun 2018 10:35:02 -0400 Received: from mga09.intel.com ([134.134.136.24]:35578 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752676AbeFHOe6 (ORCPT ); Fri, 8 Jun 2018 10:34:58 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 08 Jun 2018 07:34:58 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,490,1520924400"; d="scan'208";a="55793091" Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by FMSMGA003.fm.intel.com with ESMTP; 08 Jun 2018 07:34:57 -0700 Received: from fmsmsx157.amr.corp.intel.com (10.18.116.73) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.319.2; Fri, 8 Jun 2018 07:34:57 -0700 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by FMSMSX157.amr.corp.intel.com (10.18.116.73) with Microsoft SMTP Server (TLS) id 14.3.319.2; Fri, 8 Jun 2018 07:34:57 -0700 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.82]) by SHSMSX103.ccr.corp.intel.com ([169.254.4.51]) with mapi id 14.03.0319.002; Fri, 8 Jun 2018 22:34:53 +0800 From: "Kang, Luwei" To: Alexander Shishkin CC: "kvm@vger.kernel.org" , "tglx@linutronix.de" , "mingo@redhat.com" , "hpa@zytor.com" , "x86@kernel.org" , "chao.p.peng@linux.intel.com" , "thomas.lendacky@amd.com" , "bp@suse.de" , "Liang, Kan" , "Janakarajan.Natarajan@amd.com" , "dwmw@amazon.co.uk" , "linux-kernel@vger.kernel.org" , "peterz@infradead.org" , "mathieu.poirier@linaro.org" , "kstewart@linuxfoundation.org" , "gregkh@linuxfoundation.org" , "pbonzini@redhat.com" , "rkrcmar@redhat.com" , "david@redhat.com" , "bsd@redhat.com" , "yu.c.zhang@linux.intel.com" , "joro@8bytes.org" Subject: RE: [PATCH v9 04/12] perf/x86/intel/pt: add new capability for Intel PT Thread-Topic: [PATCH v9 04/12] perf/x86/intel/pt: add new capability for Intel PT Thread-Index: AQHT8Xi9oYPMthILhkSzx/04cBEj8qRUYT6AgAIliWA= Date: Fri, 8 Jun 2018 14:34:53 +0000 Message-ID: <82D7661F83C1A047AF7DC287873BF1E167FF006E@SHSMSX101.ccr.corp.intel.com> References: <1526964735-16566-1-git-send-email-luwei.kang@intel.com> <1526964735-16566-5-git-send-email-luwei.kang@intel.com> <20180607134051.rwu5pqtz45cgq7ve@um.fi.intel.com> In-Reply-To: <20180607134051.rwu5pqtz45cgq7ve@um.fi.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > > CPUID(EAX=14H,ECX=0):EBX[bit 3] = 1 indicates support of output to > > Trace Transport subsystem. > > MSR IA32_RTIT_CTL.FabricEn[bit 6] is reserved if CPUID.(EAX=14H, > > ECX=0):ECX[bit 3] = 0. > > This should instead say: > > This adds support for "output to Trace Transport subsystem" capability of > Intel PT, as documented in IA SDM Chapter 36.x.y.z. It means that PT can > output its trace to an MMIO address range rather than system memory > buffer. Yes, you are right. In KVM point of view this bit use for MSR access security check. KVM will track MSRs access in guest, an #GP will be injected to guest if guest try to write IA32_RTIT_CTL.FabricEn[bit 6] when "output_subsys" (CPUID.(EAX=14H, ECX=0):ECX[bit 3] = 0) is not supported. Thanks, Luwei Kang > > > This is use for emulate IA32_RTIT_CTL MSR read/write in KVM. KVM guest > > write IA32_RTIT_CTL will trap to root mode and a #GP would be injected > > to guest if set IA32_RTIT_CTL.FabricEn with CPUID.(EAX=14H, > > ECX=0):ECX[bit 3] = 0. > > I'm not sure what this means, this patch has nothing to do with KVM as far as > I can tell. > > Aside from the commit message, this is a valid patch. > > Thanks, > -- > Alex