s7d: suspend in uboot 2023 [1/1]

PD#SWPL-168291

Problem:
Add suspend function in u-boot.

Solution:
Add code.

Verify:
s7d_BM201

Change-Id: I919c8c41efa1b028786c6fdb88817e7007dd03c2
Signed-off-by: Jianyi Shi <jianyi.shi@amlogic.com>
diff --git a/cmd/amlogic/cmd_reboot.c b/cmd/amlogic/cmd_reboot.c
index 267ff4c..cab8daf 100644
--- a/cmd/amlogic/cmd_reboot.c
+++ b/cmd/amlogic/cmd_reboot.c
@@ -13,6 +13,7 @@
 #include <amlogic/storage.h>
 #include <asm/amlogic/arch/cpu_config.h>
 #include <asm/amlogic/arch/stick_mem.h>
+#include <amlogic/pm.h>
 /*
 run get_rebootmode  //set reboot_mode env with current mode
 */
@@ -332,3 +333,13 @@
 	"system off ",
 	"systemoff "
 );
+
+int do_systemsuspend(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
+{
+	pm_suspend();
+	return 0;
+}
+
+U_BOOT_CMD(systemsuspend, 2, 1,	do_systemsuspend,
+	"system suspend ", "systemsuspend ");
+