From: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
To: Krishna Chomal <krishna.chomal108@gmail.com>
Cc: Hans de Goede <hansg@kernel.org>, platform-driver-x86@vger.kernel.org
Subject: Re: [PATCH] platform/x86: hp-wmi: fix platform profile values for Omen 16-wf1xxx
Date: Mon, 15 Dec 2025 16:25:17 +0200 (EET) [thread overview]
Message-ID: <6ae912bf-ceb9-b8cf-5e9b-831c91135a59@linux.intel.com> (raw)
In-Reply-To: <20251213185107.179130-1-krishna.chomal108@gmail.com>
On Sun, 14 Dec 2025, Krishna Chomal wrote:
> HP Omen 16-wf1xxx (board ID 8C78) currently sends the incorrect
> Victus-specific thermal profile values via WMI, leading to a logical
> inconsistency when switching between platform profiles.
>
> The driver currently uses Victus S values:
> 0x00 => Balanced / Low-Power
> 0x01 => Performance
>
> However, Omen Gaming Hub logs / EC register inspection on Windows shows
> that this board is intended to use:
> 0x30 => Balanced / Low-Power
> 0x31 => Performance
>
> This patch corrects the thermal profile command values to match the
> values observed from Omen Gaming Hub logs. The performance benchmarks
> and peak power draw (from both CPU and GPU) show no observable change
> with this correction (suggesting that the firmware is currently tolerant
> of the incorrect values). However sending the correct values prevents
> potential regressions after future firmware updates.
>
> Create a new omen_new_thermal_profile_boards[] array for devices that
> share the Victus WMI queries but require Omen thermal profile values.
> Conditionally use these values in platform_profile_victus_s_set_ec().
>
> Tested on: HP Omen 16-wf1xxx (board 8C78)
> Result: Confirmed WMI codes 0x30/0x31 are now sent, resolving the
> logical inconsistency and ensuring the value visible in EC registers
> match the Windows state for this profile.
>
> Fixes: fb146a38cb11 ("platform/x86: hp-wmi: Add Omen 16-wf1xxx fan support")
> Signed-off-by: Krishna Chomal <krishna.chomal108@gmail.com>
> ---
> drivers/platform/x86/hp/hp-wmi.c | 35 +++++++++++++++++++++++++++++---
> 1 file changed, 32 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/platform/x86/hp/hp-wmi.c b/drivers/platform/x86/hp/hp-wmi.c
> index f4ea1ea05997..4dfd5fc230e2 100644
> --- a/drivers/platform/x86/hp/hp-wmi.c
> +++ b/drivers/platform/x86/hp/hp-wmi.c
> @@ -105,6 +105,14 @@ static const char * const victus_s_thermal_profile_boards[] = {
> "8D41",
> };
>
> +/* DMI Board names of Omen laptops that have same WMI queries as
> + * victus_s_thermal_profile_boards but use hp_thermal_profile_omen_v1
> + * values.
> + */
> +static const char * const omen_new_thermal_profile_boards[] = {
> + "8C78",
> +};
> +
> enum hp_wmi_radio {
> HPWMI_WIFI = 0x0,
> HPWMI_BLUETOOTH = 0x1,
> @@ -1522,6 +1530,18 @@ static bool is_victus_thermal_profile(void)
> board_name) >= 0;
> }
>
> +static bool is_omen_new_thermal_profile(void)
> +{
> + const char *board_name = dmi_get_system_info(DMI_BOARD_NAME);
> +
> + if (!board_name)
> + return false;
> +
> + return match_string(omen_new_thermal_profile_boards,
> + ARRAY_SIZE(omen_new_thermal_profile_boards),
> + board_name) >= 0;
> +}
> +
> static int platform_profile_victus_get_ec(enum platform_profile_option *profile)
> {
> int tp;
> @@ -1678,19 +1698,28 @@ static int platform_profile_victus_s_set_ec(enum platform_profile_option profile
>
> switch (profile) {
> case PLATFORM_PROFILE_PERFORMANCE:
> - tp = HP_VICTUS_S_THERMAL_PROFILE_PERFORMANCE;
> + if (is_omen_new_thermal_profile())
> + tp = HP_OMEN_V1_THERMAL_PROFILE_PERFORMANCE;
> + else
> + tp = HP_VICTUS_S_THERMAL_PROFILE_PERFORMANCE;
> gpu_ctgp_enable = true;
> gpu_ppab_enable = true;
> gpu_dstate = 1;
> break;
> case PLATFORM_PROFILE_BALANCED:
> - tp = HP_VICTUS_S_THERMAL_PROFILE_DEFAULT;
> + if (is_omen_new_thermal_profile())
> + tp = HP_OMEN_V1_THERMAL_PROFILE_DEFAULT;
> + else
> + tp = HP_VICTUS_S_THERMAL_PROFILE_DEFAULT;
> gpu_ctgp_enable = false;
> gpu_ppab_enable = true;
> gpu_dstate = 1;
> break;
> case PLATFORM_PROFILE_LOW_POWER:
> - tp = HP_VICTUS_S_THERMAL_PROFILE_DEFAULT;
> + if (is_omen_new_thermal_profile())
> + tp = HP_OMEN_V1_THERMAL_PROFILE_DEFAULT;
> + else
> + tp = HP_VICTUS_S_THERMAL_PROFILE_DEFAULT;
> gpu_ctgp_enable = false;
> gpu_ppab_enable = false;
> gpu_dstate = 1;
Hi,
Thank you for the patch but it looks this approach to add mappings using
if()s to handle variations should be replaced with something better.
--
i.
next prev parent reply other threads:[~2025-12-15 14:25 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-13 18:51 [PATCH] platform/x86: hp-wmi: fix platform profile values for Omen 16-wf1xxx Krishna Chomal
2025-12-15 14:25 ` Ilpo Järvinen [this message]
2025-12-16 10:20 ` Krishna Chomal
2025-12-16 10:33 ` Ilpo Järvinen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6ae912bf-ceb9-b8cf-5e9b-831c91135a59@linux.intel.com \
--to=ilpo.jarvinen@linux.intel.com \
--cc=hansg@kernel.org \
--cc=krishna.chomal108@gmail.com \
--cc=platform-driver-x86@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox