Skip to content

Commit f00aeb4

Browse files
divin-rajjhedberg
authored andcommitted
soc: fvp_aemv8r: Flash mpu region can't be set in case of no flash
Some platforms do not have flash memory. The flash mpu region cannot be created in case CONFIG_FLASH_SIZE is zero. Signed-off-by: Yanqin Wei <[email protected]> Signed-off-by: Divin Raj <[email protected]>
1 parent 9ee47f2 commit f00aeb4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

soc/arm/fvp_aemv8r/aarch64/arm_mpu_regions.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2021-2023 Arm Limited (or its affiliates). All rights reserved.
2+
* Copyright (c) 2021-2023,2025 Arm Limited (or its affiliates). All rights reserved.
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

@@ -11,12 +11,14 @@
1111

1212
static const struct arm_mpu_region mpu_regions[] = {
1313
/* Region 0 */
14+
#if CONFIG_FLASH_SIZE
1415
MPU_REGION_ENTRY("FLASH_0",
1516
CONFIG_FLASH_BASE_ADDRESS,
1617
CONFIG_FLASH_BASE_ADDRESS +
1718
KB(CONFIG_FLASH_SIZE),
1819
REGION_FLASH_ATTR),
1920

21+
#endif
2022
/* Region 1 zephyr text */
2123
MPU_REGION_ENTRY("SRAM_0",
2224
(uintptr_t)__text_region_start,

0 commit comments

Comments
 (0)