@@ -190,6 +190,8 @@ static struct sbi_system_reset_device pm_reset = {
.system_reset = pm_system_reset
};
+static int starfive_jh7110_inst_init(void *fdt);
+
static int pm_reset_init(void *fdt, int nodeoff,
const struct fdt_match *match)
{
@@ -215,6 +217,10 @@ static int pm_reset_init(void *fdt, int nodeoff,
pmic_inst.adapter = adapter;
+ rc = starfive_jh7110_inst_init(fdt);
+ if (rc)
+ return rc;
+
sbi_system_reset_add_device(&pm_reset);
return 0;
@@ -278,7 +284,6 @@ static int starfive_jh7110_final_init(bool cold_boot,
if (cold_boot) {
fdt_reset_driver_init(fdt, &fdt_reset_pmic);
- return starfive_jh7110_inst_init(fdt);
}
return 0;