source: rtems/bsps/arm/lpc24xx/start/start-config-mpu.c @ d49ff3e

Last change on this file since d49ff3e was d49ff3e, checked in by Sebastian Huber <sebastian.huber@…>, on May 8, 2019 at 11:02:04 AM

bsp/lpc24xx: LPC24XX_EMC_MT48LC4M16A2 MPU support

  • Property mode set to 100644
File size: 2.2 KB
Line 
1/**
2 * @file
3 *
4 * @ingroup RTEMSBSPsARMLPC24XX
5 *
6 * @brief BSP start MPU configuration.
7 */
8
9/*
10 * Copyright (c) 2011, 2019 embedded brains GmbH.  All rights reserved.
11 *
12 *  embedded brains GmbH
13 *  Dornierstr. 4
14 *  82178 Puchheim
15 *  Germany
16 *  <rtems@embedded-brains.de>
17 *
18 * The license and distribution terms for this file may be
19 * found in the file LICENSE in this distribution or at
20 * http://www.rtems.org/license/LICENSE.
21 */
22
23#include <bsp/start-config.h>
24
25#ifdef ARM_MULTILIB_ARCH_V7M
26  BSP_START_DATA_SECTION const ARMV7M_MPU_Region
27    lpc24xx_start_config_mpu_region [] = {
28      #if defined(LPC24XX_EMC_IS42S32800D7) \
29        || defined(LPC24XX_EMC_W9825G2JB75I) \
30        || defined(LPC24XX_EMC_IS42S32800B)
31        ARMV7M_MPU_REGION_INITIALIZER(
32          0,
33          0x00000000,
34          ARMV7M_MPU_SIZE_512_KB,
35          ARMV7M_MPU_ATTR_RX
36        ),
37        ARMV7M_MPU_REGION_INITIALIZER(
38          1,
39          0x10000000,
40          ARMV7M_MPU_SIZE_64_KB,
41          ARMV7M_MPU_ATTR_RWX
42        ),
43        ARMV7M_MPU_REGION_INITIALIZER(
44          2,
45          0x20000000,
46          ARMV7M_MPU_SIZE_32_KB,
47          ARMV7M_MPU_ATTR_RWX
48        ),
49        ARMV7M_MPU_REGION_INITIALIZER(
50          3,
51          0xa0000000,
52#if defined(LPC24XX_EMC_MT48LC4M16A2)
53          ARMV7M_MPU_SIZE_8_MB,
54#else
55          ARMV7M_MPU_SIZE_32_MB,
56#endif
57          ARMV7M_MPU_ATTR_RWX
58        ),
59        ARMV7M_MPU_REGION_INITIALIZER(
60          4,
61          0x20080000,
62          ARMV7M_MPU_SIZE_128_KB,
63          ARMV7M_MPU_ATTR_IO
64        ),
65        ARMV7M_MPU_REGION_INITIALIZER(
66          5,
67          0x40000000,
68          ARMV7M_MPU_SIZE_1_MB,
69          ARMV7M_MPU_ATTR_IO
70        ),
71        #if defined(LPC24XX_EMC_M29W320E70) \
72          || defined(LPC24XX_EMC_SST39VF3201)
73          ARMV7M_MPU_REGION_INITIALIZER(
74            6,
75            0x80000000,
76            ARMV7M_MPU_SIZE_4_MB,
77            ARMV7M_MPU_ATTR_RWX
78          ),
79        #else
80          ARMV7M_MPU_REGION_DISABLED_INITIALIZER(6),
81        #endif
82        ARMV7M_MPU_REGION_DISABLED_INITIALIZER(7)
83     #endif
84  };
85
86  BSP_START_DATA_SECTION const size_t
87    lpc24xx_start_config_mpu_region_count =
88      sizeof(lpc24xx_start_config_mpu_region)
89        / sizeof(lpc24xx_start_config_mpu_region [0]);
90#endif
Note: See TracBrowser for help on using the repository browser.