lib: utils/suspend: restore Andes CSRs on system-suspend resume

A deep sleep resume leaves the boot hart in SUSPENDED state, so
init_warmboot() dispatches to init_warm_resume(), which calls the SUSP
device's system_resume callback and not sbi_platform_early_init(). The
restore in ae350_early_init() is dead code on that path.

Fixes: b27ecec76b ("lib: utils/suspend: add Andes ATCSMU suspend driver")
Signed-off-by: Ben Zong-You Xie <ben717@andestech.com>
Reviewed-by: Anup Patel <anup@brainfault.org>
Link: https://lore.kernel.org/r/20260728081041.2724668-5-ben717@andestech.com
Signed-off-by: Anup Patel <anup@brainfault.org>
This commit is contained in:
Ben Zong-You Xie
2026-09-01 10:46:23 +05:30
committed by Anup Patel
parent 733867c0c8
commit 9ceaf4738a
+3 -1
View File
@@ -91,8 +91,10 @@ static void ae350_system_resume(void)
u32 hartid = current_hartid();
u32 sleep_type = atcsmu_get_sleep_type(hartid);
if (sleep_type == SBI_SUSP_SLEEP_TYPE_SUSPEND)
if (sleep_type == SBI_SUSP_SLEEP_TYPE_SUSPEND) {
fdt_cmo_llc_enable(true);
ae350_non_ret_restore(sbi_scratch_thishart_ptr());
}
}
static struct sbi_system_suspend_device suspend_andes_atcsmu = {