From 3eded9d10d8f8489b2bedb4c560df79e002c201f Mon Sep 17 00:00:00 2001 From: Anas Nashif Date: Fri, 20 Sep 2024 11:59:23 -0400 Subject: [PATCH] soc: intel_ish: remove duplicate hook Remove duplicate hook and fold power code into the same early soc hook. Fixes #78776 Signed-off-by: Anas Nashif --- soc/intel/intel_ish/intel_ish5/pm/power.c | 7 ------- soc/intel/intel_ish/intel_ish5/soc.c | 5 +++++ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/soc/intel/intel_ish/intel_ish5/pm/power.c b/soc/intel/intel_ish/intel_ish5/pm/power.c index 1ad559c3fea..8da03692305 100644 --- a/soc/intel/intel_ish/intel_ish5/pm/power.c +++ b/soc/intel/intel_ish/intel_ish5/pm/power.c @@ -69,10 +69,3 @@ void sys_arch_reboot(int type) sedi_pm_reset(); } #endif - -extern void sedi_pm_init(void); - -void soc_early_init_hook(void) -{ - sedi_pm_init(); -} diff --git a/soc/intel/intel_ish/intel_ish5/soc.c b/soc/intel/intel_ish/intel_ish5/soc.c index 6547b219d4e..488b0aedf89 100644 --- a/soc/intel/intel_ish/intel_ish5/soc.c +++ b/soc/intel/intel_ish/intel_ish5/soc.c @@ -11,9 +11,14 @@ #include "sedi_driver_hpet.h" #endif +extern void sedi_pm_init(void); + void soc_early_init_hook(void) { #if defined(CONFIG_HPET_TIMER) sedi_hpet_set_min_delay(HPET_CMP_MIN_DELAY); #endif +#if defined(CONFIG_PM) + sedi_pm_init(); +#endif }