Commit 3af24f88 authored by Anas Nashif's avatar Anas Nashif Committed by Henrik Brix Andersen
Browse files

soc: arm: move init code from SYS_INIT to hooks



Replace SYS_INIT with SoC hooks and adapt SoC init code

Signed-off-by: default avatarAnas Nashif <anas.nashif@intel.com>
parent da118b9f
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -8,3 +8,4 @@ config SOC_SERIES_BEETLE
	select CPU_CORTEX_M3
	select CPU_HAS_ARM_MPU
	select CPU_CORTEX_M_HAS_DWT
	select SOC_EARLY_INIT_HOOK
+1 −11
Original line number Diff line number Diff line
@@ -21,19 +21,9 @@
 * @brief Perform basic hardware initialization at boot.
 *
 * This needs to be run from the very beginning.
 * So the init priority has to be 0 (zero).
 *
 * Assumption:
 * MAINCLK = 24Mhz
 *
 * @return 0
 */
static int arm_beetle_init(void)
void soc_early_init_hook(void)
{
	/* Setup various clocks and wakeup sources */
	soc_power_init();

	return 0;
}

SYS_INIT(arm_beetle_init, PRE_KERNEL_1, 0);