forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-31 f70575805708cabdedea7498aaa3f710fde4d920
kernel/drivers/acpi/acpica/hwsleep.c
....@@ -4,7 +4,7 @@
44 * Name: hwsleep.c - ACPI Hardware Sleep/Wake Support functions for the
55 * original/legacy sleep/PM registers.
66 *
7
- * Copyright (C) 2000 - 2018, Intel Corp.
7
+ * Copyright (C) 2000 - 2020, Intel Corp.
88 *
99 *****************************************************************************/
1010
....@@ -299,6 +299,18 @@
299299 [ACPI_EVENT_POWER_BUTTON].
300300 status_register_id, ACPI_CLEAR_STATUS);
301301
302
+ /* Enable sleep button */
303
+
304
+ (void)
305
+ acpi_write_bit_register(acpi_gbl_fixed_event_info
306
+ [ACPI_EVENT_SLEEP_BUTTON].
307
+ enable_register_id, ACPI_ENABLE_EVENT);
308
+
309
+ (void)
310
+ acpi_write_bit_register(acpi_gbl_fixed_event_info
311
+ [ACPI_EVENT_SLEEP_BUTTON].
312
+ status_register_id, ACPI_CLEAR_STATUS);
313
+
302314 acpi_hw_execute_sleep_method(METHOD_PATHNAME__SST, ACPI_SST_WORKING);
303315 return_ACPI_STATUS(status);
304316 }