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] [day] [month] [year] [list]
Message-ID: <9a2ce7a9-9c8c-4279-aa9c-de9fa879f38b@linux.intel.com>
Date: Tue, 15 Oct 2024 11:20:58 +0300 (EEST)
From: Ilpo Järvinen <ilpo.jarvinen@...ux.intel.com>
To: Kurt Borja <kuurtb@...il.com>
cc: Hans de Goede <hdegoede@...hat.com>, LKML <linux-kernel@...r.kernel.org>, 
    platform-driver-x86@...r.kernel.org
Subject: Re: [PATCH v5 3/4] alienware-wmi: added platform profile support

On Fri, 11 Oct 2024, Kurt Borja wrote:

> Implements platform profile support for Dell laptops with new WMAX
> thermal interface, present on some Alienware X-Series, Alienware
> M-Series and Dell's G-Series laptops. This implementation supports two
> sets of thermal profile codes, namely *thermal* and *thermal_ustt*, plus
> additional quirk *gmode* for Dell's G-Series laptops.
> 
> Signed-off-by: Kurt Borja <kuurtb@...il.com>
> ---
>  drivers/platform/x86/dell/Kconfig         |   1 +
>  drivers/platform/x86/dell/alienware-wmi.c | 236 ++++++++++++++++++++++
>  2 files changed, 237 insertions(+)
> 
> diff --git a/drivers/platform/x86/dell/Kconfig b/drivers/platform/x86/dell/Kconfig
> index 68a49788a..b06d634cd 100644
> --- a/drivers/platform/x86/dell/Kconfig
> +++ b/drivers/platform/x86/dell/Kconfig
> @@ -21,6 +21,7 @@ config ALIENWARE_WMI
>  	depends on LEDS_CLASS
>  	depends on NEW_LEDS
>  	depends on ACPI_WMI
> +	select ACPI_PLATFORM_PROFILE
>  	help
>  	 This is a driver for controlling Alienware BIOS driven
>  	 features.  It exposes an interface for controlling the AlienFX
> diff --git a/drivers/platform/x86/dell/alienware-wmi.c b/drivers/platform/x86/dell/alienware-wmi.c
> index b27f3b64c..6e30e9376 100644
> --- a/drivers/platform/x86/dell/alienware-wmi.c
> +++ b/drivers/platform/x86/dell/alienware-wmi.c
> @@ -8,8 +8,11 @@
>  #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
>  
>  #include <linux/acpi.h>
> +#include <linux/bitfield.h>
> +#include <linux/bits.h>
>  #include <linux/module.h>
>  #include <linux/platform_device.h>
> +#include <linux/platform_profile.h>
>  #include <linux/dmi.h>
>  #include <linux/leds.h>
>  
> @@ -25,6 +28,12 @@
>  #define WMAX_METHOD_AMPLIFIER_CABLE	0x6
>  #define WMAX_METHOD_DEEP_SLEEP_CONTROL	0x0B
>  #define WMAX_METHOD_DEEP_SLEEP_STATUS	0x0C
> +#define WMAX_METHOD_THERMAL_INFORMATION	0x14
> +#define WMAX_METHOD_THERMAL_CONTROL	0x15
> +
> +#define WMAX_ARG_GET_CURRENT_PROF	0x0B
> +
> +#define WMAX_FAILURE_CODE		0xFFFFFFFF
>  
>  MODULE_AUTHOR("Mario Limonciello <mario.limonciello@...look.com>");
>  MODULE_DESCRIPTION("Alienware special feature control");
> @@ -49,11 +58,27 @@ enum WMAX_CONTROL_STATES {
>  	WMAX_SUSPEND = 3,
>  };
>  
> +enum WMAX_THERMAL_PROFILE {
> +	WMAX_THERMAL_QUIET = 0x96,
> +	WMAX_THERMAL_BALANCED = 0x97,
> +	WMAX_THERMAL_BALANCED_PERFORMANCE = 0x98,
> +	WMAX_THERMAL_PERFORMANCE = 0x99,
> +	WMAX_THERMAL_USTT_LOW_POWER = 0xA5,
> +	WMAX_THERMAL_USTT_QUIET = 0xA3,
> +	WMAX_THERMAL_USTT_BALANCED = 0xA0,
> +	WMAX_THERMAL_USTT_BALANCED_PERFORMANCE = 0xA1,
> +	WMAX_THERMAL_USTT_PERFORMANCE = 0xA4,
> +	WMAX_THERMAL_GMODE = 0xAB,

While doing the next version, could also align these values please.

-- 
 i.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ