Commit 30169249 authored by Yuri Tikhonov's avatar Yuri Tikhonov

RM-1156 stm32f7: disable embedded Flash caching upon boot

This is to be able to program it in Linux wout necessity to reconfigure
MPU.
Signed-off-by: default avatarYuri Tikhonov <yur@emcraft.com>
parent d2734675
...@@ -708,6 +708,7 @@ int do_bootm (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) ...@@ -708,6 +708,7 @@ int do_bootm (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
#if defined(CONFIG_STM32F7_DCACHE_ON) && defined(CONFIG_STM32F7_ICACHE_ON) #if defined(CONFIG_STM32F7_DCACHE_ON) && defined(CONFIG_STM32F7_ICACHE_ON)
stm32f7_cache_sync_range(images.os.load, stm32f7_cache_sync_range(images.os.load,
images.os.load + images.os.image_len); images.os.load + images.os.image_len);
stm32f7_envm_as_dev();
#endif #endif
boot_fn(0, argc, argv, &images); boot_fn(0, argc, argv, &images);
......
...@@ -64,9 +64,4 @@ unsigned int ...@@ -64,9 +64,4 @@ unsigned int
void envm_config(u32 wait_states); void envm_config(u32 wait_states);
#endif /* CONFIG_SYS_STM32 */ #endif /* CONFIG_SYS_STM32 */
#if defined(CONFIG_STM32F7_DCACHE_ON) || defined(CONFIG_STM32F7_ICACHE_ON)
void stm32f7_envm_as_dev(void);
void stm32f7_envm_as_mem(void);
#endif
#endif /* __ENVM_H__ */ #endif /* __ENVM_H__ */
...@@ -23,6 +23,8 @@ ...@@ -23,6 +23,8 @@
#include <common.h> #include <common.h>
#include <errno.h> #include <errno.h>
#include <asm/cache.h>
#include "envm.h" #include "envm.h"
/* /*
......
...@@ -34,6 +34,9 @@ ...@@ -34,6 +34,9 @@
* a memory region, and will be executed. * a memory region, and will be executed.
*/ */
void stm32f7_cache_sync_range(u32 s, u32 e); void stm32f7_cache_sync_range(u32 s, u32 e);
void stm32f7_envm_as_dev(void);
void stm32f7_envm_as_mem(void);
#endif #endif
/* /*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment