Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp22156222rwd; Fri, 30 Jun 2023 04:47:52 -0700 (PDT) X-Google-Smtp-Source: APBJJlHbvaCK3Vzge77ArlhunibkMe/9fOu6M2OWAblLyvd2ObDqc3+Vh/mMGZjsAPKD/y1AT6zC X-Received: by 2002:a17:902:e9c5:b0:1b8:4c8e:1885 with SMTP id 5-20020a170902e9c500b001b84c8e1885mr1453855plk.7.1688125671631; Fri, 30 Jun 2023 04:47:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688125671; cv=none; d=google.com; s=arc-20160816; b=X3Z1Vd0kO5ZfB8m81edj4e8ptdLtyo4cld/9JFLOOc2FyHOc9JfAGqUS9b//lvPUFX xgN49CsmDDIFdItGpHPHOtk2Ju2Uv3rMuKXMTxyJ0Mo4wHtHKadaqFEE6tExrC1kKRg/ cVQ+RWq7Jwf1lFwOS5+zLbABVY5eqojTriNLraiBJFxN1+KTExoYRtg62SPwNcy/f5mv 2WNX3isfP6ZUzOLi4+iuPN2Bbv8qUQsnUgszIuzGqPhhVn+5glYMMro6ujbH0zLNEk5t mOAnoxkGFDx5gK+1CSavElaIOYn5fX16D2qFZvYaidilXjHM2E8wcYVTPDw6cqXRv5Ds wBAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :content-disposition:mime-version:references:mail-followup-to :message-id:subject:cc:to:from:date:dkim-signature; bh=8cpjf6GE4jcBZi2vpLdkrsyTBdFR+rxBFev0vt96Y5w=; fh=peT54FrC4qKHdCE+rrk6gg49+AEzUcDZpO05/oPYj3o=; b=cFMB3qkz1mZvGCie9ukHrdy0PtU8+QQlGWcHI+xUFE+rH/xRiL0L+dneSou01+viEJ h9/stMsmWiseki2uIQcegSmr9OE6LGx7+cv4c4kkqtznb/nl5j1O/eTyY8Wcl19bl5Yc QQOREuq+byfm9r7mJOiZrF/mSenWnrz0ZPBnWuDm8MYXvUzAqowHIlrr6Z/hax/ZCQY5 0J8GVWTsMQfJbQotSlYJOZBUsFEALtieQTCdL/qR7vbyUqeli/ZgOtQWQSn4IYuXKSiP W8EqcZ9koJ6dGbR/Myc5Qf454cY2Rq4p1UMIe4uZuNEBsLIzFWZSQxCv3L8LwLV6762q qn1Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.de header.s=amazon201209 header.b=OpxeFIta; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id b21-20020a170902d89500b0019e57f5a5aesi12274086plz.567.2023.06.30.04.47.36; Fri, 30 Jun 2023 04:47:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@amazon.de header.s=amazon201209 header.b=OpxeFIta; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232559AbjF3LPH (ORCPT + 99 others); Fri, 30 Jun 2023 07:15:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56932 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232937AbjF3LOj (ORCPT ); Fri, 30 Jun 2023 07:14:39 -0400 Received: from smtp-fw-80006.amazon.com (smtp-fw-80006.amazon.com [99.78.197.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C77DC3AA4; Fri, 30 Jun 2023 04:14:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.de; i=@amazon.de; q=dns/txt; s=amazon201209; t=1688123679; x=1719659679; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to:content-transfer-encoding; bh=8cpjf6GE4jcBZi2vpLdkrsyTBdFR+rxBFev0vt96Y5w=; b=OpxeFItaRJZ5P8ayvIFM/yfeCg4MiCnCAxJIhgEJbf1h1hzbb4C0h/4M xR0rO7lBktfHv7mte+Xq5NkMvfPwPPrHYzjWhUUsXAMPuY5Z8YiekkTxV aag5ljLg+q6FvU9gKyEfUa0oq5qyhLrtcqWXOtVO7WaOexPdmgVY6QjKz I=; X-IronPort-AV: E=Sophos;i="6.01,170,1684800000"; d="scan'208";a="223779500" Received: from pdx4-co-svc-p1-lb2-vlan2.amazon.com (HELO email-inbound-relay-iad-1a-m6i4x-366646a6.us-east-1.amazon.com) ([10.25.36.210]) by smtp-border-fw-80006.pdx80.corp.amazon.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 Jun 2023 11:14:35 +0000 Received: from EX19D009EUA003.ant.amazon.com (iad12-ws-svc-p26-lb9-vlan2.iad.amazon.com [10.40.163.34]) by email-inbound-relay-iad-1a-m6i4x-366646a6.us-east-1.amazon.com (Postfix) with ESMTPS id 524F2A2FB4; Fri, 30 Jun 2023 11:14:29 +0000 (UTC) Received: from EX19D033EUC004.ant.amazon.com (10.252.61.133) by EX19D009EUA003.ant.amazon.com (10.252.50.105) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.30; Fri, 30 Jun 2023 11:14:28 +0000 Received: from u40bc5e070a0153.ant.amazon.com (10.1.212.14) by EX19D033EUC004.ant.amazon.com (10.252.61.133) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.30; Fri, 30 Jun 2023 11:14:24 +0000 Date: Fri, 30 Jun 2023 13:14:18 +0200 From: Roman Kagan To: Sean Christopherson CC: Jim Mattson , Paolo Bonzini , Eric Hankland , , Dave Hansen , Like Xu , , Thomas Gleixner , , "H. Peter Anvin" , "Borislav Petkov" , Ingo Molnar , Mingwei Zhang Subject: Re: [PATCH] KVM: x86: vPMU: truncate counter value to allowed width Message-ID: Mail-Followup-To: Roman Kagan , Sean Christopherson , Jim Mattson , Paolo Bonzini , Eric Hankland , kvm@vger.kernel.org, Dave Hansen , Like Xu , x86@kernel.org, Thomas Gleixner , linux-kernel@vger.kernel.org, "H. Peter Anvin" , Borislav Petkov , Ingo Molnar , Mingwei Zhang References: <20230504120042.785651-1-rkagan@amazon.de> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline In-Reply-To: X-Originating-IP: [10.1.212.14] X-ClientProxiedBy: EX19D036UWB003.ant.amazon.com (10.13.139.172) To EX19D033EUC004.ant.amazon.com (10.252.61.133) Content-Transfer-Encoding: base64 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE, T_SPF_PERMERROR autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org T24gVGh1LCBKdW4gMjksIDIwMjMgYXQgMDU6MTE6MDZQTSAtMDcwMCwgU2VhbiBDaHJpc3RvcGhl cnNvbiB3cm90ZToKPiArTWluZ3dlaQo+IAo+IE9uIFRodSwgSnVuIDI5LCAyMDIzLCBKaW0gTWF0 dHNvbiB3cm90ZToKPiA+IE9uIE1vbiwgSnVuIDU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WM1OGE4Ny4uMThhNjU4YWEyYThkIDEwMDY0NAo+IC0t LSBhL2FyY2gveDg2L2t2bS92bXgvcG11X2ludGVsLmMKPiArKysgYi9hcmNoL3g4Ni9rdm0vdm14 L3BtdV9pbnRlbC5jCj4gQEAgLTQwNiwxMSArNDA2LDExIEBAIHN0YXRpYyBpbnQgaW50ZWxfcG11 X3NldF9tc3Ioc3RydWN0IGt2bV92Y3B1ICp2Y3B1LCBzdHJ1Y3QgbXNyX2RhdGEgKm1zcl9pbmZv KQo+ICAgICAgICAgICAgICAgICAgICAgICAgIGlmICghbXNyX2luZm8tPmhvc3RfaW5pdGlhdGVk ICYmCj4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICEobXNyICYgTVNSX1BNQ19GVUxMX1dJ RFRIX0JJVCkpCj4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhID0gKHM2NCko czMyKWRhdGE7Cj4gLSAgICAgICAgICAgICAgICAgICAgICAgcG1jLT5jb3VudGVyICs9IGRhdGEg LSBwbWNfcmVhZF9jb3VudGVyKHBtYyk7Cj4gKyAgICAgICAgICAgICAgICAgICAgICAgcG1jX3dy aXRlX2NvdW50ZXIocG1jLCBkYXRhKTsKPiAgICAgICAgICAgICAgICAgICAgICAgICBwbWNfdXBk YXRlX3NhbXBsZV9wZXJpb2QocG1jKTsKPiAgICAgICAgICAgICAgICAgICAgICAgICBicmVhazsK PiAgICAgICAgICAgICAgICAgfSBlbHNlIGlmICgocG1jID0gZ2V0X2ZpeGVkX3BtYyhwbXUsIG1z cikpKSB7Cj4gLSAgICAgICAgICAgICAgICAgICAgICAgcG1jLT5jb3VudGVyICs9IGRhdGEgLSBw bWNfcmVhZF9jb3VudGVyKHBtYyk7Cj4gKyAgICAgICAgICAgICAgICAgICAgICAgcG1jX3dyaXRl X2NvdW50ZXIocG1jLCBkYXRhKTsKPiAgICAgICAgICAgICAgICAgICAgICAgICBwbWNfdXBkYXRl X3NhbXBsZV9wZXJpb2QocG1jK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