mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-10 23:24:38 +00:00
] fix monitor protection for CONFIG_MONITOR_IS_IN_RAM
For platforms with flash below ram addresses, the current check to activate monitor protection is wrong/insufficient. This patch fixes CONFIG_MONITOR_IS_IN_RAM for these systems by adding a check for this configuration. Signed-off-by: Wolfgang Wegner <w.wegner@astro-kom.de> Signed-off-by: Stefan Roese <sr@denx.de>
This commit is contained in:
parent
f3651764e5
commit
8f9a221045
1 changed files with 2 additions and 1 deletions
|
@ -1980,7 +1980,8 @@ unsigned long flash_init (void)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Monitor protection ON by default */
|
/* Monitor protection ON by default */
|
||||||
#if (CONFIG_SYS_MONITOR_BASE >= CONFIG_SYS_FLASH_BASE)
|
#if (CONFIG_SYS_MONITOR_BASE >= CONFIG_SYS_FLASH_BASE) && \
|
||||||
|
(!defined(CONFIG_MONITOR_IS_IN_RAM))
|
||||||
flash_protect (FLAG_PROTECT_SET,
|
flash_protect (FLAG_PROTECT_SET,
|
||||||
CONFIG_SYS_MONITOR_BASE,
|
CONFIG_SYS_MONITOR_BASE,
|
||||||
CONFIG_SYS_MONITOR_BASE + monitor_flash_len - 1,
|
CONFIG_SYS_MONITOR_BASE + monitor_flash_len - 1,
|
||||||
|
|
Loading…
Reference in a new issue