From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C6E53C001DF for ; Mon, 31 Jul 2023 22:03:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230204AbjGaWDL (ORCPT ); Mon, 31 Jul 2023 18:03:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38666 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231822AbjGaWDA (ORCPT ); Mon, 31 Jul 2023 18:03:00 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1E0E7139; Mon, 31 Jul 2023 15:02:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: Content-Type:In-Reply-To:From:References:Cc:To:Subject:MIME-Version:Date: Message-ID:Sender:Reply-To:Content-ID:Content-Description; bh=gHoaM7eGFNI0KBp/0qw5JaxvSgb4EPXM7prcdF6Gpvo=; b=YOow06njeJ2olbzkCBKb8IZ9Nj jVqID3WRMSIwJ/moJkKieCB6dlOM6c18c0/E525uSPWKhKvDBfNhl9+sz1rfHT7CU0mSzimPsTbJD SK2jmsLU3kM/+Y+W+yFl5k69zuubZRgknxIPJtf1rGYYqD6UM5g0DcZNixGYffLkNEyZaZHbpNAYz mnxoMRdRuuxhHWWwK+QcuIELp00rYFGkNBppcswr9d0vcIkKFOXZRwth+afyxMBZQ4ZhStUOUIrfh vJLv4jqUMgfChpAkgO1/UwuuaC8r5L/k4nORLEkD6rVlDJTDwp5/6ZNJg5U2A4yRLuJa/HKlsXMhI 3TkWjTVw==; Received: from [2601:1c2:980:9ec0::2764] by bombadil.infradead.org with esmtpsa (Exim 4.96 #2 (Red Hat Linux)) id 1qQayW-00HSp6-1h; Mon, 31 Jul 2023 22:02:48 +0000 Message-ID: Date: Mon, 31 Jul 2023 15:02:47 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Subject: Re: [PATCH v3 2/2] cpufreq: add virtual-cpufreq driver Content-Language: en-US To: David Dai , "Rafael J. Wysocki" , Viresh Kumar , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Sudeep Holla , Saravana Kannan Cc: Quentin Perret , Masami Hiramatsu , Will Deacon , Peter Zijlstra , Vincent Guittot , Marc Zyngier , Oliver Upton , Dietmar Eggemann , Pavan Kondeti , Gupta Pankaj , Mel Gorman , kernel-team@android.com, linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org References: <20230731174613.4133167-1-davidai@google.com> <20230731174613.4133167-3-davidai@google.com> From: Randy Dunlap In-Reply-To: <20230731174613.4133167-3-davidai@google.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org On 7/31/23 10:46, David Dai wrote: > diff --git a/drivers/cpufreq/Kconfig b/drivers/cpufreq/Kconfig > index f429b9b37b76..3977ca796747 100644 > --- a/drivers/cpufreq/Kconfig > +++ b/drivers/cpufreq/Kconfig > @@ -217,6 +217,21 @@ config CPUFREQ_DT > > If in doubt, say N. > > +config CPUFREQ_VIRT > + tristate "Virtual cpufreq driver" > + depends on OF > + select PM_OPP > + help The 4 lines above should be indented with one tab (not 8 spaces). > + This adds a virtualized cpufreq driver for guest kernels that > + read/writes to a MMIO region for a virtualized cpufreq device to reads/writes to an MMIO region > + communicate with the host. It sends frequency updates to the host > + which gets used as a hint to schedule vCPU threads and select CPU > + frequency. If a VM does not support a virtualized FIE such as AMUs, > + it updates the frequency scaling factor by polling host CPU frequency > + to enable accurate Per-Entity Load Tracking for tasks running in the guest. > + > + If in doubt, say N. -- ~Randy