From nobody Sun Feb 8 21:41:46 2026 Received: from mail-wm1-f52.google.com (mail-wm1-f52.google.com [209.85.128.52]) (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 644242D8391 for ; Tue, 6 Jan 2026 22:10:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767737403; cv=none; b=LTA0eJrNEcs904EwiCOnf1Mqs3/yHiI4V4qa7Ul5Qku95HAO58uADmzilqAQAo/tJ1cxiRbGejPv/41Akg5qTXI7/98AkX6E61TJjBdmODxhkMPygtxGFz3xiv8lMdcsS3t75fM2QyoPObEV0ZVV/bpuolPCHB5y/teiZXFokz4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767737403; c=relaxed/simple; bh=fcpMvtgMT7GoElBxsRwGvsS1wELaQReb4mwUGcCWNKA=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=QgcLEP+WTKXeiWpLIpgENIeQxWJARNiwKClMayUuWL/Y6nhAhtAAsv55ThprhTQXdLtCtgjvZnU39A+DlYtRJwUooh89FfyYXH/iMqvIf9aTOVyA3If/XCUrOcelOHRGyFZKAy1lQNzdSr7aYS93OCijQS+UG3kygo2mxfPpTo8= 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=LylHG7Du; arc=none smtp.client-ip=209.85.128.52 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="LylHG7Du" Received: by mail-wm1-f52.google.com with SMTP id 5b1f17b1804b1-47d1d8a49f5so9792525e9.3 for ; Tue, 06 Jan 2026 14:10:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1767737399; x=1768342199; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=+cRDnYnmJsvW4e1q+MXOokUh4bw3J2LGrswV3roVx3Q=; b=LylHG7Dud82FNIzSYjmOXVNFA7KFXdbfEdu6zDscjBWZ9uA7V/S1WiNBqQXmh/6wne dQxyejJhQIzqQjwfj7wn6NNcvtgOZzIYYGYwSpxHHhusKbHkFVn1qkL+uow1d0lxL0WY KGk2NKBwYNQPVZYBZIzwVTo9nW7eP3iMDGscWGTv44pnL9zTQDot4OnbfM+S1xQcWIaF azISCCkrHlbJadqbdsy2s+QFjlIPjHws6OJ/QFkew1IPrwFRNFOzJ0lzbFuXAjpVQYSc vJyol4IQ6tOASNJ+5okTzJmU4dnjMCbdLSv1J+KYXbI2nZfBBOhK8Oaz8ZZnDSyfXbLB Flnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1767737399; x=1768342199; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=+cRDnYnmJsvW4e1q+MXOokUh4bw3J2LGrswV3roVx3Q=; b=r2da/iCjCaIcCHSCRZiPf5VMwOrPEVtBXxWU6wFYyRWR/IshFB7J+aRTGz+w1DSOUZ VsTnmD7eKB2bIoNL5dw+Hj3mxJMVoiHmV08h96oO6KfkHV1LKSQ2TVdnLR6q5L7mOd01 +cTGONT8BEakcADoBHfd15uOm41zMMD/KzrABeVJAGQcMlInHM+fCmXy6KuL9rV41lg+ vk+8LXDcOf8OdGZiMlnCyaeunmIooIDLYFni70rlu9uWjX2Licb2dduzB4PvDzDMRG3G e2AOx6X5x0aV+FupyLxG5wlLhDcTQZq3f85NR09B+G6t5cPr1jGo7/H2HisJ/lmRkzBv AHlA== X-Forwarded-Encrypted: i=1; AJvYcCX4Vj5VmIWfPhCwEuBk8a6NJX4P11lsODmarqzJmPIN9FcpDRNf4qpfiqTeTOULdqawscfMXA52QV66bYA=@vger.kernel.org X-Gm-Message-State: AOJu0YzchaQ99EmFDmdy9ctJ7HClYpkCddrFHva4bxelljm8RKIy2UNf l/aAHXjVN5KXGpOPIpEocD/M1vrJSsZwXIW3ljWb2r4jBya67yBVUcTY X-Gm-Gg: AY/fxX7KbbVeFgJpjJtfXwV9vNigCweSXQcA9tZC9PwBBhhBIvNbJBwQ6p59x0NuiMO LPqZ+5vNYzroTUdo4MgbahAhm+p99XHme22hTjyuj6A5FSv+TMdYK1xzuEbdAuRKgCd0WcScOo/ 9GgKqDSrlqWkY1T20h+ixz3HeYlyU/xFwSwqAdCf8louL+KmWgl6YxY7AOYNWVC+edUwuYLGDIo IUcbtF/s02J/Ooawflp3QWZSAwmDlMwx+Cq02ra0kBimGzT5N0gBheUmWKelGu7yBsfaCcg1H0N BSpSAgyySAGyQAlOWKGs9VN3+AayWGbgWrrWWaE2VchaEJEtxR2S5YmvDiT4PNnidjaZuXB/8pn /BadTDacc14DRzGxSUcUOhbPPyCA7pIDt977Zim+b/zUxY1f9YqBm7gPNm8ilIkZHKUcq8nuTw+ B+A5mnpiMZjREkF2lyZaPuwjY= X-Google-Smtp-Source: AGHT+IHhwoKp4RkDXTHMKIODD167WvWfZ/h+Pfk1tlTSu3x6t/rvj9cOZ56e6qcWKOcadGkrJZ/usg== X-Received: by 2002:a05:600c:8b52:b0:477:abea:9028 with SMTP id 5b1f17b1804b1-47d84b1a348mr3616395e9.6.1767737399415; Tue, 06 Jan 2026 14:09:59 -0800 (PST) Received: from jakob-laptop ([213.55.186.25]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47d7f668e03sm65572525e9.14.2026.01.06.14.09.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Jan 2026 14:09:59 -0800 (PST) From: Jakob X-Google-Original-From: Jakob To: mpearson-lenovo@squebb.ca, derekjohn.clark@gmail.com, ikepanhc@gmail.com, hansg@kernel.org, ilpo.jarvinen@linux.intel.com Cc: platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, Jakob Subject: [PATCH v1] platform/x86: ideapad-laptop: Fix resume behavior for Lenovo Yoga 15ILL9 Date: Tue, 6 Jan 2026 23:09:49 +0100 Message-ID: <20260106220949.1518571-1-jriemenschne@student.ethz.ch> X-Mailer: git-send-email 2.52.0 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" On the Lenovo Yoga Slim 7 15ILL9, the Embedded Controller fails to restore its state after resuming from suspend. This results in the cooling fans remaining stopped (causing overheating), the keyboard backlight and brightness keys becoming unresponsive, and the power button LED continuing to pulse as if still suspended. Testing shows that invoking the UPHK method with command 0x09 properly resets the EC state. This single command restores fan control, fixes the keyboard backlight and brightness keys and corrects the power LED behavior. This patch adds a DMI quirk to invoke this method on resume. Note: On this model, UPHK is located at \_SB.PC00.LPCB.EC0.UPHK rather than the standard VPC2004 device, so we access it via its absolute path. Closes: https://bugzilla.kernel.org/show_bug.cgi?id=3D220505 Signed-off-by: Jakob --- drivers/platform/x86/lenovo/ideapad-laptop.c | 56 ++++++++++++++++++++ 1 file changed, 56 insertions(+) diff --git a/drivers/platform/x86/lenovo/ideapad-laptop.c b/drivers/platfor= m/x86/lenovo/ideapad-laptop.c index 5171a077f..c9fec590a 100644 --- a/drivers/platform/x86/lenovo/ideapad-laptop.c +++ b/drivers/platform/x86/lenovo/ideapad-laptop.c @@ -43,6 +43,7 @@ #include =20 #define IDEAPAD_RFKILL_DEV_NUM 3 +#define IDEAPAD_EC_UPHK_PATH "\\_SB.PC00.LPCB.EC0.UPHK" =20 enum { CFG_CAP_BT_BIT =3D 16, @@ -105,6 +106,10 @@ enum { SALS_FNLOCK_OFF =3D 0xf, }; =20 +enum { + UPHK_FAN_RESUME =3D 0x9, +}; + enum { VPCCMD_R_VPC1 =3D 0x10, VPCCMD_R_BL_MAX, @@ -198,6 +203,7 @@ struct ideapad_private { bool ctrl_ps2_aux_port : 1; bool usb_charging : 1; bool ymc_ec_trigger : 1; + bool fan_mode_fix : 1; } features; struct { bool initialized; @@ -246,6 +252,12 @@ MODULE_PARM_DESC(touchpad_ctrl_via_ec, "Enable registering a 'touchpad' sysfs-attribute which can be used to man= ually " "tell the EC to enable/disable the touchpad. This may not work on all mod= els."); =20 +static bool fan_mode_fix; +module_param(fan_mode_fix, bool, 0444); +MODULE_PARM_DESC(fan_mode_fix, + "Enable fan-mode resume fix for laptops that stop cooling after sleep. " + "If you need this please report this to: platform-driver-x86@vger.kernel.= org"); + static bool ymc_ec_trigger __read_mostly; module_param(ymc_ec_trigger, bool, 0444); MODULE_PARM_DESC(ymc_ec_trigger, @@ -2022,6 +2034,24 @@ static const struct dmi_system_id hw_rfkill_list[] = =3D { {} }; =20 +/* + * On the Lenovo Yoga Slim 15ILL9, the EC fails to restore the fan control= profile after + * resuming from suspend, causing the fans to stop working. + * On this model, the driver needs to explicitly reset the fan mode + * on resume. + * See https://bugzilla.kernel.org/show_bug.cgi?id=3D220505 + */ +static const struct dmi_system_id fan_mode_fix_list[] =3D { + { + /* Lenovo Yoga Slim 7 15ILL9 */ + .matches =3D { + DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"), + DMI_MATCH(DMI_PRODUCT_NAME, "83HM"), + }, + }, + {} +}; + /* * On some models the EC toggles the touchpad muted LED on touchpad toggle * hotkey presses, but the EC does not actually disable the touchpad itsel= f. @@ -2185,6 +2215,8 @@ static int ideapad_check_features(struct ideapad_priv= ate *priv) priv->features.touchpad_ctrl_via_ec =3D touchpad_ctrl_via_ec; priv->features.ymc_ec_trigger =3D ymc_ec_trigger || dmi_check_system(ymc_ec_trigger_quirk_dmi_table); + priv->features.fan_mode_fix =3D + fan_mode_fix || dmi_check_system(fan_mode_fix_list); =20 if (!read_ec_data(handle, VPCCMD_R_FAN, &val)) priv->features.fan_mode =3D true; @@ -2517,6 +2549,28 @@ static void ideapad_acpi_remove(struct platform_devi= ce *pdev) ideapad_debugfs_exit(priv); } =20 +static void ideapad_fan_mode_fix(struct ideapad_private *priv) +{ + acpi_handle handle; + acpi_status status; + + if (!priv->features.fan_mode_fix) + return; + + status =3D acpi_get_handle(NULL, IDEAPAD_EC_UPHK_PATH, &handle); + if (ACPI_FAILURE(status)) { + dev_warn(&priv->platform_device->dev, "Could not find UPHK method for fa= n fix\n"); + return; + } + + status =3D acpi_execute_simple_method(handle, NULL, UPHK_FAN_RESUME); + if (ACPI_FAILURE(status)) { + dev_warn(&priv->platform_device->dev, "Failed to execute UPHK fix: %s\n", + acpi_format_exception(status)); + return; + } +} + #ifdef CONFIG_PM_SLEEP static int ideapad_acpi_resume(struct device *dev) { @@ -2528,6 +2582,8 @@ static int ideapad_acpi_resume(struct device *dev) if (priv->dytc) dytc_profile_refresh(priv); =20 + ideapad_fan_mode_fix(priv); + return 0; } #endif --=20 2.52.0