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 7F733EE7FF6 for ; Fri, 8 Sep 2023 13:24:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243509AbjIHNYU (ORCPT ); Fri, 8 Sep 2023 09:24:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57008 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231295AbjIHNYT (ORCPT ); Fri, 8 Sep 2023 09:24:19 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 683CD19BC; Fri, 8 Sep 2023 06:24:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; 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=B9k4dnbji9dnrByms7YY3LGk13xuTrwM08yQHVzelLI=; b=hR2iVHQlXKi/fwdpa5csKFUJ2M vU1v4kHdiUiHfW+lu2TZOzHRGEVKf3slc98/Wu+YFD3oqRA7Z2XHWqdCtxXMNE532Nr/bkDEo0eT+ eGT8KhdyJkK/8Dx8kYnYco5QYpvcUyswVC1OyLkdzqs0vcfKG2Z3aHWzplkg0GphhVN6maXT5XlEc OUJEYjDq3xbsuxWd39Cc7vNM4UucsSoSy9i/XTMafRtRbIp3ZoediI0dOgN4D11zphRdoHRXTAS/a ftvMj/AXWgXhjYm2jXsZ49FrhnjDrtxabMALqJPYEVqbrGe5Z0NhZxrSxqCyIWB9si+a6h1JH2lT3 JuY1IOQg==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1qebSt-000MEr-6f; Fri, 08 Sep 2023 13:24:03 +0000 Received: by noisy.programming.kicks-ass.net (Postfix, from userid 1000) id 33F96300472; Fri, 8 Sep 2023 15:24:02 +0200 (CEST) Date: Fri, 8 Sep 2023 15:24:02 +0200 From: Peter Zijlstra To: Meng Li Cc: "Rafael J . Wysocki" , Huang Rui , linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, x86@kernel.org, linux-acpi@vger.kernel.org, Shuah Khan , linux-kselftest@vger.kernel.org, Nathan Fontenot , Deepak Sharma , Alex Deucher , Mario Limonciello , Shimmer Huang , Perry Yuan , Xiaojian Du , Viresh Kumar , Borislav Petkov Subject: Re: [PATCH V5 4/7] cpufreq: Add a notification message that the highest perf has changed Message-ID: <20230908132402.GH19320@noisy.programming.kicks-ass.net> References: <20230905015116.2268926-1-li.meng@amd.com> <20230905015116.2268926-5-li.meng@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230905015116.2268926-5-li.meng@amd.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Sep 05, 2023 at 09:51:13AM +0800, Meng Li wrote: > ACPI 6.5 section 8.4.6.1.1.1 specifies that Notify event 0x85 can be > emmitted to cause the the OSPM to re-evaluate the highest performance > register. Add support for this event. > > Signed-off-by: Meng Li > Link: https://uefi.org/specs/ACPI/6.5/08_Processor_Configuration_and_Control.html?highlight=cppc#cpc-continuous-performance-control > --- > drivers/acpi/processor_driver.c | 6 ++++++ > drivers/cpufreq/cpufreq.c | 13 +++++++++++++ > include/linux/cpufreq.h | 5 +++++ > 3 files changed, 24 insertions(+) > > diff --git a/drivers/acpi/processor_driver.c b/drivers/acpi/processor_driver.c > index 4bd16b3f0781..29b2fb68a35d 100644 > --- a/drivers/acpi/processor_driver.c > +++ b/drivers/acpi/processor_driver.c > @@ -27,6 +27,7 @@ > #define ACPI_PROCESSOR_NOTIFY_PERFORMANCE 0x80 > #define ACPI_PROCESSOR_NOTIFY_POWER 0x81 > #define ACPI_PROCESSOR_NOTIFY_THROTTLING 0x82 > +#define ACPI_PROCESSOR_NOTIFY_HIGEST_PERF_CHANGED 0x85 > > MODULE_AUTHOR("Paul Diefenbaugh"); > MODULE_DESCRIPTION("ACPI Processor Driver"); > @@ -83,6 +84,11 @@ static void acpi_processor_notify(acpi_handle handle, u32 event, void *data) > acpi_bus_generate_netlink_event(device->pnp.device_class, > dev_name(&device->dev), event, 0); > break; > + case ACPI_PROCESSOR_NOTIFY_HIGEST_PERF_CHANGED: > + cpufreq_update_highest_perf(pr->id); > + acpi_bus_generate_netlink_event(device->pnp.device_class, > + dev_name(&device->dev), event, 0); > + break; > default: > acpi_handle_debug(handle, "Unsupported event [0x%x]\n", event); > break; I've obviously not read the link, but the above seems to suggest that every CPU that has its limits changed gets the 'interrupt' ?