Skip to content

Commit b512f71

Browse files
committed
Merge tag 'acpi-5.1-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull ACPI fix from Rafael Wysocki: "Prevent stale GPE events from triggering spurious system wakeups from suspend-to-idle (Furquan Shaikh)" * tag 'acpi-5.1-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPICA: Clear status of GPEs before enabling them
2 parents 9db6ce4 + b59fb7e commit b512f71

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

drivers/acpi/acpica/evgpe.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,12 @@ acpi_status acpi_ev_enable_gpe(struct acpi_gpe_event_info *gpe_event_info)
8181

8282
ACPI_FUNCTION_TRACE(ev_enable_gpe);
8383

84-
/* Enable the requested GPE */
84+
/* Clear the GPE status */
85+
status = acpi_hw_clear_gpe(gpe_event_info);
86+
if (ACPI_FAILURE(status))
87+
return_ACPI_STATUS(status);
8588

89+
/* Enable the requested GPE */
8690
status = acpi_hw_low_set_gpe(gpe_event_info, ACPI_GPE_ENABLE);
8791
return_ACPI_STATUS(status);
8892
}

0 commit comments

Comments
 (0)