soc: arm: remove redundant cache config options for kv5x
Remove the redundant cache config options for kv5x and use the sys_cache* functions to enable the caches. This will automatically consider CONFIG_CACHE_MANAGEMENT. Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
This commit is contained in:
parent
d992683db5
commit
1f1b430d88
|
@ -57,12 +57,4 @@ config SOC_PART_NUMBER_KINETIS_KV5X
|
|||
number selection choice defines the default value for this
|
||||
string.
|
||||
|
||||
config KINETIS_KV5X_ENABLE_CODE_CACHE
|
||||
bool "Code cache"
|
||||
default y
|
||||
|
||||
config KINETIS_KV5X_ENABLE_DATA_CACHE
|
||||
bool "Data cache"
|
||||
default y
|
||||
|
||||
endif # SOC_SERIES_KINETIS_KV5X
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
#include <zephyr/kernel.h>
|
||||
#include <zephyr/device.h>
|
||||
#include <zephyr/init.h>
|
||||
#include <zephyr/cache.h>
|
||||
#include <fsl_common.h>
|
||||
#include <fsl_clock.h>
|
||||
|
||||
|
@ -90,14 +91,8 @@ static int kv5x_init(void)
|
|||
/* Initialize system clocks and PLL */
|
||||
clk_init();
|
||||
|
||||
#ifndef CONFIG_KINETIS_KV5X_ENABLE_CODE_CACHE
|
||||
/* SystemInit will have enabled the code cache. Disable it here */
|
||||
SCB_DisableICache();
|
||||
#endif
|
||||
#ifndef CONFIG_KINETIS_KV5X_ENABLE_DATA_CACHE
|
||||
/* SystemInit will have enabled the data cache. Disable it here */
|
||||
SCB_DisableDCache();
|
||||
#endif
|
||||
sys_cache_instr_enable();
|
||||
sys_cache_data_enable();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue