All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] platform/x86: alienware-wmi-wmax: Do not enable G-Mode for Dell G-series
@ 2026-09-02  7:40 Lewis Clement
  2026-09-05  0:53 ` Kurt Borja
  0 siblings, 1 reply; 3+ messages in thread
From: Lewis Clement @ 2026-09-02  7:40 UTC (permalink / raw)
  To: platform-driver-x86; +Cc: kuurtb, ilpo.jarvinen, stable, Lewis Clement

The alienware-wmi-wmax driver auto-engages EC G-Mode (Game Shift) for
Dell G-series laptops when the platform profile is set to "performance".
On models like the Dell G5 SE 5505, this pins both fans at 100% (~5400 RPM)
permanently on every boot.

Fix this by:
1. Setting generic_quirks (gmode=false) for G-series DMI entries so
   selecting "performance" no longer toggles G-Mode.
2. In awcc_platform_profile_probe(), mapping PLATFORM_PROFILE_PERFORMANCE
   to balanced-performance when no dedicated performance profile exists,
   keeping the option available with sane fan behavior.

This mirrors commit e2468dc70074 ("Revert "platform/x86:
alienware-wmi-wmax: Add G-Mode support to Alienware m16 R1"").

Fixes: 202a86120590 ("platform/x86: alienware-wmi-wmax: Extend support to more laptops")
Tested-by: Lewis Clement <lewis@lewisclement.nl>
Signed-off-by: Lewis Clement <lewis@lewisclement.nl>
---
Tested on a Dell G5 SE 5505 (Ryzen 4600H/4800H + RX 5600M, BIOS 1.24.0),
kernel 7.1.10 (module built out-of-tree against the running kernel):

- Before: fans pinned at ~5400 RPM on every cold boot with
  profile=performance; cleared only by suspend/resume.
- After: fans normal (~2400 RPM, scaling with temperature) with
  profile=performance; survives cold reboot; "performance" remains in
  /sys/firmware/acpi/platform_profile_choices.
- Also validated the intermediate gmode=false-only variant (option
  disappears -> tuned-ppd write rejected as EOPNOTSUPP), which confirmed
  G-Mode was the only fan-pinning path.

Cc: platform-driver-x86@vger.kernel.org
Cc: Kurt Borja <kuurtb@gmail.com>
Cc: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Cc: stable@vger.kernel.org # 6.15+

 .../platform/x86/dell/alienware-wmi-wmax.c    | 22 +++++++++++++++----
 1 file changed, 18 insertions(+), 4 deletions(-)

diff --git a/drivers/platform/x86/dell/alienware-wmi-wmax.c b/drivers/platform/x86/dell/alienware-wmi-wmax.c
index d1b4df91401b..26ba91539b6e 100644
--- a/drivers/platform/x86/dell/alienware-wmi-wmax.c
+++ b/drivers/platform/x86/dell/alienware-wmi-wmax.c
@@ -207,7 +207,7 @@ static const struct dmi_system_id awcc_dmi_table[] __initconst = {
 			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
 			DMI_MATCH(DMI_PRODUCT_NAME, "Dell G15"),
 		},
-		.driver_data = &g_series_quirks,
+		.driver_data = &generic_quirks,
 	},
 	{
 		.ident = "Dell Inc. G16",
@@ -215,7 +215,7 @@ static const struct dmi_system_id awcc_dmi_table[] __initconst = {
 			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
 			DMI_MATCH(DMI_PRODUCT_NAME, "Dell G16"),
 		},
-		.driver_data = &g_series_quirks,
+		.driver_data = &generic_quirks,
 	},
 	{
 		.ident = "Dell Inc. G3",
@@ -223,7 +223,7 @@ static const struct dmi_system_id awcc_dmi_table[] __initconst = {
 			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
 			DMI_MATCH(DMI_PRODUCT_NAME, "G3"),
 		},
-		.driver_data = &g_series_quirks,
+		.driver_data = &generic_quirks,
 	},
 	{
 		.ident = "Dell Inc. G5",
@@ -231,7 +231,7 @@ static const struct dmi_system_id awcc_dmi_table[] __initconst = {
 			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
 			DMI_MATCH(DMI_PRODUCT_NAME, "G5"),
 		},
-		.driver_data = &g_series_quirks,
+		.driver_data = &generic_quirks,
 	},
 	{}
 };
@@ -1345,6 +1345,20 @@ static int awcc_platform_profile_probe(void *drvdata, unsigned long *choices)
 		__set_bit(PLATFORM_PROFILE_PERFORMANCE, choices);
 	}
 
+	/*
+	 * Some models (e.g. the Dell G5 SE) have no dedicated "performance"
+	 * EC profile and map PLATFORM_PROFILE_PERFORMANCE only to G-Mode,
+	 * which runs the fans at 100%. When G-Mode is not used, fall back to
+	 * the balanced-performance profile so the option stays available with
+	 * sane fan behavior.
+	 */
+	if (!test_bit(PLATFORM_PROFILE_PERFORMANCE, choices) &&
+	    test_bit(PLATFORM_PROFILE_BALANCED_PERFORMANCE, choices)) {
+		priv->supported_profiles[PLATFORM_PROFILE_PERFORMANCE] =
+			priv->supported_profiles[PLATFORM_PROFILE_BALANCED_PERFORMANCE];
+		__set_bit(PLATFORM_PROFILE_PERFORMANCE, choices);
+	}
+
 	/* Every model supports the "custom" profile */
 	priv->supported_profiles[PLATFORM_PROFILE_CUSTOM] =
 		AWCC_PROFILE_SPECIAL_CUSTOM;
-- 
2.55.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] platform/x86: alienware-wmi-wmax: Do not enable G-Mode for Dell G-series
  2026-09-02  7:40 [PATCH] platform/x86: alienware-wmi-wmax: Do not enable G-Mode for Dell G-series Lewis Clement
@ 2026-09-05  0:53 ` Kurt Borja
  2026-09-07  7:17   ` Lewis Clement
  0 siblings, 1 reply; 3+ messages in thread
From: Kurt Borja @ 2026-09-05  0:53 UTC (permalink / raw)
  To: Lewis Clement, platform-driver-x86; +Cc: kuurtb, ilpo.jarvinen, stable

On Wed Sep 2, 2026 at 4:40 AM -03, Lewis Clement wrote:
> The alienware-wmi-wmax driver auto-engages EC G-Mode (Game Shift) for
> Dell G-series laptops when the platform profile is set to "performance".
> On models like the Dell G5 SE 5505, this pins both fans at 100% (~5400 RPM)
> permanently on every boot.

Hmmm... This seems like you are trying to fix a userspace problem by
patching the driver. What is preventing you from just not selecting the
"performance" profile if you don't like the fans spinning at 100%? With
this patch you are promoting balanced-performance to performance so you
*could* just do that in userspace right? I'm pretty sure Tuned can do
it.

I actually do agree that fans at 100% can be annoying, but that is
subjective. In Windows pressing the "G-Mode" button selects the maximum
performance profile and ramps up fans to 100% too; this driver tries to
mimic that behavior.

>
> Fix this by:
> 1. Setting generic_quirks (gmode=false) for G-series DMI entries so
>    selecting "performance" no longer toggles G-Mode.

You are removing the G-Mode profile for every G-Series laptop. As I
said earlier, some users may like it and some may not at all so it
qualifies as a regression, which would not be acceptable.

> 2. In awcc_platform_profile_probe(), mapping PLATFORM_PROFILE_PERFORMANCE
>    to balanced-performance when no dedicated performance profile exists,
>    keeping the option available with sane fan behavior.

This is a completely different change that would require a different
patch. I'm not exactly against it because of how PPD usually does
things.

Do you know if the AWCC app in Windows does this? Does it map
"performance" to the balanced-performance mode? Not that we have to
follow everything Windows does but it can be a starting point.

>
> This mirrors commit e2468dc70074 ("Revert "platform/x86:
> alienware-wmi-wmax: Add G-Mode support to Alienware m16 R1"").

This does not mirror that commit. That commit revers G-Mode because it
has less performance than the plain "performance" mode. Does this happen
in your case?

>
> Fixes: 202a86120590 ("platform/x86: alienware-wmi-wmax: Extend support to more laptops")

Not a fix.

> Tested-by: Lewis Clement <lewis@lewisclement.nl>
> Signed-off-by: Lewis Clement <lewis@lewisclement.nl>
> ---
> Tested on a Dell G5 SE 5505 (Ryzen 4600H/4800H + RX 5600M, BIOS 1.24.0),
> kernel 7.1.10 (module built out-of-tree against the running kernel):
>
> - Before: fans pinned at ~5400 RPM on every cold boot with
>   profile=performance; cleared only by suspend/resume.
> - After: fans normal (~2400 RPM, scaling with temperature) with
>   profile=performance; survives cold reboot; "performance" remains in
>   /sys/firmware/acpi/platform_profile_choices.
> - Also validated the intermediate gmode=false-only variant (option
>   disappears -> tuned-ppd write rejected as EOPNOTSUPP), which confirmed
>   G-Mode was the only fan-pinning path.
>
> Cc: platform-driver-x86@vger.kernel.org

You dropped this Cc.

> Cc: Kurt Borja <kuurtb@gmail.com>
> Cc: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
> Cc: stable@vger.kernel.org # 6.15+

[...]

Can you email me the acpidump for this model? I want to check what
profiles are reported by the firmware.

-- 
Thanks,
 ~ Kurt

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] platform/x86: alienware-wmi-wmax: Do not enable G-Mode for Dell G-series
  2026-09-05  0:53 ` Kurt Borja
@ 2026-09-07  7:17   ` Lewis Clement
  0 siblings, 0 replies; 3+ messages in thread
From: Lewis Clement @ 2026-09-07  7:17 UTC (permalink / raw)
  To: platform-driver-x86; +Cc: kuurtb, ilpo.jarvinen

Hi Kurt, 

Thanks for taking a look. 

I would agree that losing the option for enabling the "G-Mode" isn't desirable.
However, there is a semantic issue in here: what is normally communicated as a
separate gaming mode now replaces the normal performance mode. It took me this
kernel driver investigation to find out that switching to balanced would've
fixed my problem. Since my device configuration doesn't have a G-Mode button,
I wasn't even aware of the feature for this machine before. As far as I
understand it, performance is commonly the default selection by distros when
the machine is plugged in, so this behavior can be triggered without the user
explicitly choosing G-Mode.
Also, I just found out that in Gnome desktop selecting balanced will enable the
Balanced profile, while selecting power saver enables Balanced-Performance. 
That seems confusing to me.

If you think this should be addressed in userspace, 
where would you suggest this needs to be handled?

Attached you'll find my acpidump. 

Thanks, 
Lewis

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-09-07  7:24 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-02  7:40 [PATCH] platform/x86: alienware-wmi-wmax: Do not enable G-Mode for Dell G-series Lewis Clement
2026-09-05  0:53 ` Kurt Borja
2026-09-07  7:17   ` Lewis Clement

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.