Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp3002415ybv; Mon, 24 Feb 2020 16:09:49 -0800 (PST) X-Google-Smtp-Source: APXvYqzWQfhJzCRDawxVgD6pRroNs/kR3NrpGYnrKgTN2Mmxm69YDEo7KwRuglBka+cM8WE+Dvg9 X-Received: by 2002:a9d:5d07:: with SMTP id b7mr43713136oti.209.1582589389547; Mon, 24 Feb 2020 16:09:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582589389; cv=none; d=google.com; s=arc-20160816; b=IcwtQ0mgRWi9XLSTG1UftHW51orQjT5NifXCVnfw9f6uh4ZJjOrNsVEGb+z0bevlg+ XvelSbCJo0KwrIKBbPwDx3qx1+CceVuY+pe8LrFT5h3q4YrJ20MUP7nJSdZJfqvj7k0i SZ3SIOYBdr95viHnSJ7FAfmz72gBx/9AJBrc6ul2chlQqfo67FsUTmGhKU/X7SaZW5kH c9sXtJ96z1lh10tUJiYHbk4RgFuVSEvy1LY/uXaZsPIz//iOwYVg1FXMjDwZeVe5ZMe4 MaXq1rzMJiaFMKGUKH2N1DrDg2tlyxuFTf4luEk7ojdQ22VqMrCDGT1FkqLrPaHDd2Ra RLFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=yYLHirngUHxt10qFoU9xmupylPxKXSewlxECiHVcCbc=; b=LqQy+2GPThkMGYlnwDxrzvle7rF8qgZ9oLVC4Dfx9eobdvzsiZpBtE+XCjy2Rf4BBs 6/Ld8ttnXxjYjfqkiT8M+TxQuFECuGOLfTZuG0OpMsVFB7Zvkpd47sgqoM5Liawt9Zat 5L/UG3fSZkk5u+Qr0L/B36PDT/kPHSaGn6z81hI+7DQvcOzod1WHpFPWvZXCa41ECL7P pP67iZW45E5NW2hTA83tKFVhrvbn8P3MxdNAbE0tFtTDWupFeBZYy9DbkZqrBypAp9LD pBpukoFpKnoho6zi8+WuZS1gOskaYu8UQTbEwtq2DrzgBuKrq5tsaxwwM/5EMpPMTLo/ wiyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=pdVgPiWK; 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=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x26si7144012otk.325.2020.02.24.16.09.35; Mon, 24 Feb 2020 16:09:49 -0800 (PST) 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; dkim=pass header.i=@google.com header.s=20161025 header.b=pdVgPiWK; 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=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726651AbgBYAIR (ORCPT + 99 others); Mon, 24 Feb 2020 19:08:17 -0500 Received: from mail-io1-f65.google.com ([209.85.166.65]:42154 "EHLO mail-io1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728320AbgBYAIQ (ORCPT ); Mon, 24 Feb 2020 19:08:16 -0500 Received: by mail-io1-f65.google.com with SMTP id z1so1161042iom.9 for ; Mon, 24 Feb 2020 16:08:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=yYLHirngUHxt10qFoU9xmupylPxKXSewlxECiHVcCbc=; b=pdVgPiWKRIZ6FGDifzN+jO7VW4qmMUPDK9hEVvS/Uzl7iTkfQxBqNCYbyruzNjkH3R FUsq75ZEMBVuEZmMvqJlBUHbo+HQ9+bhK97Nb6Qn8c+k8WLWDt6OcSir14JkDnVim3VL dAhGAYEIq3EX7SLhpFZDPFNtOPhCNiVDp+YX66sO+jg2+77959SfeDUcywD9q76Qcb+n SXXL7OVxUHg7VJvpXpLbuUq1cGDk5BnhUbJeWXdWWsyTnXEW2RxfLnY6YvR6kf7QgwMi G9Ug6sDiaWMxQY/sQIweYBoEk6YUqtOHp1K0Y5poF5WyQOhiz1YMlOp3J8K8ilB1XVBP oXZw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=yYLHirngUHxt10qFoU9xmupylPxKXSewlxECiHVcCbc=; b=s4/6H7fm8d2lpDxl0v892+jn6aBpMiedGKNHEe8Kf+kPbelNrq/gFSmBe3j0y3Wmib uTme+bWl0wQXfzXoR5/xxAWyplRBvqadXkKAR74b3G178pl/A58LVljBg6C27t/RfZMv h8JPloxGVUfQoEDU1kOKS8DB7ox8thbRtRD7lLiVHdbqTE+EyKJydl7j1Ii0ec3EbpiE xLQ69E2w8yawCpQGQXfBsaZsG4KcNLZJjEmVy0+Whfn4t727K6f9c0tpMkQNhzrMTFnx LABDgU5iLX9sXXCEYBcv3GxMCPW0looXAnC8UpT+o0UNAQ12P9ZI/t+KCUIcliTI335y erGw== X-Gm-Message-State: APjAAAU2urfibcY9ppLhPjxfdCtWXhTl/MLwyuFhdYatLRrNljGElKuv Hsz+FfO6tIHeQ8sEFUPC0cXHjqNr0xSWutlA/Y9hGg== X-Received: by 2002:a6b:ee01:: with SMTP id i1mr54662261ioh.109.1582589295859; Mon, 24 Feb 2020 16:08:15 -0800 (PST) MIME-Version: 1.0 References: <20200222023413.78202-1-ehankland@google.com> <9adcb973-7b60-71dd-636d-1e451e664c55@redhat.com> <0c66eae3-8983-0632-6d39-fd335620b76a@linux.intel.com> In-Reply-To: <0c66eae3-8983-0632-6d39-fd335620b76a@linux.intel.com> From: Eric Hankland Date: Mon, 24 Feb 2020 16:08:04 -0800 Message-ID: Subject: Re: [PATCH] KVM: x86: Adjust counter sample period after a wrmsr To: Like Xu Cc: Paolo Bonzini , Jim Mattson , Peter Shier , linux-kernel@vger.kernel.org, kvm@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Like - Thanks for the feedback - is your recommendation to do the read and period change at the same time and only take the lock once or is there another way around this while still handling writes correctly? Eric