Skip to content

Commit 77bdac7

Browse files
Pavel Nikulinij-intel
authored andcommitted
platform/x86: asus-wmi: Disable OOBE state after resume from hibernation
ASUS firmware resets OOBE state during S4 suspend, so the keyboard blinks during resume from hibernation. This patch disables OOBE state after resume from hibernation. Signed-off-by: Pavel Nikulin <pavel@noa-labs.com> Link: https://lore.kernel.org/r/20250418140706.1691-1-pavel@noa-labs.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
1 parent 246f9bb commit 77bdac7

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

drivers/platform/x86/asus-wmi.c

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,6 +304,7 @@ struct asus_wmi {
304304

305305
u32 kbd_rgb_dev;
306306
bool kbd_rgb_state_available;
307+
bool oobe_state_available;
307308

308309
u8 throttle_thermal_policy_mode;
309310
u32 throttle_thermal_policy_dev;
@@ -1826,7 +1827,7 @@ static int asus_wmi_led_init(struct asus_wmi *asus)
18261827
goto error;
18271828
}
18281829

1829-
if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_OOBE)) {
1830+
if (asus->oobe_state_available) {
18301831
/*
18311832
* Disable OOBE state, so that e.g. the keyboard backlight
18321833
* works.
@@ -4723,6 +4724,7 @@ static int asus_wmi_add(struct platform_device *pdev)
47234724
asus->egpu_enable_available = asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_EGPU);
47244725
asus->dgpu_disable_available = asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_DGPU);
47254726
asus->kbd_rgb_state_available = asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_TUF_RGB_STATE);
4727+
asus->oobe_state_available = asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_OOBE);
47264728
asus->ally_mcu_usb_switch = acpi_has_method(NULL, ASUS_USB0_PWR_EC0_CSEE)
47274729
&& dmi_check_system(asus_ally_mcu_quirk);
47284730

@@ -4970,6 +4972,13 @@ static int asus_hotk_restore(struct device *device)
49704972
}
49714973
if (!IS_ERR_OR_NULL(asus->kbd_led.dev))
49724974
kbd_led_update(asus);
4975+
if (asus->oobe_state_available) {
4976+
/*
4977+
* Disable OOBE state, so that e.g. the keyboard backlight
4978+
* works.
4979+
*/
4980+
asus_wmi_set_devstate(ASUS_WMI_DEVID_OOBE, 1, NULL);
4981+
}
49734982

49744983
if (asus_wmi_has_fnlock_key(asus))
49754984
asus_wmi_fnlock_update(asus);

0 commit comments

Comments
 (0)