forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-05-10 9999e48639b3cecb08ffb37358bcba3b48161b29
kernel/arch/x86/kernel/acpi/sleep.c
....@@ -7,13 +7,12 @@
77 */
88
99 #include <linux/acpi.h>
10
-#include <linux/bootmem.h>
1110 #include <linux/memblock.h>
1211 #include <linux/dmi.h>
1312 #include <linux/cpumask.h>
13
+#include <linux/pgtable.h>
1414 #include <asm/segment.h>
1515 #include <asm/desc.h>
16
-#include <asm/pgtable.h>
1716 #include <asm/cacheflush.h>
1817 #include <asm/realmode.h>
1918
....@@ -28,12 +27,23 @@
2827 #endif
2928
3029 /**
30
+ * acpi_get_wakeup_address - provide physical address for S3 wakeup
31
+ *
32
+ * Returns the physical address where the kernel should be resumed after the
33
+ * system awakes from S3, e.g. for programming into the firmware waking vector.
34
+ */
35
+unsigned long acpi_get_wakeup_address(void)
36
+{
37
+ return ((unsigned long)(real_mode_header->wakeup_start));
38
+}
39
+
40
+/**
3141 * x86_acpi_enter_sleep_state - enter sleep state
3242 * @state: Sleep state to enter.
3343 *
3444 * Wrapper around acpi_enter_sleep_state() to be called by assmebly.
3545 */
36
-acpi_status asmlinkage __visible x86_acpi_enter_sleep_state(u8 state)
46
+asmlinkage acpi_status __visible x86_acpi_enter_sleep_state(u8 state)
3747 {
3848 return acpi_enter_sleep_state(state);
3949 }