From nobody Wed Apr 1 20:42:55 2026 Received: from mail-pj1-f47.google.com (mail-pj1-f47.google.com [209.85.216.47]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C56DA3DEAE3 for ; Wed, 1 Apr 2026 11:18:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.47 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775042293; cv=none; b=E4Fb1mG7ZHcGRMpQdwRMH8zsVY6eLzx50eJkorpfw6foNRA/l12T3Y6pNU779y8ZCUSwkHk9WT9H0KvMXGfivtIxBOsyWWRgTMq8tHswwE0Ds8EYVcj0EW31/bDYgnBeyg3C1r1PV1CUeomPi6rboXggIEqKWtUnbHcxgSikpYE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775042293; c=relaxed/simple; bh=JPbB3lxSCXRaYUR+xW47osXy0IVHVCaCGPKYGLISgBE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=oFAHmtmBqv2bhEw8BbMidX2qrZkop9rki3t9iEvvPVLvpso4bte1UerC/jLWCvncl/+97ri+wnkTjbkf9uLgwnFaO9UqBgkQj5wRt1R5xbqKicxvx2KsDNi1+ojwMYPgwuruV6P4yMc88S5zupkV21QDHvdYeGegI8SWQdTO2cw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=l/z9Bv0O; arc=none smtp.client-ip=209.85.216.47 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="l/z9Bv0O" Received: by mail-pj1-f47.google.com with SMTP id 98e67ed59e1d1-35d9749c26dso3203160a91.2 for ; Wed, 01 Apr 2026 04:18:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1775042292; x=1775647092; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=o8J9smKGowWMdR9oHje2W97PGn5/bAbt4cYk0bUF6U8=; b=l/z9Bv0OhWZn2idL3w9vT0dzaAoFYBrCYl73UBuDQYhH3BuL0791/extEym5JNGBBO r9WMFLTHKgyRx/beb8FhQ0OK+BzrpVbLzeRZ0PcCRxq+oqmoZbnJRYS8o/YeTmCU4rPu Zm9zxtvIl0J0rS/cVXdCMFCxNnNchOMUKSrWsz2/dDFlg1f168hT8WwE2zDKE4Thh+5U B/vz2yMJj7ysD9kojZtxbxXHVAn/tvcxJRu4B3GsQL439XfcHRYvI0I0XKlRAeFB3wRJ DLoU5BYgFeM/tnn3gkdg+ZqE6nIIAtIshQmRUKi7cxXZ1hprqkD3q3wBz4ZyXYusVcuW 4I7Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1775042292; x=1775647092; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=o8J9smKGowWMdR9oHje2W97PGn5/bAbt4cYk0bUF6U8=; b=rZA9Qspa8SZsv01Qc41v6a4Ot5ojcXbkrm3zIC91Gaquwr9RNqNWps2RJW2caOh5Xk peGfP1052KkiM+wLYXLZmZAEFegBLfGOljPv/XDNSOlINfWl5yAaAINECkiE+xy7KHe0 GE91mK0DhlkSAF6aYJhntHaM99OPsfn9RuOO2owai8iWUwQE+/MOBOVxEHGywPx/IkwH Ao6Vr4RMG1kRQduZJPHcW2rnFxnYX+xJgQ0BVeLGUDuObe2yEYOt+GDPBxXTeAYx+T+s qYWW7nw/mmDgtFI0QloO7tF+//cRB6ap1aTdBzL4BP4dpX8rk2D48VT4HRI0OCrAende HZ7A== X-Forwarded-Encrypted: i=1; AJvYcCVxYO9TV8pzE79m+BF2gXoTt9VwpDTxsZLocRvxPLj50ET182VcSRcSQqrGs8USVTpvpsRg4O6NQoNu0bQ=@vger.kernel.org X-Gm-Message-State: AOJu0YyFyVZSriAsGNOXwMFAfVD+aeGr6p+dESNf3nAs8re0YlEa99BX VFRafAJ+nPMKioP/I1ssD58z3Qouqw6utzpdfEF9AfoglrTzHJ39httD X-Gm-Gg: ATEYQzwXoiPfPKqorc7lAb18qdO43xcAnyYnR0OpnRlyulpXg/oWSxrfiNP40GCN+i9 KMRsOQ8jsgMPXY8nS7v/qDAuNGtbamjQmXCs12T4L+xEcWFpKORd8u6HFQ3DdzEXopZqQgPUwtn FrO8K6YzgzPjppsu3Y6Rp+pFkXoAeCSpyfcsxakHSlf7FOtEPE6RhNqeoSr9nxiT1sdJsZepwvF KfqC0oadU/GRDoW4N/U0TEBtmK7PKW34YyUEuWv0RgkidSTbdQXgFt6Wi7f0ohadTsUM5/eWPte Ff7mUQc4WVeqyZIvF9SWEjriARaJwWp3jWAt7GsjuY/854k6nL/EtOKkqiiJzEL68JoXn9ltrIh I0J2awxnn73TMrWcjqBRpx/t/jVEKKy7WHHdfRmbDE01RB+G0V3XpZiqVsq9R+aSM+A8eqZIAkx aK0CPUGma4GH0bclVwmfkOgd4vov0feoxnM+gaBDQ/0bsGQzDY3hXv9saX0MN9uxxCRrLFCX6ky 1S88nPIHHzWlqet/LDA X-Received: by 2002:a17:90b:1fc4:b0:359:f22:8879 with SMTP id 98e67ed59e1d1-35dc6f90b2amr3127278a91.22.1775042291968; Wed, 01 Apr 2026 04:18:11 -0700 (PDT) Received: from archlinux ([2405:201:1b:225c:eb9d:1fc0:f95c:bd90]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-35dcafd004fsm1889689a91.12.2026.04.01.04.18.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Apr 2026 04:18:11 -0700 (PDT) From: Krishna Chomal To: ilpo.jarvinen@linux.intel.com, hansg@kernel.org Cc: platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, Krishna Chomal Subject: [PATCH 1/4] platform/x86: hp-wmi: fix fan table parsing Date: Wed, 1 Apr 2026 16:47:45 +0530 Message-ID: <20260401111748.106970-2-krishna.chomal108@gmail.com> X-Mailer: git-send-email 2.53.0 In-Reply-To: <20260401111748.106970-1-krishna.chomal108@gmail.com> References: <20260401111748.106970-1-krishna.chomal108@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" For Victus S devices, the BIOS fan table header was being incorrectly parsed as: struct { u8 unknown; u8 num_entries; } The first field should be num_fans and the second should be unknown. It is pure coincidence that interpreting an "unknown" field as "num_entries" worked on multiple device, however for board 8D87 (in an upcoming patch), this assumption fails, and the hp-wmi driver fails to load. We fix this by correcting the header definition and compensating for num_entries by parsing each entry of the fan table until an all-NULL row is obtained, mirroring the behavior of OMEN Gaming Hub on Windows. Fixes: 46be1453e6e6 ("platform/x86: hp-wmi: add manual fan control for Vict= us S models") Signed-off-by: Krishna Chomal --- drivers/platform/x86/hp/hp-wmi.c | 41 +++++++++++++++++++++++++------- 1 file changed, 33 insertions(+), 8 deletions(-) diff --git a/drivers/platform/x86/hp/hp-wmi.c b/drivers/platform/x86/hp/hp-= wmi.c index 304d9ac63c8a..d630b7f6e146 100644 --- a/drivers/platform/x86/hp/hp-wmi.c +++ b/drivers/platform/x86/hp/hp-wmi.c @@ -433,14 +433,14 @@ struct hp_wmi_hwmon_priv { }; =20 struct victus_s_fan_table_header { + u8 num_fans; u8 unknown; - u8 num_entries; } __packed; =20 struct victus_s_fan_table_entry { u8 cpu_rpm; u8 gpu_rpm; - u8 unknown; + u8 noise_db; } __packed; =20 struct victus_s_fan_table { @@ -2514,7 +2514,9 @@ static int hp_wmi_setup_fan_settings(struct hp_wmi_hw= mon_priv *priv) u8 fan_data[128] =3D { 0 }; struct victus_s_fan_table *fan_table; u8 min_rpm, max_rpm, gpu_delta; - int ret; + u8 cpu_rpm, gpu_rpm, noise_db; + int ret, num_entries, i; + size_t header_size, entry_size; =20 /* Default behaviour on hwmon init is automatic mode */ priv->mode =3D PWM_MODE_AUTO; @@ -2529,13 +2531,36 @@ static int hp_wmi_setup_fan_settings(struct hp_wmi_= hwmon_priv *priv) return ret; =20 fan_table =3D (struct victus_s_fan_table *)fan_data; - if (fan_table->header.num_entries =3D=3D 0 || - sizeof(struct victus_s_fan_table_header) + - sizeof(struct victus_s_fan_table_entry) * fan_table->header.num_entri= es > sizeof(fan_data)) + if (fan_table->header.num_fans =3D=3D 0) + return -EINVAL; + + header_size =3D sizeof(struct victus_s_fan_table_header); + entry_size =3D sizeof(struct victus_s_fan_table_entry); + num_entries =3D (sizeof(fan_data) - header_size) / entry_size; + min_rpm =3D U8_MAX; + max_rpm =3D 0; + + for (i =3D 0 ; i < num_entries ; i++) { + cpu_rpm =3D fan_table->entries[i].cpu_rpm; + gpu_rpm =3D fan_table->entries[i].gpu_rpm; + noise_db =3D fan_table->entries[i].noise_db; + + /* + * On some devices, the fan table is truncated with an all-zero row, + * hence we stop parsing here. + */ + if (cpu_rpm =3D=3D 0 && gpu_rpm =3D=3D 0 && noise_db =3D=3D 0) + break; + + if (cpu_rpm < min_rpm) + min_rpm =3D cpu_rpm; + if (cpu_rpm > max_rpm) + max_rpm =3D cpu_rpm; + } + + if (min_rpm =3D=3D U8_MAX || max_rpm =3D=3D 0) return -EINVAL; =20 - min_rpm =3D fan_table->entries[0].cpu_rpm; - max_rpm =3D fan_table->entries[fan_table->header.num_entries - 1].cpu_rpm; gpu_delta =3D fan_table->entries[0].gpu_rpm - fan_table->entries[0].cpu_r= pm; priv->min_rpm =3D min_rpm; priv->max_rpm =3D max_rpm; --=20 2.53.0 From nobody Wed Apr 1 20:42:55 2026 Received: from mail-pj1-f49.google.com (mail-pj1-f49.google.com [209.85.216.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CE7853EBF20 for ; Wed, 1 Apr 2026 11:18:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.49 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775042300; cv=none; b=VAJ1WtoyevfSMQ71NQeGgs5WdkPDHMXVi4h+WkNgHCH1JjZ86cs3zz4vdsMZxutLmY5RGuzHpWSS+WfEjQXBKyjcrXPnsM4mQ5v1oulPKAFKKrE4lziBw0xDgcsN3Em06mpmcZflkmnNtcCt8PzT+QOXMAB4NUIqzD6UyMvX7fk= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775042300; c=relaxed/simple; bh=Zod/mbmSErAVBnUR2KsmYCmm5vMqxEg4NpW/Yvq/orw=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=VSLFUNj9r/ujtrOd7KaOPtqoX7uu5xq/TMa/SAu1RCsQUXnUu49Pdgv04Y1AHBd7j6MtzkdbM707sM10wJT3L/8Q52DNiGXYURUK5K/Pb1I6VrihfSEG7XLqjeR73eX/6dipmFrloqHgHVZ6K5rQbvohlDsGGr/0gBGrMtRWceQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=jdYypNfo; arc=none smtp.client-ip=209.85.216.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="jdYypNfo" Received: by mail-pj1-f49.google.com with SMTP id 98e67ed59e1d1-35691a231a7so4117677a91.3 for ; Wed, 01 Apr 2026 04:18:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1775042298; x=1775647098; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=XPtxhpt/RdXrwtdWw636aHBwOhySfdQdA4zowFMg+Sw=; b=jdYypNfoCIkPm98oeJe8kh1njMgewTKLRULwVn/5nprcs9KFKJpMsz8H1x/vG+K4lf OxP/3ujyUdHDHuxqEFtgq5whv6cL8HylCluOdCcIx2SKJ7ZVU1JYw2sv/0IDcao8o8ik EbTmTLtJDa+XEOmYbGE5ycA2SxTgdAoQ3UlhD/8AqkoEsTqBSbZaZAZttuDsC1q4B1UQ fZyrjGrUhoOH9cK8xiWlwyFfDdIYj0nqmxYU/vKaee0fJcOF4jrsJgPQdadKYRmX5UdB Guack56ITT9x03kdp5VqHfEsM9APjj2dSy+9WP6YZMOKKFwFbvBZ1rYAqk6ZKX5YXGQY 9ZkA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1775042298; x=1775647098; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=XPtxhpt/RdXrwtdWw636aHBwOhySfdQdA4zowFMg+Sw=; b=o0yUmj1lDRBPz/7kYRCTb+961yTmYdUlnlD/Jq+MOoCfNmW5Ta7mXDKPbH7tZBlFAB UNO3nF47MyohSI4yhAbsesgdGt3JSqpfInO67N45F49oxUafw11rnzS0Sa+ZeyT+u4cl EysBR9Os677NcWH4TH2Hdy8ejSWziLjlWzjAcwu+GL+PtfvO2QLzw/oEU04+m68JiYbK dB5XYbRDM6Z2gUIE27C8aGvNiAupSGuai6lRFzeFws7/kWo0QjPYa6b0rkdkRftWBufW YFSXLMg74+6Fr9NTY/V+b187vK1BKfYyn8k1izobZcTkWW6N8kQ7Mvy+qP6IhERIEtdp CLpQ== X-Forwarded-Encrypted: i=1; AJvYcCUJ6OHxWJqGHkZZYWxh5h1pu5X07arEFmnI6MIetwQ+oy3VnWDznzGfjyjBRgZECiVQIpOg5zD3DigKoaA=@vger.kernel.org X-Gm-Message-State: AOJu0Yy2p1VkeFgxnfXSVnj+8PAlwkXwjxDX7t4eRwT3Nrv74W6KMYTA FJ9vP5Ad1QYJhJ3wMTsncaZNGuO7+ihV+ErDMQGeglXkoUDwSge0c2W/ X-Gm-Gg: ATEYQzxFcKzyoyRVApa208YZjLdtJ8AsWHNZl03YaTGjnL1MyXcxHLE5CSG+dOXKccu qrD+Vbl28rghx1lpvypOel0BE2EkuoReEv3/CSKU93jFue36Q3Nr/z/B+lt0Tv3XaYdfZjNrUHG paUiKvGr6NrBQIVwcgY6h0Tvpt+yfcohrYB2d4v0NoKhqEUTeDn4POyg4DlfZzjOMh6wIrymQUI 6dvMt8681VqRyv3FJhVAFkgszkizKL3gdVjiWe0d0wxBzdlxhHx70CAqpsOvfwMVxzUYur5Ei0A kIFEKFC4pjnmiBDYcGb07/nTzOOQwSZgeI5NjILnYBvofMcvq347Ek/dtQeL4V7VPmAtOVWHX7I INHcxXzMhAsM6ejpYjsLvY5DivbmVUbbV3+gFs/4wAyJu3u0g8vvNiO0FE7R6VGKqBDD/1gSmQG 1X0Hc1nye/F0ow7lU8vDeQHTmSbLr4hUnJO4Qe83aVvZSFmWe9En4p1z0UHZCUd/6xpO5h/WHgv if5XrraTk/URb0O3xel X-Received: by 2002:a17:90b:3e4e:b0:35d:9c43:57fe with SMTP id 98e67ed59e1d1-35dc6e6739emr2907995a91.13.1775042298013; Wed, 01 Apr 2026 04:18:18 -0700 (PDT) Received: from archlinux ([2405:201:1b:225c:eb9d:1fc0:f95c:bd90]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-35dcafd004fsm1889689a91.12.2026.04.01.04.18.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Apr 2026 04:18:17 -0700 (PDT) From: Krishna Chomal To: ilpo.jarvinen@linux.intel.com, hansg@kernel.org Cc: platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, Krishna Chomal , Jinyang Zhu Subject: [PATCH 2/4] platform/x86: hp-wmi: Add support for OMEN MAX 16-ak0xxx (8D87) Date: Wed, 1 Apr 2026 16:47:46 +0530 Message-ID: <20260401111748.106970-3-krishna.chomal108@gmail.com> X-Mailer: git-send-email 2.53.0 In-Reply-To: <20260401111748.106970-1-krishna.chomal108@gmail.com> References: <20260401111748.106970-1-krishna.chomal108@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The HP OMEN MAX 16-ak0xxx (8D87) requires the same WMI queries as other Victus S devices, hence it has been added to the corresponding list. For this reason, platform_profile_victus_s_get_ec() will be called during thermal_profile_setup() and victus_s_powersource_event() to obtain hardware state (platform profile) by reading from the Embedded Controller, however, this particular board's EC does not seem to expose the platform profile value, unlike other boards. Hence EC readback is disabled. Testing on board 8D87 confirmed that platform profile is registered successfully and fan RPMs are readable and controllable. Tested-by: Jinyang Zhu Signed-off-by: Krishna Chomal --- drivers/platform/x86/hp/hp-wmi.c | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/drivers/platform/x86/hp/hp-wmi.c b/drivers/platform/x86/hp/hp-= wmi.c index d630b7f6e146..24164f294420 100644 --- a/drivers/platform/x86/hp/hp-wmi.c +++ b/drivers/platform/x86/hp/hp-wmi.c @@ -48,6 +48,7 @@ MODULE_ALIAS("wmi:5FB7F034-2C63-45E9-BE91-3D44E2C707E4"); =20 enum hp_ec_offsets { HP_EC_OFFSET_UNKNOWN =3D 0x00, + HP_NO_THERMAL_PROFILE_OFFSET =3D 0x01, HP_VICTUS_S_EC_THERMAL_PROFILE_OFFSET =3D 0x59, HP_OMEN_EC_THERMAL_PROFILE_FLAGS_OFFSET =3D 0x62, HP_OMEN_EC_THERMAL_PROFILE_TIMER_OFFSET =3D 0x63, @@ -120,6 +121,13 @@ static const struct thermal_profile_params omen_v1_the= rmal_params =3D { .ec_tp_offset =3D HP_VICTUS_S_EC_THERMAL_PROFILE_OFFSET, }; =20 +static const struct thermal_profile_params omen_v1_no_ec_thermal_params = =3D { + .performance =3D HP_OMEN_V1_THERMAL_PROFILE_PERFORMANCE, + .balanced =3D HP_OMEN_V1_THERMAL_PROFILE_DEFAULT, + .low_power =3D HP_OMEN_V1_THERMAL_PROFILE_DEFAULT, + .ec_tp_offset =3D HP_NO_THERMAL_PROFILE_OFFSET, +}; + /* * A generic pointer for the currently-active board's thermal profile * parameters. @@ -201,6 +209,10 @@ static const struct dmi_system_id victus_s_thermal_pro= file_boards[] __initconst .matches =3D { DMI_MATCH(DMI_BOARD_NAME, "8D41") }, .driver_data =3D (void *)&victus_s_thermal_params, }, + { + .matches =3D { DMI_MATCH(DMI_BOARD_NAME, "8D87") }, + .driver_data =3D (void *)&omen_v1_no_ec_thermal_params, + }, {}, }; =20 @@ -1801,7 +1813,8 @@ static int platform_profile_victus_s_get_ec(enum plat= form_profile_option *profil const struct thermal_profile_params *params; =20 params =3D active_thermal_profile_params; - if (params->ec_tp_offset =3D=3D HP_EC_OFFSET_UNKNOWN) { + if (params->ec_tp_offset =3D=3D HP_EC_OFFSET_UNKNOWN || + params->ec_tp_offset =3D=3D HP_NO_THERMAL_PROFILE_OFFSET) { *profile =3D active_platform_profile; return 0; } @@ -2156,7 +2169,8 @@ static int thermal_profile_setup(struct platform_devi= ce *device) * behaves like a wrapper around active_platform_profile, to avoid using * uninitialized data, we default to PLATFORM_PROFILE_BALANCED. */ - if (active_thermal_profile_params->ec_tp_offset =3D=3D HP_EC_OFFSET_UNKN= OWN) { + if (active_thermal_profile_params->ec_tp_offset =3D=3D HP_EC_OFFSET_UNKN= OWN || + active_thermal_profile_params->ec_tp_offset =3D=3D HP_NO_THERMAL_PRO= FILE_OFFSET) { active_platform_profile =3D PLATFORM_PROFILE_BALANCED; } else { err =3D platform_profile_victus_s_get_ec(&active_platform_profile); --=20 2.53.0 From nobody Wed Apr 1 20:42:55 2026 Received: from mail-pj1-f41.google.com (mail-pj1-f41.google.com [209.85.216.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DB9E33F0746 for ; Wed, 1 Apr 2026 11:18:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.41 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775042304; cv=none; b=Vf57OF3v1AWzPvpukYStoDvacNfE5nSa6JRqEZO9JofZDUBGDxyOzNF8DE2WL2wsB9ZQY188W7eYR3K2CwwoDBgkdY05PZ2bCI6w3uIwVzCm2wnuYjzOFCecT/nxyV1E/fUphXgXiI2pCjlN1ICAopst7CF8w6q5WYGAvxl+GAo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775042304; c=relaxed/simple; bh=zYnHlcvIRBWdtzEm1zTt0FHTgOVyzkD3PEyh8M5t0qg=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=lmubegAT8K3GW6B8WEeJok8dl++bW5kmjJ1kO6khO7lVtYnc30LUuVpoO4DGOyFTce4xTgQgz/ZEfhy67NGgPr/W+t2T1Qt5ju4Bk7Ea9BJUep2MGQ4OjKuIRi4Y5XxvwAhJNC3kBGRJiW0GbTYbQ1NB39r8gmrahIGqCc2V7TI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=rSWQ0rIv; arc=none smtp.client-ip=209.85.216.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="rSWQ0rIv" Received: by mail-pj1-f41.google.com with SMTP id 98e67ed59e1d1-35d99bae2ebso3590471a91.3 for ; Wed, 01 Apr 2026 04:18:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1775042302; x=1775647102; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Y4NqdGeNr4dDBnJSpOJI2C3YLgWGN5SwaW+i/cg94Rw=; b=rSWQ0rIvSejE9Ehv6S1ekiArFHqJxTwvnBEaBvBZQqoef6upChMfFUZ8kyKuoaLLpR nfXrUaFc/UbGDyszlL4CDaq9hCVHS9S0nZ6x7nW1YVtVNY1uLgkQGax47e3x+ykBtUi4 7nbQDkZESFzI9muCxlP5OLKVoQf2iZhkna2EVBel9gNSFXcZIG9R+pH6yd51vupndMry HrSMypdzmXL2IKUYnnQ/VCNjx49m/PFrZRFnAJQHOodTkTD1IgepZ70L6ie5OrjGCM5W UeUXRNeUrsUjiVm4Jfe/35hhusppHF+Skrj8Qn4Dfnq2AoUfyuGcygRagrAA/Mmj9oR1 yPOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1775042302; x=1775647102; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=Y4NqdGeNr4dDBnJSpOJI2C3YLgWGN5SwaW+i/cg94Rw=; b=KPxhODwvuTJnQz8iszlGmsipuxbGeCHODBjZ2+8sbS2KmcE0gAC7t2fUaKU4sITOYZ AVs0XARsnviGgK1z8ztTUdzUMzlruyqM9wX9h+Zii2Y48B1HZlkkQXJuceW06+bcCsXL zES0qdmVG/v1tbB4F3lZTaVzQGh60n5YppQp+ttJ958BZxYH9Ss0nU6reTBrQwhZ000Y ZrtOFRAbB8XFCcdkjb+hF2pQABGZLVrhQhrX3uDJenhj/GrJVQuuHtkmYUYNOj3U3KTW EhqQl+wm/EiCbray6EE6A9tS9FzUwAZU0l9CyNi8W8WIotH8R+FEM6j23oL2U7N/AqtE cIEg== X-Forwarded-Encrypted: i=1; AJvYcCXWedbzdnWkImv03ElCZvY6hbUkPyVOwN07ScAVrYcaVN9U40qtZ9j+OKKgTM6/0Mf+gqi+k6oivnv3nBg=@vger.kernel.org X-Gm-Message-State: AOJu0YxC/8l/+SBAUOUIu0rFDZNPd9RM7sj0wpYoSjhldN2O9hWMM/LP 2v6bJ5RvfC5O4GQiBNOtCqCVcUHM/njtMhf7AUbgHfae7FOF8bXmo1xn X-Gm-Gg: ATEYQzytj7/ipqWiOTTwnh5eQSxrMMBdtsfJXXWWnt8rphMSh0gmuULNT+kPemroxEW /Hyw6VVfeEgmHMgTL0k+QVbQs8FA1djm1NSFfJUrbLXi+xhH9u/0MXZW7TbVNeK7g9vBtMizT0A 4QXCCe1A9YK7bK4X+17lOi4jZnLEFRmvVKp05ZMOJ/yU8vML6Vzd4h5twkIVnmqWxseMywrO2eO IfOYp3T20NasbuamshopGjWJdWmgPsW0L3QULhApVk7XNb17KjOCKfUBW6KCJxC8RR0lGHer+q7 tce3e1RxXB68TGQF+s8pSLDGoGf4hSkEIUdFCMjeirYvhUiKS6wQmgDwlCfZpPdBq+3y2uwSiMf mv8m1QbaCQHibea1+bmLyMnvKdwUQ4M0J7ICzETt0lz5Bd2lmJrkhed6XXyHw4a9Vh4rsbVAtrr 1mpRRPOFVCtMqKDCaY5nMO/cATgQTCRmTbCO+DKYJvjhi6/88SrW+MPQTsGB338WD5QGadxxnw9 WqmacEEBmDU80s/K8qL X-Received: by 2002:a17:90b:3508:b0:35c:1c77:fac8 with SMTP id 98e67ed59e1d1-35dc6fbad7fmr2914367a91.30.1775042302288; Wed, 01 Apr 2026 04:18:22 -0700 (PDT) Received: from archlinux ([2405:201:1b:225c:eb9d:1fc0:f95c:bd90]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-35dcafd004fsm1889689a91.12.2026.04.01.04.18.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Apr 2026 04:18:22 -0700 (PDT) From: Krishna Chomal To: ilpo.jarvinen@linux.intel.com, hansg@kernel.org Cc: platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, Krishna Chomal , Prasoon Dev Subject: [PATCH 3/4] platform/x86: hp-wmi: Add support for Omen 16-n0xxx (8A44) Date: Wed, 1 Apr 2026 16:47:47 +0530 Message-ID: <20260401111748.106970-4-krishna.chomal108@gmail.com> X-Mailer: git-send-email 2.53.0 In-Reply-To: <20260401111748.106970-1-krishna.chomal108@gmail.com> References: <20260401111748.106970-1-krishna.chomal108@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The HP Omen 16-n0xxx (board ID: 8A44) has the same WMI interface as other Victus S boards, but requires additional quirks for correctly switching thermal profile. Create a new quirk omen_v1_legacy_thermal_params which allows a board to use Omen V1 thermal values, but rely on the older legacy HP_OMEN_EC_THERMAL_PROFILE_OFFSET. Add the DMI board name to victus_s_thermal_profile_boards[] table and map it to the newly added quirk. Testing on board 8A44 confirmed that platform profile is registered successfully and fan RPMs are readable and controllable. Tested-by: Prasoon Dev Signed-off-by: Krishna Chomal --- drivers/platform/x86/hp/hp-wmi.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/drivers/platform/x86/hp/hp-wmi.c b/drivers/platform/x86/hp/hp-= wmi.c index 24164f294420..3284cf0d74cb 100644 --- a/drivers/platform/x86/hp/hp-wmi.c +++ b/drivers/platform/x86/hp/hp-wmi.c @@ -121,6 +121,13 @@ static const struct thermal_profile_params omen_v1_the= rmal_params =3D { .ec_tp_offset =3D HP_VICTUS_S_EC_THERMAL_PROFILE_OFFSET, }; =20 +static const struct thermal_profile_params omen_v1_legacy_thermal_params = =3D { + .performance =3D HP_OMEN_V1_THERMAL_PROFILE_PERFORMANCE, + .balanced =3D HP_OMEN_V1_THERMAL_PROFILE_DEFAULT, + .low_power =3D HP_OMEN_V1_THERMAL_PROFILE_DEFAULT, + .ec_tp_offset =3D HP_OMEN_EC_THERMAL_PROFILE_OFFSET, +}; + static const struct thermal_profile_params omen_v1_no_ec_thermal_params = =3D { .performance =3D HP_OMEN_V1_THERMAL_PROFILE_PERFORMANCE, .balanced =3D HP_OMEN_V1_THERMAL_PROFILE_DEFAULT, @@ -181,6 +188,10 @@ static const char * const victus_thermal_profile_board= s[] =3D { =20 /* DMI Board names of Victus 16-r and Victus 16-s laptops */ static const struct dmi_system_id victus_s_thermal_profile_boards[] __init= const =3D { + { + .matches =3D { DMI_MATCH(DMI_BOARD_NAME, "8A44") }, + .driver_data =3D (void *)&omen_v1_legacy_thermal_params, + }, { .matches =3D { DMI_MATCH(DMI_BOARD_NAME, "8BBE") }, .driver_data =3D (void *)&victus_s_thermal_params, --=20 2.53.0 From nobody Wed Apr 1 20:42:55 2026 Received: from mail-pj1-f51.google.com (mail-pj1-f51.google.com [209.85.216.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F0E5C3EC2CB for ; Wed, 1 Apr 2026 11:18:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.51 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775042309; cv=none; b=Dm28YeSblbOcCuBlxpHxNxMsEFB44p75w3Nn2hHco5AMBLYXcdnz7hUVJssRE7c44EvvqMbwzquLl3E/HZ/BWYnrAQJqNF2Y6ifDBAbAO8v9fIvdi3eFPtpmkX2tjjYwAfbm7Ose8nkwZ1QgDo6mshdNYVMrpl7ENQoHdKVCZrQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775042309; c=relaxed/simple; bh=bOoGXg+Ptdm+5MGtNztiplrP7obGnl1Ycdm4b0J6M5c=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=k8MeNhLc61NzZ678R84hHr8Uib0Iyzw1rmu4s0DapvusaOSBMC7aiGQIFhUj6aw/Hyi6sjxMRGXDQFMuOJapcsWYxdPpGmupUshJ9W0xdTKN4owp69ZSnFS1DIGemEWKJNWuojQlyooWVhswMXdgTe/9+/Rm9PcI7hux1DpFPew= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=M2MI8B2y; arc=none smtp.client-ip=209.85.216.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="M2MI8B2y" Received: by mail-pj1-f51.google.com with SMTP id 98e67ed59e1d1-3590042fa8eso4497031a91.1 for ; Wed, 01 Apr 2026 04:18:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1775042307; x=1775647107; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=QFbdbNnRPMKcdpjgOezZ2saKnXuNUCW2P7MMIh2Z3Ig=; b=M2MI8B2y0G+91k0XuUbI7MRWvFoB74tAqL9BLwjN+sSqmJXVYbBnvz2wTq5XDguskS VXeZW1TOxv7RvCYjon9RgNG2K/xlVHJ1gDcTVUQ3or/d/BbaMp2BVGtBJuvB99YAn7Vf bqRVJWcZUmGtu63h1OSufzxD48t2muqd4RxsnJQ7pFAkGhz1CWYSVA7u5cjqPJ3j/b9A kumdCAvI7A3E5maJEC4TI8s3dKxaoZVa8bG7X7hk1j99W73W7Fe3WLd6gLtBZHO/nEOa kcbKeY7yj01tAgrJIbSasSQkpM7hab1FjnrmWNCVWWyYvI+DRPDanVoppDi3qUlx6DQm I8VA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1775042307; x=1775647107; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=QFbdbNnRPMKcdpjgOezZ2saKnXuNUCW2P7MMIh2Z3Ig=; b=gEIWWaKqq956nwfuBgIfONc4aJZTMGOFKP6sycX5a6TMN7ONtE/Jc0a0ipwxBWSpIG t3O4l98FTsm6cSLNJlJ9mjJVCjN/4UoseoF4dPatWITBePeb9xwG4k5hB6UORax44YRK DA7Qte4yfgXg2p1WUL27zKblNAi7MvOjXRGd5YW2s0TGRfnwpnl5YagZ2HLKNVNnNlWD KbdpA590XeYW8ZAiLln3+AlUNzVnrN77C9uBDtyiM8emSwNxkoCqebBXCj4jW3BPn/+a 7U025cNLDTB24HERzpnKAPlPt5NBUAzOisFnaVXuj907uKFPZiBo4XC3powEyVE/IOcI OOAg== X-Forwarded-Encrypted: i=1; AJvYcCXMfZPImBYCLdinxtTohGOHifqM/MvIET9hfOWRpChRdy4YJYxEUfGO/5pq2XZAmOw8r/hr3rUffdBhbz0=@vger.kernel.org X-Gm-Message-State: AOJu0Yz5VHWU2iXGoz80h/WfMHG2F+h+V3dPo+uxsI+M5WyLlThCouNM TcyzQQtVEbMVuIl3OvDKmXwKFQHCaXN7Whsp5LjtdkREqSurufiZwn/N X-Gm-Gg: ATEYQzx0QSa2H8IxdlfO7ew1cHNFxKjRCaEte3jy2rrdmUjXWGBGcOVAf56pROjkLRC pRy1+9viwd2fE3SsNMinGYLZ2ukFJPUudFH2s2v90OeKhe0dPhMwXsNqmc25HQHythXeuSXPF8L Mj4lkIUtCtRCX0ysyQbvuVIv7wC1yInBrrgE7w6HHEAHxlmGOE9WfRdb1D4yGmieduxw1Xmu1B6 G8DCOQ0Uwdcq77HbbYNDUBXE5uSk+/XcIqsLWNUTL62JHTkLEBD832ml0lq9VKb4OdWpExByM2w 7cmeJN4HHcbh4Ybdh4uWrUUVv7RueDw2+nNnvdLV+65pbZdB4i/Mq4zq6sX7hJmKcx+PXQMhzhq kwwe/JpQGeKSJDIdKJ80aWiQrA8Q85PW0ClEzeq03pOuVkWlHpPysGTsv8ki+NVV2+NqKGZ60bK UX2WSGwwyjirpp9lnGiUdN+NS1FGcFLaE1oCtl0tY4uOIxYOUnxeC3JqxVHZOqJJ4Pj/dCxKutY mM6YXtQrgs7MHc0YIVT X-Received: by 2002:a17:90b:1a90:b0:35c:30a8:322 with SMTP id 98e67ed59e1d1-35dc6d7e7ebmr3187458a91.0.1775042307146; Wed, 01 Apr 2026 04:18:27 -0700 (PDT) Received: from archlinux ([2405:201:1b:225c:eb9d:1fc0:f95c:bd90]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-35dcafd004fsm1889689a91.12.2026.04.01.04.18.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Apr 2026 04:18:26 -0700 (PDT) From: Krishna Chomal To: ilpo.jarvinen@linux.intel.com, hansg@kernel.org Cc: platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, Krishna Chomal , Thomas Arici Subject: [PATCH 4/4] platform/x86: hp-wmi: Add support for Omen 16-wf1xxx (8C77) Date: Wed, 1 Apr 2026 16:47:48 +0530 Message-ID: <20260401111748.106970-5-krishna.chomal108@gmail.com> X-Mailer: git-send-email 2.53.0 In-Reply-To: <20260401111748.106970-1-krishna.chomal108@gmail.com> References: <20260401111748.106970-1-krishna.chomal108@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The HP Omen 16-wf1xxx (board ID: 8C77) has the same WMI interface as other Victus S boards, but requires quirks for correctly switching thermal profile. Add the DMI board name to victus_s_thermal_profile_boards[] table and map it to omen_v1_thermal_params. Testing on board 8C77 confirmed that platform profile is registered successfully and fan RPMs are readable and controllable. Tested-by: Thomas Arici Reported-by: Thomas Arici Closes: https://bugzilla.kernel.org/show_bug.cgi?id=3D221300 Signed-off-by: Krishna Chomal --- drivers/platform/x86/hp/hp-wmi.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/platform/x86/hp/hp-wmi.c b/drivers/platform/x86/hp/hp-= wmi.c index 3284cf0d74cb..fc1eaf6c3e24 100644 --- a/drivers/platform/x86/hp/hp-wmi.c +++ b/drivers/platform/x86/hp/hp-wmi.c @@ -204,6 +204,10 @@ static const struct dmi_system_id victus_s_thermal_pro= file_boards[] __initconst .matches =3D { DMI_MATCH(DMI_BOARD_NAME, "8BD5") }, .driver_data =3D (void *)&victus_s_thermal_params, }, + { + .matches =3D { DMI_MATCH(DMI_BOARD_NAME, "8C77") }, + .driver_data =3D (void *)&omen_v1_thermal_params, + }, { .matches =3D { DMI_MATCH(DMI_BOARD_NAME, "8C78") }, .driver_data =3D (void *)&omen_v1_thermal_params, --=20 2.53.0