Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp3412176ybk; Tue, 19 May 2020 04:08:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwm7YlKV6Xpu5bXlpool4oc0ymG4M8xWYe5DdkL8zZKYHaEV71gndpVwfmVdZ5a7AY+iCIb X-Received: by 2002:a17:906:2b4f:: with SMTP id b15mr19290803ejg.64.1589886500442; Tue, 19 May 2020 04:08:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589886500; cv=none; d=google.com; s=arc-20160816; b=U/9hD4wBPedl+LWUWmKfjv0z7t6116bvypfsP2vipa/Tr1GJErPErKSJ85U8I5Kez8 u7eqscuKP69wiuPzCQGCNjQt1G+GUBJPnidH0mgAcUmXPcnnzah9jEpJQow05DnKih0W DLlmnhzwzfpaYPNHiwOT7BYUAv6Gkbczwo2z+SmmCueM5CHA6/aQQdrSOfg0YmvYL9fp 5wuqueFqmu3kk0UbLnDdCADUeH7h8EsBbQq9VodMoxnM9kX5JcHDLrJBhtPX64nKz5Ob 5LvYV7ctARZkPmLVn3P6aj79gWFnCpo6safXh5qWKhM7uZOlXE2feWWtrtBISl5wGh1r rRhQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=J9d+m4V5triwaXNGvm5EH9MRoAlSjk0m+9i2L2q2oJk=; b=wKXc/OJb7q8jS3Cs4dbCHd3rO7E3FcQIzltsiyE/Yv+8rpkcrugTKQFxS5p44sLOlv 35oKumHjwKxGI+pc9CoWPFLxleadQlaMPmHCRFzBkGQZjwONomhnRHFpBTTA6T42oCPg 2Bwkkx9hBozq4nN+QhJb8jZRPDoHYozmuMrFdBhyxTVEj+AQezGOh7D+u1phU3nqRnwx xOs4/a/8ngWVMVwL7Xi5mjUfRrNRyr8oKgG0fsNotEsqrzbyr/E8N4vUFHaxcpiw+3wA SXOQ/z1YaWimFD1o8dFIZE3ennAhOwP4++vmrzkLP2h5+giO9T6CcNRZafNOL0VHHv5T LUqQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b=Bs+G7VX1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t10si7598946edw.408.2020.05.19.04.07.55; Tue, 19 May 2020 04:08:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b=Bs+G7VX1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728694AbgESLGN (ORCPT + 99 others); Tue, 19 May 2020 07:06:13 -0400 Received: from merlin.infradead.org ([205.233.59.134]:32846 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726121AbgESLGM (ORCPT ); Tue, 19 May 2020 07:06:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=J9d+m4V5triwaXNGvm5EH9MRoAlSjk0m+9i2L2q2oJk=; b=Bs+G7VX1wRWj6afTmpcUxLpoi/ JBtUsQIVq//6O+iZjieaPDTS8aED+dpeTxPG84OFimXYcb9AN9hznGDEmnHTPRi+84ZGUI3pirhvh FN8sIWI5Z2HJaLgK7CQQZBLk4A74x23YufEi4WMRfTQ2Jj76ITvKKQM6U7YqQuESPBOIXZLBpCshl hRX2Ypjw49xHp2pscgjpc9fMgSyn6pb2EZGEuhFssdW3K+EsjrCUQ36cwiGvKAPjBCDu+94uIe1hs BeuY86keLJwVRZ99VXfDU/xWc9XEqLAMqPz4bV4GWwPXQC6MS6Lvbatqzi7AHanP8WyGTu1UmoP3U 5vxLEsWw==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by merlin.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1jb02O-0005ff-Pv; Tue, 19 May 2020 11:03:56 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 3A547304A59; Tue, 19 May 2020 13:03:55 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 25A7220BE636B; Tue, 19 May 2020 13:03:55 +0200 (CEST) Date: Tue, 19 May 2020 13:03:55 +0200 From: Peter Zijlstra To: Like Xu Cc: Paolo Bonzini , linux-kernel@vger.kernel.org, kvm@vger.kernel.org, Sean Christopherson , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Joerg Roedel , Thomas Gleixner , ak@linux.intel.com, wei.w.wang@intel.com Subject: Re: [PATCH v11 08/11] KVM: x86/pmu: Emulate LBR feature via guest LBR event Message-ID: <20200519110355.GI279861@hirez.programming.kicks-ass.net> References: <20200514083054.62538-1-like.xu@linux.intel.com> <20200514083054.62538-9-like.xu@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200514083054.62538-9-like.xu@linux.intel.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 14, 2020 at 04:30:51PM +0800, Like Xu wrote: > @@ -6698,6 +6698,7 @@ static fastpath_t vmx_vcpu_run(struct kvm_vcpu *vcpu) > > if (vcpu_to_pmu(vcpu)->version) > atomic_switch_perf_msrs(vmx); > + > atomic_switch_umwait_control_msr(vmx); > > if (enable_preemption_timer) Is this where the test to see if any of the KVM events went into ERROR state should go? if (event->state == PERF_EVENT_STATE_ERROR) { pr_warn("unhappy, someone stole our counter\n"); } like..