Received: by 2002:a05:6358:a55:b0:ec:fcf4:3ecf with SMTP id 21csp4691128rwb; Tue, 17 Jan 2023 04:23:09 -0800 (PST) X-Google-Smtp-Source: AMrXdXsPP256NEgp0zYqj57nnfQ1jADg1EbOJd1xek94p0TBU+8BJxCN1gQ4tqhSJ3UbtJl81aqq X-Received: by 2002:a17:90a:c284:b0:229:4b87:4001 with SMTP id f4-20020a17090ac28400b002294b874001mr2921015pjt.38.1673958189244; Tue, 17 Jan 2023 04:23:09 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1673958189; cv=pass; d=google.com; s=arc-20160816; b=wT2x0IOLtxyxVSZuy+yWa8sQ7/5/KVcGFx1Ctp2R+ROuStF9uKiHBDEidM9tu7wbHn DJHCng2T26W6ddx3ykI1aqOaBRFKiXvJS5h55qYSXYC0RtEQiNIuAWI2oIn22lyvKTgl 9xDWpLIr8BDiB8dvWxEgJr86zdgF1NcvIQdVf4J+D7XnCnWPts3sgLrFFpl02+PtnjrZ auQjhRiGmgY3F6Gm6aYvGwOdD2CgomjtWyC3SUz116iKUwSSLo7R/JvtTve56doSp/Zd PaQfc003d9uttcAbVURDiURT0ACpRnw8VuMqxW3CmoaksPGegJ5WX16aFiLgP0KeLk0I 43Hg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:in-reply-to:content-disposition :references:message-id:subject:cc:to:from:date:dkim-signature; bh=gG6XbRyUT6NSTXVXXKDRnNhPDqDxmA5NDQ9AWLJWbfw=; b=SVjuxhcAQ2cvhGiC2GeFx2+uhGLMN8w9LVEFi48b87zfYoEHQyZs13jddjgyq9ejam s2jyMOVqhj+/To9M36TS00dJIN8sFHM3m5sE/A8opfhuXLG9cqMHboFxCoCdq51lIg2C cnz/dv0yKZdbcpkE8AFu/Xgn5iKYSDMM9KOru0TdLA6AX19Vk2aCcvvr1QVeZzOU14s5 RvdR96n/K4Js4X4sGn76i/2va6dHGYz/AgFZXv6hj5blVz3Mby0pz3rghXM5Z/iPnxdl bh7KrLrfx48SDBqEohrx7NZVKFiMXA3ZM2Sh9vWCX3oQKNOFP14tismgn4g6yVJhoB3i xB3A== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=KhcnEm47; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ng6-20020a17090b1a8600b00200ad6b1554si40500049pjb.6.2023.01.17.04.23.03; Tue, 17 Jan 2023 04:23:09 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=KhcnEm47; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236819AbjAQLp7 (ORCPT + 50 others); Tue, 17 Jan 2023 06:45:59 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58706 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236140AbjAQLp4 (ORCPT ); Tue, 17 Jan 2023 06:45:56 -0500 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2060.outbound.protection.outlook.com [40.107.223.60]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7EFF59012; Tue, 17 Jan 2023 03:45:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hXPL75JGCFDFehzfsovrw3Gfj6RE9SMejVaq/C5PjoIP73Ce06iVvcmHPQzrv1XdTNXyitCF1WTyRT7ezotjY6I8yAWB1Y3da6ga/lsrNuWIPjZkRV/hyXF4OX/HsBN2PXZVhYh6gOAn73/HfEwi+Tx6+P5fKYeaism/G4dsTtTvlWbVf2+20XgYir5QmhBkk+8AsZ+7N0Tub3RnjUk60J9xiV+JR09EZRs+TJI4RvJiebbg+lXzhWEaceURFlCq5DgTxvwH88hv2+K4LXfjVeRepYBhEW2HkEPeSH1XcOT/voDE18n5bp82hOZFoJuJwA3J5rFXxovXW6A96PeVPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=gG6XbRyUT6NSTXVXXKDRnNhPDqDxmA5NDQ9AWLJWbfw=; b=jClSOlTtWNJZJZGvA/mMxtiRzGgm0NYwsUAagM1E4o70hZ8oB5be1c6Zk6SAXkdQBCjKn/Tu2pASbm1OMGGaz+QayQi9BRa+P/bgiDDThZFz8uxxynm8kcvaMkG5n1yFQX/C3O5nDpjYhlYRx8T8004SGV1avQSZzl7xFPW4/bxEHyY5PjKeKKhOL5/Tp08FaatJkt31dkSYImxNI4QrXK6Ubo9Tpssgxt+L2b5IfWAaOY1r2rwdkcejyrwru6EnCXEKSYtDv0iHeCtFLr/ipIXyFwSisZr9wKS7DyaBaLhwU9ES61slZN1rI5mmGh4V6cfPhxrFqTNTtIYaY1k8Kg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=gG6XbRyUT6NSTXVXXKDRnNhPDqDxmA5NDQ9AWLJWbfw=; b=KhcnEm47sFf0gD9d3l4o49cjNHUKIWPDmv3Ok2zqnLntZVPq7OOHRvvxgPRYXlWzZT1yKFjjogrtkWy3yxwcsYgdFX+AyjddLChtwQqy8cyi5kZp1uscSlVJnGgDI6L8iMXAN91mUDtpx7ozEx9A27418AFSi+Tc4QL6mT5Wuaw= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from DM5PR12MB2504.namprd12.prod.outlook.com (2603:10b6:4:b5::19) by PH0PR12MB5420.namprd12.prod.outlook.com (2603:10b6:510:e8::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5986.23; Tue, 17 Jan 2023 11:45:53 +0000 Received: from DM5PR12MB2504.namprd12.prod.outlook.com ([fe80::d17b:f929:12fd:8ae]) by DM5PR12MB2504.namprd12.prod.outlook.com ([fe80::d17b:f929:12fd:8ae%4]) with mapi id 15.20.6002.013; Tue, 17 Jan 2023 11:45:53 +0000 Date: Tue, 17 Jan 2023 19:45:30 +0800 From: Huang Rui To: "Yuan, Perry" Cc: "rafael.j.wysocki@intel.com" , "Limonciello, Mario" , "viresh.kumar@linaro.org" , "Sharma, Deepak" , "Fontenot, Nathan" , "Deucher, Alexander" , "Huang, Shimmer" , "Du, Xiaojian" , "Meng, Li (Jassmine)" , "Karny, Wyes" , "linux-pm@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH v10 02/12] Documentation: amd-pstate: add EPP profiles introduction Message-ID: References: <20230106061420.95715-1-perry.yuan@amd.com> <20230106061420.95715-3-perry.yuan@amd.com> Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230106061420.95715-3-perry.yuan@amd.com> X-ClientProxiedBy: SI2PR06CA0009.apcprd06.prod.outlook.com (2603:1096:4:186::17) To DM5PR12MB2504.namprd12.prod.outlook.com (2603:10b6:4:b5::19) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DM5PR12MB2504:EE_|PH0PR12MB5420:EE_ X-MS-Office365-Filtering-Correlation-Id: 20229ec9-5fcb-47b6-ba16-08daf880635e X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: tBkWEppWX/cch7XpU2kpD0pNo+NBq4h47HNTPnEXcbU2IRUlQ5f2Jtkgh+fOyiJy0K1KS/blsyNYpIGaHl3La2DAWF2R/hgbt6BItkbq5HoyVHA/TEeIOtKMzvku1iCkSBQhhr2pjjeKrVlm8OBnmHKeLlRoSqwVwvTCOYCQ2tvkPW0Bx81dliXtvSX20gC2WgDr+Hu7JTkETYTJies24AWPr/BDLH2SdacXeIjR7d20pY+q+TB/ql4kunKOqiYN+Wf/9dyZCzI5ig07s+HXP0evCYJ22zBSOk4Wl012sEMkJcvpFa5O8cTFuVIDGXOANs56PEYXCaDd3nGn19x9Yq/EjbokMde91D94ZVwECFiGO1/gMmwD490dmw7ky7rM/9WNR1syzI/SefVdWD0Dtw2hEatoAqliaClBczpvS9o4Uu8w/4cWFLcMF3f3gMu2TLW9Mp17CPXgt9Cnp2X20YVQQEYdF98elBSUKLxe58rj0M8WbnLOFZA45zoECiQZzWerV6yQgHvivVahYAUFGbtNDF25ePXQhexa3D0VAcXF5+BfG1oH6rXyIhlugMMaY1hJsDrCMHGM8lpZ6S/O9ZDGaSrE9NWFAxVR7D/IkAGFuOeN+TVJ6INf+K17hlQU57HWkfwekpqka0Grpz191gZqQQ4BLxLsHu8uxWti0jeyWurJKI2pOeiZHXNQX+hY X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM5PR12MB2504.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(4636009)(346002)(366004)(39860400002)(396003)(136003)(376002)(451199015)(36756003)(86362001)(83380400001)(186003)(26005)(4326008)(41300700001)(8676002)(66946007)(66556008)(66476007)(2616005)(6512007)(316002)(6666004)(6636002)(54906003)(6486002)(478600001)(2906002)(37006003)(6506007)(38100700002)(5660300002)(6862004)(8936002)(67856001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?QCKFP7bET/+cYslVA4dd+lg44wq5cxIE+QeujrOHnnOv5xXN5nWoXgQU08Lp?= =?us-ascii?Q?ZSBHV/2qUx9dOIIFXq4A1cqna5YoRCKG2A6qByT6fUf0ORUvuaH0MyongwRd?= =?us-ascii?Q?Tfly4pjkHag2R5lFwjipLIGw01pF7sqBc0xgkZaqvbSVwXvtyxxRtTmOrmLe?= =?us-ascii?Q?fi5wiTv2MW/xNGE7JfuH5GW39syCn6RuTIdl0GoqaiTW8mj6vkw3immJyl0T?= =?us-ascii?Q?1+4viObRiSXbRmzjJ3bTl31Zl9gSmRWCs/lh6VoDh7bkG9ExV+6JGXWD2BYi?= =?us-ascii?Q?Y6pePmAeKFI0fzl3tv3w/02+89GvcxDPx3IfcuQ/VqxMsPGuWfn6a37sD+74?= =?us-ascii?Q?ASk7M1wfjDRWmUkhRP/Ny7gRbE0uwyNyT6WpptpyE7pHa208dH4KCvXH9mJ6?= =?us-ascii?Q?wF+VoSfY/IuT5XliscXSQqbpa+ZVXpho6qe5TD241MS/+SfrNgenH4A+ekge?= =?us-ascii?Q?IrDDEJZG3d12Xa61DhwWMWu8J5Nzg6SkqLZ5l4PVhfUvbJ1IFTqKYRobTd6k?= =?us-ascii?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RZvkZbSP7AGJK?= =?us-ascii?Q?XaD8fNGrXcAI2DUtsID2RWvlyCrTAhouuUHrD1Nh6lcNRsQp1nTsGRVgQEQ1?= =?us-ascii?Q?UUlw0IifrD8/iAfkMYiVZrgtKgtpJGlHkF9BaFvpaJshxvJ8+zAxhrKbfuyK?= =?us-ascii?Q?1i/l8wsANR0FO6YwPDJ3ac3h0tVVagFX+PKMhH38?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 20229ec9-5fcb-47b6-ba16-08daf880635e X-MS-Exchange-CrossTenant-AuthSource: DM5PR12MB2504.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Jan 2023 11:45:53.5188 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: nbJbK5C5TKqb8yVXTIuuu1Ws0K1QQ56oPDBRb8wRwJEGbk0PCxEH7vwTAlcX9slv+EBWJ1l/4wtA7A5Q9vMPiQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH0PR12MB5420 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS autolearn=ham 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 Fri, Jan 06, 2023 at 02:14:10PM +0800, Yuan, Perry wrote: > From: Perry Yuan > > The amd-pstate driver supports a feature called energy performance > preference (EPP). Add information to the documentation to explain > how users can interact with the sysfs files for this feature. > > 1) See all EPP profiles > $ sudo cat /sys/devices/system/cpu/cpu0/cpufreq/energy_performance_available_preferences > default performance balance_performance balance_power power > > 2) Check current EPP profile > $ sudo cat /sys/devices/system/cpu/cpu0/cpufreq/energy_performance_preference > performance > > 3) Set new EPP profile > $ sudo bash -c "echo power > /sys/devices/system/cpu/cpu0/cpufreq/energy_performance_preference" > > Reviewed-by: Mario Limonciello > Signed-off-by: Perry Yuan Acked-by: Huang Rui > --- > Documentation/admin-guide/pm/amd-pstate.rst | 19 +++++++++++++++++++ > 1 file changed, 19 insertions(+) > > diff --git a/Documentation/admin-guide/pm/amd-pstate.rst b/Documentation/admin-guide/pm/amd-pstate.rst > index 06e23538f79c..33ab8ec8fc2f 100644 > --- a/Documentation/admin-guide/pm/amd-pstate.rst > +++ b/Documentation/admin-guide/pm/amd-pstate.rst > @@ -262,6 +262,25 @@ lowest non-linear performance in `AMD CPPC Performance Capability > `_.) > This attribute is read-only. > > +``energy_performance_available_preferences`` > + > +A list of all the supported EPP preferences that could be used for > +``energy_performance_preference`` on this system. > +These profiles represent different hints that are provided > +to the low-level firmware about the user's desired energy vs efficiency > +tradeoff. ``default`` represents the epp value is set by platform > +firmware. This attribute is read-only. > + > +``energy_performance_preference`` > + > +The current energy performance preference can be read from this attribute. > +and user can change current preference according to energy or performance needs > +Please get all support profiles list from > +``energy_performance_available_preferences`` attribute, all the profiles are > +integer values defined between 0 to 255 when EPP feature is enabled by platform > +firmware, if EPP feature is disabled, driver will ignore the written value > +This attribute is read-write. > + > Other performance and frequency values can be read back from > ``/sys/devices/system/cpu/cpuX/acpi_cppc/``, see :ref:`cppc_sysfs`. > > -- > 2.34.1 >