Browse Source

soc: andestech: move init code from SYS_INIT to hooks

Replace SYS_INIT with SoC hooks and adapt SoC init code

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
pull/78767/head
Anas Nashif 10 months ago committed by Henrik Brix Andersen
parent
commit
da118b9f24
  1. 1
      soc/andestech/ae350/Kconfig
  2. 6
      soc/andestech/ae350/pma.c

1
soc/andestech/ae350/Kconfig

@ -91,6 +91,7 @@ config SOC_ANDES_V5_EXECIT
config SOC_ANDES_V5_PMA config SOC_ANDES_V5_PMA
bool "Andes V5 Physical Memory Attribute (PMA)" bool "Andes V5 Physical Memory Attribute (PMA)"
select ARCH_HAS_NOCACHE_MEMORY_SUPPORT select ARCH_HAS_NOCACHE_MEMORY_SUPPORT
select SOC_EARLY_INIT_HOOK
help help
This option enables the Andes V5 PMA, in order to support SW to This option enables the Andes V5 PMA, in order to support SW to
configure physical memory attribute by PMA CSRs. The address configure physical memory attribute by PMA CSRs. The address

6
soc/andestech/ae350/pma.c

@ -201,7 +201,7 @@ void pma_init_per_core(void)
#endif /* CONFIG_NOCACHE_MEMORY */ #endif /* CONFIG_NOCACHE_MEMORY */
} }
static int pma_init(void) void soc_early_init_hook(void)
{ {
unsigned long mmsc_cfg; unsigned long mmsc_cfg;
@ -220,8 +220,4 @@ static int pma_init(void)
} }
pma_init_per_core(); pma_init_per_core();
return 0;
} }
SYS_INIT(pma_init, PRE_KERNEL_2, CONFIG_KERNEL_INIT_PRIORITY_DEFAULT);

Loading…
Cancel
Save