From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 6753945AD8; Mon, 7 Oct 2024 21:25:06 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 085004025D; Mon, 7 Oct 2024 21:25:06 +0200 (CEST) Received: from NAM04-BN8-obe.outbound.protection.outlook.com (mail-bn8nam04on2078.outbound.protection.outlook.com [40.107.100.78]) by mails.dpdk.org (Postfix) with ESMTP id E356E4025C for ; Mon, 7 Oct 2024 21:25:03 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=m6oXRzi8KReIwvW0+SqxW/kiRykKQ7dmNsd7aRSWZoLSQzIZr4Cp2zU70ytHsyiDbsa00Af1LLLRjw2erdvYUfE/E9T6XEJ5Kei105BjMZQvdC2lZpP3hwBzoz/bJgosw6wHaIfogcm+UFagLjhp37YiXVG/lg9TlGvDJpw82Cjyem3UjCf7nvJEi9Td22NUt8/FtiEgIncy1peV2ho3kFcl8UdaGUvbsMigA7ekOSPSUa8P8Q+bq3kHIqrocJdesqBn7WhLIQ9Z3LuUAK7TQxvEKRTDgf1p0/V/6NHtoaBbqVmiKc4wCyLlUuwJNivF/h6lhiI7D243ExYIwcqOxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=Qxkk36sE71cwHJQh4fVauGQO/RXpll6cTRH4YxLGoPk=; b=a81UPVwXmsnaPMYPGRpYSjwQPmq7vqIoHVD099Tso2lv4qGyMAkB6wIMVUloTEHIgGg5tM+be5ny3RxdpZI4s2idkg7tro2u5G5lgdMMVYC/EY71T8d+GxQI8thaK3qN2Z5YAimAJvyOcFc4GFB2N90Y+RUsz7p8svaqJ9NGvT008xk6CCWW2rc4bCRJwpSJSJL78vjPD18W6tG6xsaqKGSv2CWWTmIh0/Idjb7mOAjp2KPmNxtonVSJnvQVm3worZuP5RPu3sWy9B6WbXkZc6UOR3pt7zqKoY6WAIwLYOhJD7CF9FfGW9wX90Yn9LqD89HVYxzvLRqFkgzSQ1PUuQ== 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=Qxkk36sE71cwHJQh4fVauGQO/RXpll6cTRH4YxLGoPk=; b=sBLe1N9b4ZByMorZlGxTMiBqe63sgaex1yOul2X9vq/X7oudomP6qlc4CEmYUq4kWlBNdOAcF7ED+2osQe+vU6HG8+/3Ub3pMEKHDJ6b8zG+E23oq4urOB7RisXMA10yzNevkSp/MGJQKem1k1Fsi3UZieKQb2CW2PEBpKSzX6Q= Received: from CH3PR12MB8233.namprd12.prod.outlook.com (2603:10b6:610:129::15) by DM6PR12MB4466.namprd12.prod.outlook.com (2603:10b6:5:2ae::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8026.23; Mon, 7 Oct 2024 19:25:00 +0000 Received: from CH3PR12MB8233.namprd12.prod.outlook.com ([fe80::278f:5cc5:549c:3515]) by CH3PR12MB8233.namprd12.prod.outlook.com ([fe80::278f:5cc5:549c:3515%5]) with mapi id 15.20.8026.020; Mon, 7 Oct 2024 19:25:00 +0000 From: "Tummala, Sivaprasad" To: Stephen Hemminger CC: "david.hunt@intel.com" , "anatoly.burakov@intel.com" , "jerinj@marvell.com" , "radu.nicolau@intel.com" , "gakhil@marvell.com" , "cristian.dumitrescu@intel.com" , "Yigit, Ferruh" , "konstantin.ananyev@huawei.com" , "dev@dpdk.org" Subject: RE: [PATCH v2 1/4] power: refactor core power management library Thread-Topic: [PATCH v2 1/4] power: refactor core power management library Thread-Index: AQHa97jruE4/5FJoc0KdhklxB9GDGbI5qSoAgEJAXTA= Date: Mon, 7 Oct 2024 19:25:00 +0000 Message-ID: References: <20240720165030.246294-1-sivaprasad.tummala@amd.com> <20240826130650.320130-1-sivaprasad.tummala@amd.com> <20240826130650.320130-2-sivaprasad.tummala@amd.com> <20240826082622.643538f8@hermes.local> In-Reply-To: <20240826082622.643538f8@hermes.local> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_ActionId=9648a7e6-317b-4500-ab67-d922a2405607; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_ContentBits=0; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_Enabled=true; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_Method=Standard; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_Name=AMD Internal Distribution Only; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_SetDate=2024-10-07T19:09:51Z; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: CH3PR12MB8233:EE_|DM6PR12MB4466:EE_ x-ms-office365-filtering-correlation-id: 201a7931-fab7-4661-9be9-08dce705bc94 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; ARA:13230040|376014|1800799024|366016|38070700018; x-microsoft-antispam-message-info: =?us-ascii?Q?y0tNS++tsLhKS8kpR85QEfDmxFhXvGrMZmlgoPp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FVtORE1TRqX+BQZWcd7cleRhzgQMVNyg260U/Kbdn/3dV/gvbl8N?= =?us-ascii?Q?EOb9PtTzSwxy8b9xvSrjNu2zOtwOGYICpNOrwYidRjPHvlmCV+jl6fY4uVUx?= =?us-ascii?Q?ilNEVOpcS++esq/5bIzW7Tr8wnvsR0nKTDTdILoQRF9TJDx0N4Hj121gna1g?= =?us-ascii?Q?eaAnwu8FgN27B7W7fIfaerRErjtn9nGYp2VPrDYeCR7nivbeNb1hGWgQhnJk?= =?us-ascii?Q?io1BlNdHcme1WJbJgMGvr8Cu48914p6Ub5O7XgWMPgjNee3tuFHYBs5nCXl1?= =?us-ascii?Q?C/oKhVskRdN3EMo5n3GRziyyWSJEzJpEvb3J++zJHpxoJTxuGapBboQ5x3+2?= =?us-ascii?Q?cqM+UrN+QGl4uq4tQCF4/CS+r0nXc4Ip19yeu6CuNbaR0jD90xCC1PM3Y9i4?= =?us-ascii?Q?eYXWE0oHMx88xBR/FA7+kbgrIb89ewmK481zJb/82GHQrw=3D=3D?= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CH3PR12MB8233.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(376014)(1800799024)(366016)(38070700018); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?RAw9r1N5v8k0eRIApfC2saw7LtOS8U2IlFaToMiGpyE7zxkf2tqbs26DLAHj?= =?us-ascii?Q?iI4I5Y3jBHabYmknTZ6ORgWzzeL/Ibf4JZmXG6Lsvg6tM0dIW+XdnyVZuU5o?= =?us-ascii?Q?tYhDM4PWTBGvqYFgWZZ7OEOlAFHGlXtjIH4nZhmDTofW8saTad3Jd5cCNDv/?= =?us-ascii?Q?hmF8AAgmgCDgs1i59khvpc4ORS6aVoOE4eYrmkJYS7Ci9bsyyzfpnvxbszVv?= =?us-ascii?Q?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ILxhZ3iKuIe7?= =?us-ascii?Q?tbwUw7BRP0akFP5f1WhQQAutjx4srTJNdRXM98T1TyJeLHlt526Jcnzz8Mh6?= =?us-ascii?Q?vtU98LYvkI94c0DEHBoEtAka/MQeQmDQqhQkIwo1ya92p4G4AsoN1Ekgc/7R?= =?us-ascii?Q?6/vOZ56h1NWvyuSOjotFVmzaKPgbS/KksqTr4yGMs9p+n8cCKNdWy0VszSIz?= =?us-ascii?Q?v0Ru10hNpuhO7f6CHOd9NRX3tjCL0Hxa7lkmDRV2pMeWhBlEGmrGYbKKJygu?= =?us-ascii?Q?98qFUZ0YuHYa9f6nEw74/QcyHUHQiIjDzGduTXQi16A8uUevwjQWkG0xZd2p?= =?us-ascii?Q?s2c4+JJ7wVAW2afjXw5eHDBo/u8ScmRtMX9OLErL54mTD1ZZtqxYW2/mpY6H?= =?us-ascii?Q?I0wn3Ueoh2mdVCWJXfzCJfJ+txJdkE9FohgshGdkitmfZl3W2MvoFw1ztoSn?= =?us-ascii?Q?SusN+k6SQCChoFhBx5c=3D?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: CH3PR12MB8233.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 201a7931-fab7-4661-9be9-08dce705bc94 X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Oct 2024 19:25:00.4084 (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: oD+lv0Q4j09OvDWN2GFqqcMXvy4iWeu+JrIk30f3Y/ae//8nRO3EazAP4e9DrJDkPZ2S6SDjFgown5wx0EM1EQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB4466 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org [AMD Official Use Only - AMD Internal Distribution Only] Hi Stephen, > -----Original Message----- > From: Stephen Hemminger > Sent: Monday, August 26, 2024 8:56 PM > To: Tummala, Sivaprasad > Cc: david.hunt@intel.com; anatoly.burakov@intel.com; jerinj@marvell.com; > radu.nicolau@intel.com; gakhil@marvell.com; cristian.dumitrescu@intel.com= ; Yigit, > Ferruh ; konstantin.ananyev@huawei.com; > dev@dpdk.org > Subject: Re: [PATCH v2 1/4] power: refactor core power management library > > Caution: This message originated from an External Source. Use proper caut= ion > when opening attachments, clicking links, or responding. > > > On Mon, 26 Aug 2024 13:06:46 +0000 > Sivaprasad Tummala wrote: > > > +static struct rte_power_core_ops acpi_ops =3D { > > + .name =3D "acpi", > > + .init =3D power_acpi_cpufreq_init, > > + .exit =3D power_acpi_cpufreq_exit, > > + .check_env_support =3D power_acpi_cpufreq_check_supported, > > + .get_avail_freqs =3D power_acpi_cpufreq_freqs, > > + .get_freq =3D power_acpi_cpufreq_get_freq, > > + .set_freq =3D power_acpi_cpufreq_set_freq, > > + .freq_down =3D power_acpi_cpufreq_freq_down, > > + .freq_up =3D power_acpi_cpufreq_freq_up, > > + .freq_max =3D power_acpi_cpufreq_freq_max, > > + .freq_min =3D power_acpi_cpufreq_freq_min, > > + .turbo_status =3D power_acpi_turbo_status, > > + .enable_turbo =3D power_acpi_enable_turbo, > > + .disable_turbo =3D power_acpi_disable_turbo, > > + .get_caps =3D power_acpi_get_capabilities }; > > + > > Can this be made const? > It is good for security and overall safety to have structures with functi= on pointers > marked const. The struct relies on dynamic list operations, it makes sense to keep it mut= able. This will ensure we can effectively manage the operations as needed without running into issues with read-only restrictions.