lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <c0f02ffd-9a29-4411-8e5e-13a4d93c558f@app.fastmail.com>
Date: Fri, 01 Nov 2024 22:15:23 -0400
From: "Mark Pearson" <mpearson-lenovo@...ebb.ca>
To: "Limonciello, Mario" <mario.limonciello@....com>,
 "Hans de Goede" <hdegoede@...hat.com>,
 Ilpo Järvinen <ilpo.jarvinen@...ux.intel.com>
Cc: "Rafael J. Wysocki" <rafael@...nel.org>, "Len Brown" <lenb@...nel.org>,
 "Maximilian Luz" <luzmaximilian@...il.com>, "Lee Chun-Yi" <jlee@...e.com>,
 "Shyam Sundar S K" <Shyam-sundar.S-k@....com>,
 "Corentin Chary" <corentin.chary@...il.com>,
 "Luke D . Jones" <luke@...nes.dev>, "Ike Panhc" <ike.pan@...onical.com>,
 "Henrique de Moraes Holschuh" <hmh@....eng.br>,
 "Alexis Belmonte" <alexbelm48@...il.com>,
 Uwe Kleine-König <u.kleine-koenig@...gutronix.de>,
 "Ai Chao" <aichao@...inos.cn>, "Gergo Koteles" <soyer@....hu>,
 "open list" <linux-kernel@...r.kernel.org>,
 "linux-acpi@...r.kernel.org" <linux-acpi@...r.kernel.org>,
 "platform-driver-x86@...r.kernel.org" <platform-driver-x86@...r.kernel.org>,
 "open list:THINKPAD ACPI EXTRAS DRIVER" <ibm-acpi-devel@...ts.sourceforge.net>,
 "Matthew Schwartz" <matthew.schwartz@...ux.dev>
Subject: Re: [PATCH v3 17/22] ACPI: platform_profile: Add concept of a "custom" profile



On Thu, Oct 31, 2024, at 12:09 AM, Mario Limonciello wrote:
> When two profile handlers don't agree on the current profile it's ambiguous
> what to show to the legacy sysfs interface.
>
> Add a "custom" profile string that userspace will be able to distinguish
> this situation when using the legacy sysfs interface.
>
> Signed-off-by: Mario Limonciello <mario.limonciello@....com>
> ---
>  drivers/acpi/platform_profile.c  | 1 +
>  include/linux/platform_profile.h | 1 +
>  2 files changed, 2 insertions(+)
>
> diff --git a/drivers/acpi/platform_profile.c b/drivers/acpi/platform_profile.c
> index c2bb325ba531c..3128bd16615b6 100644
> --- a/drivers/acpi/platform_profile.c
> +++ b/drivers/acpi/platform_profile.c
> @@ -20,6 +20,7 @@ static const char * const profile_names[] = {
>  	[PLATFORM_PROFILE_BALANCED] = "balanced",
>  	[PLATFORM_PROFILE_BALANCED_PERFORMANCE] = "balanced-performance",
>  	[PLATFORM_PROFILE_PERFORMANCE] = "performance",
> +	[PLATFORM_PROFILE_CUSTOM] = "custom",
>  };
>  static_assert(ARRAY_SIZE(profile_names) == PLATFORM_PROFILE_LAST);
> 
> diff --git a/include/linux/platform_profile.h b/include/linux/platform_profile.h
> index 6aad98f4abaf4..da009c8a402c9 100644
> --- a/include/linux/platform_profile.h
> +++ b/include/linux/platform_profile.h
> @@ -23,6 +23,7 @@ enum platform_profile_option {
>  	PLATFORM_PROFILE_BALANCED,
>  	PLATFORM_PROFILE_BALANCED_PERFORMANCE,
>  	PLATFORM_PROFILE_PERFORMANCE,
> +	PLATFORM_PROFILE_CUSTOM,
>  	PLATFORM_PROFILE_LAST, /*must always be last */
>  };
> 
> -- 
> 2.43.0

Looks good to me.
Reviewed-by: Mark Pearson <mpearson-lenovo@...ebb.ca>

Mark

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ