]> git.sur5r.net Git - u-boot/blobdiff - arch/arm/cpu/armv7/ls102xa/psci.S
SPDX: Convert all of our single license tags to Linux Kernel style
[u-boot] / arch / arm / cpu / armv7 / ls102xa / psci.S
index 8f386800f6c2e74e26f83ef85ed96dfd0acea02a..a36f05c577f20d12a1d96fbe329117cc43c77f3c 100644 (file)
@@ -1,8 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
 /*
  * Copyright 2015 Freescale Semiconductor, Inc.
  * Author: Wang Dongsheng <dongsheng.wang@freescale.com>
- *
- * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #include <config.h>
@@ -29,6 +28,7 @@
 #define PSCI_FN_AFFINITY_INFO_FEATURE_MASK     0x0
 #define PSCI_FN_SYSTEM_OFF_FEATURE_MASK                0x0
 #define PSCI_FN_SYSTEM_RESET_FEATURE_MASK      0x0
+#define PSCI_FN_SYSTEM_SUSPEND_FEATURE_MASK    0x0
 
        .pushsection ._secure.text, "ax"
 
@@ -36,7 +36,7 @@
 
        .align  5
 
-#define        ONE_MS          (GENERIC_TIMER_CLK / 1000)
+#define        ONE_MS          (COUNTER_FREQUENCY / 1000)
 #define        RESET_WAIT      (30 * ONE_MS)
 
 .globl psci_version
@@ -61,6 +61,8 @@ _ls102x_psci_supported_table:
        .word   PSCI_FN_SYSTEM_OFF_FEATURE_MASK
        .word   ARM_PSCI_0_2_FN_SYSTEM_RESET
        .word   PSCI_FN_SYSTEM_RESET_FEATURE_MASK
+       .word   ARM_PSCI_1_0_FN_SYSTEM_SUSPEND
+       .word   PSCI_FN_SYSTEM_SUSPEND_FEATURE_MASK
        .word   0
        .word   ARM_PSCI_RET_NI
 
@@ -243,4 +245,12 @@ psci_system_reset:
 1:     wfi
        b       1b
 
+.globl psci_system_suspend
+psci_system_suspend:
+       push    {lr}
+
+       bl      ls1_system_suspend
+
+       pop     {pc}
+
        .popsection