Received: by 2002:a19:771d:0:0:0:0:0 with SMTP id s29csp1271530lfc; Wed, 1 Jun 2022 13:46:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyua4efrD5BEZTWdvQdp1hlIKM9VWZ4ZtONexljf3JNu4UvVDL9BMy3BG7RECzLQCHEeHAR X-Received: by 2002:a17:90b:4b12:b0:1dc:dfdb:446 with SMTP id lx18-20020a17090b4b1200b001dcdfdb0446mr36047508pjb.150.1654116388575; Wed, 01 Jun 2022 13:46:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654116388; cv=none; d=google.com; s=arc-20160816; b=dpgIgW/IBln8EKKfa+9mAJT5+egD/5Rof852YOHIlTOnA3zAXeV98dso8oz08syxKf k6xKQ4QNJoSk2q7Kb+PHNI4oGgVDrrEoC2lXSTI9HuXZsARO4LmTI+8jOfv/znIt67w3 V21DgWJGBmI+KNVRouGZV3tvG+MFV3MCzmIYtnrYUePT49y37k2rnlaiM8OBkqZe9i0N 4VzXYuSv6w+rShNC/meMhG61MTI1ovbCDOFuT63dfQ9Jos2GdHZ7u3Hxxr1/aogmMcM9 jPEmU7VWCQn2i+nbKr+xHqjR0uHpAb0U/8mBCSpUd9vHan3tT5UTlgCSkCockB0YJB0B csYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=kmPFKn3CfNA6S8ITvZmyqXq/Q8dnPnZS1T5Vpg4XptA=; b=aAYHq9MaXPLdWGEJGjyKR2pHcI0Phr3Xs2xPB0z9LoJ54pfKOZdJtkHuNfdb46TTHD HhJFB502w/hsE4o+GcVKhLZVD0h9AfB9iU2f7efVcFXyabHqYwT3vOZUFIjVyyD5T9j3 WegKtVBXPVfh/aP6gbpLSyJVfESyd1SEPuTBpVdpC+RLqrKu44w7lPYvsmCT8M/SOlLO jj9feig/WVaLJjXfSA6QmDlGoYLfkOwwUkUHtq9+Kwn9N2SGvPjbPpLbCPnHWGu+oUIm 38pILVX2noZAc2Rmm+eNgRQwEA8C7Tq5kIn3UG8rVNwpmYSqbn2Sqhdnsq3tupVBuiBp CBHQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=E08QSsED; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id ng17-20020a17090b1a9100b001df621048f4si10048775pjb.10.2022.06.01.13.46.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jun 2022 13:46:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=E08QSsED; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 28A962AB21F; Wed, 1 Jun 2022 12:55:15 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1352020AbiFAKTv (ORCPT + 99 others); Wed, 1 Jun 2022 06:19:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44242 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243633AbiFAKTt (ORCPT ); Wed, 1 Jun 2022 06:19:49 -0400 Received: from desiato.infradead.org (desiato.infradead.org [IPv6:2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0AFAD6B677; Wed, 1 Jun 2022 03:19:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; 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=kmPFKn3CfNA6S8ITvZmyqXq/Q8dnPnZS1T5Vpg4XptA=; b=E08QSsEDzDXwZxdVkGb/CWF7xQ efHbWb78SvKvZHoGfgBASeiDq2eiD4WCHpcjIM4FMywEwVHPoUX9UK02Kpb3m6GKjRV5TwHFOq7Qa NLi6ISL8StPtArU+wtQGRT/6+M1akpUNg+r0CF29a5nZpULH3kYcWWu4YUZs528GePslagJkbEW6Q 4kHnRWaB77R7h3xQQQEYLb/3Xd+ZKpzJcqiAdAiJ24BI/CNpdwDHFDjS7gGZRPYvTs7A4o3SxnRvi IJWqCLfCW8watu1HENAsz6uXFRanaVgoH4xv+htG+QSV9FxCoNKHHg+066jGLnWV97DUWXFIIoqFN /jueuXgA==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=worktop.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nwLRV-003k8D-Hj; Wed, 01 Jun 2022 10:19:09 +0000 Received: by worktop.programming.kicks-ass.net (Postfix, from userid 1000) id 3319198137D; Wed, 1 Jun 2022 12:19:07 +0200 (CEST) Date: Wed, 1 Jun 2022 12:19:07 +0200 From: Peter Zijlstra To: Paolo Bonzini Cc: Vitaly Kuznetsov , "Durrant, Paul" , "Allister, Jack" , "bp@alien8.de" , "diapop@amazon.co.uk" , "hpa@zytor.com" , "jmattson@google.com" , "joro@8bytes.org" , "kvm@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "metikaya@amazon.co.uk" , "mingo@redhat.com" , "rkrcmar@redhat.com" , "sean.j.christopherson@intel.com" , "tglx@linutronix.de" , "wanpengli@tencent.com" , "x86@kernel.org" Subject: Re: ...\n Message-ID: References: <20220531140236.1435-1-jalliste@amazon.com> <059ab3327ac440479ecfdf49fa054347@EX13D32EUC003.ant.amazon.com> <307f19cc-322e-c900-2894-22bdee1e248a@redhat.com> <87tu94olyd.fsf@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 On Wed, Jun 01, 2022 at 10:59:17AM +0200, Paolo Bonzini wrote: > On 6/1/22 09:57, Vitaly Kuznetsov wrote: > > > > I'll bite... What's ludicrous about wanting to run a guest at a lower CPU freq to minimize observable change in whatever workload it is running? > > > Well, the right API is cpufreq, there's no need to make it a KVM > > > functionality. > > KVM may probably use the cpufreq API to run each vCPU at the desired > > frequency: I don't quite see how this can be done with a VMM today when > > it's not a 1-vCPU-per-1-pCPU setup. > > True, but then there's also a policy issue, in that KVM shouldn't be allowed > to *bump* the frequency if userspace would ordinarily not have access to the > cpufreq files in sysfs. So, when using schedutil (which requires intel_pstate in passive mode), then there's the option to use per-task uclamps which are somewhat complicated but also affect cpufreq.