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 55E22C433EF for ; Thu, 9 Dec 2021 16:11:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237041AbhLIQPS (ORCPT ); Thu, 9 Dec 2021 11:15:18 -0500 Received: from mga06.intel.com ([134.134.136.31]:40656 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230177AbhLIQPR (ORCPT ); Thu, 9 Dec 2021 11:15:17 -0500 X-IronPort-AV: E=McAfee;i="6200,9189,10193"; a="298924660" X-IronPort-AV: E=Sophos;i="5.88,192,1635231600"; d="scan'208";a="298924660" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Dec 2021 08:04:59 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,192,1635231600"; d="scan'208";a="463291598" Received: from ranerica-svr.sc.intel.com ([172.25.110.23]) by orsmga006.jf.intel.com with ESMTP; 09 Dec 2021 08:04:58 -0800 Date: Thu, 9 Dec 2021 08:03:46 -0800 From: Ricardo Neri To: Daniel Lezcano Cc: "Rafael J. Wysocki" , linux-pm@vger.kernel.org, x86@kernel.org, linux-doc@vger.kernel.org, Len Brown , Srinivas Pandruvada , Aubrey Li , Amit Kucheria , Andi Kleen , Tim Chen , "Ravi V. Shankar" , Ricardo Neri , linux-kernel@vger.kernel.org Subject: Re: [PATCH 6/7] thermal: netlink: Add a new event to notify CPU capabilities change Message-ID: <20211209160346.GA7692@ranerica-svr.sc.intel.com> References: <20211106013312.26698-1-ricardo.neri-calderon@linux.intel.com> <20211106013312.26698-7-ricardo.neri-calderon@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 30, 2021 at 10:29:46AM +0100, Daniel Lezcano wrote: > On 06/11/2021 02:33, Ricardo Neri wrote: > > From: Srinivas Pandruvada > > > > Add a new netlink event to notify change in CPU capabilities in terms of > > performance and efficiency. > > > > Firmware may change CPU capabilities as a result of thermal events in the > > system or to account for changes in the TDP (thermal design power) level. > > > > This notification type will allow user space to avoid running workloads > > on certain CPUs or proactively adjust power limits to avoid future events. > > > > [ ... ] > > > + [THERMAL_GENL_ATTR_CPU_CAPABILITY_ID] = { .type = NLA_U32 }, > > + [THERMAL_GENL_ATTR_CPU_CAPABILITY_PERF] = { .type = NLA_U32 }, > > + [THERMAL_GENL_ATTR_CPU_CAPABILITY_EFF] = { .type = NLA_U32 }, > > }; > > AFAIU, 0 <= perf < 256 and 0 <= eff < 256, right? > > Is the following true? > > 0 <= perf + eff < 256 No, they are not. They are set independently. Thanks and BR, Ricardo