Received: by 10.192.165.148 with SMTP id m20csp720269imm; Fri, 4 May 2018 05:29:07 -0700 (PDT) X-Google-Smtp-Source: AB8JxZptcFEcFcf0i68RWzWOM45TPJuJe6d/8Xjst2SzHsr7H8rkgKd2Z/Bz95oVzl/+yzqK9JIb X-Received: by 2002:a65:5509:: with SMTP id f9-v6mr22479146pgr.317.1525436947366; Fri, 04 May 2018 05:29:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525436947; cv=none; d=google.com; s=arc-20160816; b=HxgIEFwMwIvqZvTjSf1OCbPBYedxc8LG77tGtcZs5DWjOAyRdm1teWqT4Ni1nPRbgq rFj45YLh1Dq/v1wG9mteNuAmxQ2XAw9pQmTW7kXnxl2mTZCfLlGbKxsOd+mZ3v7tqX4P WMOCe8rrzLVrieU5B/xIgVjtvxvIO7nqJsrzrybgjilIGK0BAt58B69/MaXFn70zw+SN Q8ItIurF0FSmn47pmroZxWKnsc2XjELIzJ1kfivxNELbz8exf9FItqFtdyjrFkS2M8AD P0YNYdGz4IJxlMMkgpkype/N0hBGzCIiJuciReO9JNeNTzAAWDILSJZa0cFHe0/tE7bs /X1g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:references:in-reply-to:mime-version :dkim-signature:arc-authentication-results; bh=RPZXVPzFHN7x7PnLkAx0PM5gqglE+lp2tKr1a8CmyxU=; b=sQnqbgZEFjirU614qQFaoJtIW/fAPxdl1W/haMfSu8wPKTh4JqikLIaZ8kHDSk3FA4 1Q1u3aVhVIn7gQ1y90QzucoYEBNfqPd1RXOINXIrLg2O7zT3fwF/J56L+TLz0HkF5jmg zmxXhMB2Yg6eXyvrpgecWgwOii6IEXcJSacVy02O3k2H5GvHaUpBum6n1H/S60N3pow1 R3Fea7+DFoKFo7LcX9DKtr0g868ORKGg9y8Mn7m5XpwPJMZBZXU95IwAKXUQXa1POQT7 AQTKz56gUgqoJQnCRvNlsrZgzdVV7d/bGiz8lZVnabnp7Gzfyr9REIFPJHXzJeLYSrXd kjHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=OyLc2jow; 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z4-v6si12988790pgs.508.2018.05.04.05.28.52; Fri, 04 May 2018 05:29:07 -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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=OyLc2jow; 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751404AbeEDM2d (ORCPT + 99 others); Fri, 4 May 2018 08:28:33 -0400 Received: from mail-oi0-f65.google.com ([209.85.218.65]:42707 "EHLO mail-oi0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751262AbeEDM2b (ORCPT ); Fri, 4 May 2018 08:28:31 -0400 Received: by mail-oi0-f65.google.com with SMTP id t27-v6so18950361oij.9; Fri, 04 May 2018 05:28:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=RPZXVPzFHN7x7PnLkAx0PM5gqglE+lp2tKr1a8CmyxU=; b=OyLc2jowUTxVEcMwSr2SUA2oACBUxmZqpzb9dniBEZxTNRCtUjofRMNG2KD2cuWOhs JDR5P3nAAMWmmZcmKDePcNlGDdRDiS+Aflq5INLh1dNF7uH9LrwL2xDIa35y9Gv6RvRv NJiiPCxeYE1gVaQwMmG+9MdkpDUS0eM9F3Ct/Uv1LkATpJ/E+eAfswrVq+fxjyAXHiNh f+ydRuAGQ6Za3HpxxtaDjLzoI1pwVZq7FHcPjGPHfIFDbcLhbxrb2vcbkfPhbOtQXbIe 3zlem8ZhiKn1z7nfPy/8ORbEgYtXUVv1seKkTdWb2MXGGg39FqCX8Fwp8i2ThvnHaprX Em/A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=RPZXVPzFHN7x7PnLkAx0PM5gqglE+lp2tKr1a8CmyxU=; b=jjn4aa/4CINVFxOCN413fxR5245H/HqBSXa+NOC2RTch9MFdjk4cHFdkPfsa+feRmc OVd+5V5bDGozoekPE54i+kqU0Ve6YMA4F3uC4jQoOwHg8HO72ZHD1kkDjG63lxKSqaSg bWB7qU+LE9M/D7IWv1JzLxmLU0UFgrL+mKijA7cZi7CsewsAGUEvbh0PolHjcGeNJh+E YGxkxrHVIT5F074xK2cLXW+l+MnqowVtThqGvqm+AOVx7UH54wtCXlzBApBN+CXyWx/Q Bev2AOi+xU4aO5HRnYl2LdNwpmN2eP/7D0nsthORbdlhSBhhCGBAA/WCJmYFHf7TzEQT lJFg== X-Gm-Message-State: ALQs6tBLMzAo7N7omDo+ochF3vpVExjGdOQWquuzUH9zleeulNSc2/64 AceqGde+ou6/gaK1/oCtPc1P3DpbjgUJYRnN6wQ= X-Received: by 2002:aca:d9c5:: with SMTP id q188-v6mr3619510oig.233.1525436911099; Fri, 04 May 2018 05:28:31 -0700 (PDT) MIME-Version: 1.0 Received: by 10.74.70.211 with HTTP; Fri, 4 May 2018 05:28:30 -0700 (PDT) In-Reply-To: <1525055900-20729-1-git-send-email-wanpengli@tencent.com> References: <1525055900-20729-1-git-send-email-wanpengli@tencent.com> From: Wanpeng Li Date: Fri, 4 May 2018 20:28:30 +0800 Message-ID: Subject: Re: [PATCH] KVM: X86: Limit timer frequency with more smaller interval To: LKML , kvm Cc: Paolo Bonzini , =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= , Anthoine Bourgeois Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ping, 2018-04-30 10:38 GMT+08:00 Wanpeng Li : > From: Wanpeng Li > > Anthoine reported: > The period used by Windows change over time but it can be 1 milliseconds > or less. I saw the limit_periodic_timer_frequency print so 500 > microseconds is sometimes reached. > > This patchs limits timer frequency with more smaller interval 200ms(5000H= z) > to leave some headroom as Paolo suggested since Windows 10 changed the > scheduler tick limit from 1024 Hz to 2048 Hz. > > Reported-by: Anthoine Bourgeois > Suggested-by: Paolo Bonzini > Cc: Paolo Bonzini > Cc: Radim Kr=C4=8Dm=C3=A1=C5=99 > Cc: Anthoine Bourgeois > Signed-off-by: Wanpeng Li > --- > arch/x86/kvm/x86.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c > index 51ecd38..dc47073 100644 > --- a/arch/x86/kvm/x86.c > +++ b/arch/x86/kvm/x86.c > @@ -114,7 +114,7 @@ module_param(ignore_msrs, bool, S_IRUGO | S_IWUSR); > static bool __read_mostly report_ignored_msrs =3D true; > module_param(report_ignored_msrs, bool, S_IRUGO | S_IWUSR); > > -unsigned int min_timer_period_us =3D 500; > +unsigned int min_timer_period_us =3D 200; > module_param(min_timer_period_us, uint, S_IRUGO | S_IWUSR); > > static bool __read_mostly kvmclock_periodic_sync =3D true; > -- > 2.7.4 >