Skip to content

Commit 030e766

Browse files
gbrtthaggarg
andauthored
M85 support (#556)
* Extend support to Arm Cortex-M85 Signed-off-by: Gabor Toth <gabor.toth@arm.com> Change-Id: I679ba8e193638126b683b651513f08df445f9fe6 * Add generated Cortex-M85 support files Signed-off-by: Gabor Toth <gabor.toth@arm.com> Change-Id: Ib329d88623c2936ffe3e9a24f5d6e07655e4e5c8 * Extend Trusted Firmware M port Extend Trusted Firmware M port to Cortex-M23, Cortex-M55 and Cortex-M85. Signed-off-by: Gabor Toth <gabor.toth@arm.com> Change-Id: If8f1081acfd04e547b3227579e70e355a6adffe3 * Re-run copy_files.py script Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com> Signed-off-by: Gabor Toth <gabor.toth@arm.com> Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com> Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com> Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
1 parent c09187e commit 030e766

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+11249
-17
lines changed

portable/ARMv8M/ReadMe.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
This directory tree contains the master copy of the FreeeRTOS Armv8-M and
22
Armv8.1-M ports.
33
Do not use the files located here! These file are copied into separate
4-
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55]_NNN directories prior to each
4+
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55|85]_NNN directories prior to each
55
FreeRTOS release.
66

77
If your Armv8-M and Armv8.1-M application uses TrustZone then use the files from the
8-
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55] directories.
8+
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55|85] directories.
99

1010
If your Armv8-M and Armv8.1-M application does not use TrustZone then use the files from
11-
the FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55]_NTZ directories.
11+
the FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55|85]_NTZ directories.

portable/ARMv8M/copy_files.py

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@
3333
_FREERTOS_PORTABLE_DIRECTORY_ = os.path.dirname(_THIS_FILE_DIRECTORY_)
3434

3535
_COMPILERS_ = ['GCC', 'IAR']
36-
_ARCH_NS_ = ['ARM_CM55', 'ARM_CM55_NTZ', 'ARM_CM33', 'ARM_CM33_NTZ', 'ARM_CM23', 'ARM_CM23_NTZ']
37-
_ARCH_S_ = ['ARM_CM55', 'ARM_CM33', 'ARM_CM23']
36+
_ARCH_NS_ = ['ARM_CM85', 'ARM_CM85_NTZ', 'ARM_CM55', 'ARM_CM55_NTZ', 'ARM_CM33', 'ARM_CM33_NTZ', 'ARM_CM23', 'ARM_CM23_NTZ']
37+
_ARCH_S_ = ['ARM_CM85', 'ARM_CM55', 'ARM_CM33', 'ARM_CM23']
3838

3939
# Files to be compiled in the Secure Project
4040
_SECURE_COMMON_FILE_PATHS_ = [
@@ -48,12 +48,14 @@
4848
'GCC':{
4949
'ARM_CM23':[os.path.join('secure', 'context', 'portable', 'GCC', 'ARM_CM23')],
5050
'ARM_CM33':[os.path.join('secure', 'context', 'portable', 'GCC', 'ARM_CM33')],
51-
'ARM_CM55':[os.path.join('secure', 'context', 'portable', 'GCC', 'ARM_CM33')]
51+
'ARM_CM55':[os.path.join('secure', 'context', 'portable', 'GCC', 'ARM_CM33')],
52+
'ARM_CM85':[os.path.join('secure', 'context', 'portable', 'GCC', 'ARM_CM33')]
5253
},
5354
'IAR':{
5455
'ARM_CM23':[os.path.join('secure', 'context', 'portable', 'IAR', 'ARM_CM23')],
5556
'ARM_CM33':[os.path.join('secure', 'context', 'portable', 'IAR', 'ARM_CM33')],
56-
'ARM_CM55':[os.path.join('secure', 'context', 'portable', 'IAR', 'ARM_CM33')]
57+
'ARM_CM55':[os.path.join('secure', 'context', 'portable', 'IAR', 'ARM_CM33')],
58+
'ARM_CM85':[os.path.join('secure', 'context', 'portable', 'IAR', 'ARM_CM33')]
5759
}
5860
}
5961

@@ -71,7 +73,11 @@
7173
'ARM_CM55' : [os.path.join('non_secure', 'portable', 'GCC', 'ARM_CM33', 'portasm.c'),
7274
os.path.join('non_secure', 'portable', 'GCC', 'ARM_CM55', 'portmacro.h')],
7375
'ARM_CM55_NTZ' : [os.path.join('non_secure', 'portable', 'GCC', 'ARM_CM33_NTZ', 'portasm.c'),
74-
os.path.join('non_secure', 'portable', 'GCC', 'ARM_CM55', 'portmacro.h')]
76+
os.path.join('non_secure', 'portable', 'GCC', 'ARM_CM55', 'portmacro.h')],
77+
'ARM_CM85' : [os.path.join('non_secure', 'portable', 'GCC', 'ARM_CM33', 'portasm.c'),
78+
os.path.join('non_secure', 'portable', 'GCC', 'ARM_CM85', 'portmacro.h')],
79+
'ARM_CM85_NTZ' : [os.path.join('non_secure', 'portable', 'GCC', 'ARM_CM33_NTZ', 'portasm.c'),
80+
os.path.join('non_secure', 'portable', 'GCC', 'ARM_CM85', 'portmacro.h')]
7581
},
7682
'IAR':{
7783
'ARM_CM23' : [os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM23')],
@@ -81,7 +87,11 @@
8187
'ARM_CM55' : [os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM33', 'portasm.s'),
8288
os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM55', 'portmacro.h')],
8389
'ARM_CM55_NTZ' : [os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM33_NTZ', 'portasm.s'),
84-
os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM55', 'portmacro.h')]
90+
os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM55', 'portmacro.h')],
91+
'ARM_CM85' : [os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM33', 'portasm.s'),
92+
os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM85', 'portmacro.h')],
93+
'ARM_CM85_NTZ' : [os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM33_NTZ', 'portasm.s'),
94+
os.path.join('non_secure', 'portable', 'IAR', 'ARM_CM85', 'portmacro.h')]
8595
},
8696
}
8797

portable/ARMv8M/non_secure/ReadMe.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
This directory tree contains the master copy of the FreeRTOS Armv8-M and
22
Armv8.1-M ports.
33
Do not use the files located here! These file are copied into separate
4-
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55]_NNN directories prior to
4+
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55|85]_NNN directories prior to
55
each FreeRTOS release.
66

77
If your Armv8-M/Armv8.1-M application uses TrustZone then use the files from the
8-
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55] directories.
8+
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55|85] directories.
99

1010
If your Armv8-M/Armv8.1-M application does not use TrustZone then use the files from
11-
the FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55]_NTZ directories.
11+
the FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55|85]_NTZ directories.
Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
/*
2+
* FreeRTOS Kernel <DEVELOPMENT BRANCH>
3+
* Copyright (C) 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved.
4+
*
5+
* SPDX-License-Identifier: MIT
6+
*
7+
* Permission is hereby granted, free of charge, to any person obtaining a copy of
8+
* this software and associated documentation files (the "Software"), to deal in
9+
* the Software without restriction, including without limitation the rights to
10+
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
11+
* the Software, and to permit persons to whom the Software is furnished to do so,
12+
* subject to the following conditions:
13+
*
14+
* The above copyright notice and this permission notice shall be included in all
15+
* copies or substantial portions of the Software.
16+
*
17+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
19+
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
20+
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
21+
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
22+
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23+
*
24+
* https://www.FreeRTOS.org
25+
* https://github.com/FreeRTOS
26+
*
27+
*/
28+
29+
#ifndef PORTMACRO_H
30+
#define PORTMACRO_H
31+
32+
#ifdef __cplusplus
33+
extern "C" {
34+
#endif
35+
36+
#include "portmacrocommon.h"
37+
38+
/*------------------------------------------------------------------------------
39+
* Port specific definitions.
40+
*
41+
* The settings in this file configure FreeRTOS correctly for the given hardware
42+
* and compiler.
43+
*
44+
* These settings should not be altered.
45+
*------------------------------------------------------------------------------
46+
*/
47+
48+
#ifndef configENABLE_MVE
49+
#error configENABLE_MVE must be defined in FreeRTOSConfig.h. Set configENABLE_MVE to 1 to enable the MVE or 0 to disable the MVE.
50+
#endif /* configENABLE_MVE */
51+
/*-----------------------------------------------------------*/
52+
53+
/**
54+
* Architecture specifics.
55+
*/
56+
#define portARCH_NAME "Cortex-M85"
57+
#define portDONT_DISCARD __attribute__( ( used ) )
58+
/*-----------------------------------------------------------*/
59+
60+
/**
61+
* @brief Critical section management.
62+
*/
63+
#define portDISABLE_INTERRUPTS() ulSetInterruptMask()
64+
#define portENABLE_INTERRUPTS() vClearInterruptMask( 0 )
65+
/*-----------------------------------------------------------*/
66+
67+
#ifdef __cplusplus
68+
}
69+
#endif
70+
71+
#endif /* PORTMACRO_H */
Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
/*
2+
* FreeRTOS Kernel <DEVELOPMENT BRANCH>
3+
* Copyright (C) 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved.
4+
*
5+
* SPDX-License-Identifier: MIT
6+
*
7+
* Permission is hereby granted, free of charge, to any person obtaining a copy of
8+
* this software and associated documentation files (the "Software"), to deal in
9+
* the Software without restriction, including without limitation the rights to
10+
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
11+
* the Software, and to permit persons to whom the Software is furnished to do so,
12+
* subject to the following conditions:
13+
*
14+
* The above copyright notice and this permission notice shall be included in all
15+
* copies or substantial portions of the Software.
16+
*
17+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
19+
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
20+
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
21+
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
22+
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23+
*
24+
* https://www.FreeRTOS.org
25+
* https://github.com/FreeRTOS
26+
*
27+
*/
28+
29+
#ifndef PORTMACRO_H
30+
#define PORTMACRO_H
31+
32+
#ifdef __cplusplus
33+
extern "C" {
34+
#endif
35+
36+
#include "portmacrocommon.h"
37+
38+
/*------------------------------------------------------------------------------
39+
* Port specific definitions.
40+
*
41+
* The settings in this file configure FreeRTOS correctly for the given hardware
42+
* and compiler.
43+
*
44+
* These settings should not be altered.
45+
*------------------------------------------------------------------------------
46+
*/
47+
48+
#ifndef configENABLE_MVE
49+
#error configENABLE_MVE must be defined in FreeRTOSConfig.h. Set configENABLE_MVE to 1 to enable the MVE or 0 to disable the MVE.
50+
#endif /* configENABLE_MVE */
51+
/*-----------------------------------------------------------*/
52+
53+
/**
54+
* Architecture specifics.
55+
*/
56+
#define portARCH_NAME "Cortex-M85"
57+
#define portDONT_DISCARD __root
58+
/*-----------------------------------------------------------*/
59+
60+
#if( configTOTAL_MPU_REGIONS == 16 )
61+
#error 16 MPU regions are not yet supported for this port.
62+
#endif
63+
/*-----------------------------------------------------------*/
64+
65+
/**
66+
* @brief Critical section management.
67+
*/
68+
#define portDISABLE_INTERRUPTS() ulSetInterruptMask()
69+
#define portENABLE_INTERRUPTS() vClearInterruptMask( 0 )
70+
/*-----------------------------------------------------------*/
71+
72+
/* Suppress warnings that are generated by the IAR tools, but cannot be fixed in
73+
* the source code because to do so would cause other compilers to generate
74+
* warnings. */
75+
#pragma diag_suppress=Be006
76+
#pragma diag_suppress=Pa082
77+
/*-----------------------------------------------------------*/
78+
79+
#ifdef __cplusplus
80+
}
81+
#endif
82+
83+
#endif /* PORTMACRO_H */

portable/ARMv8M/secure/ReadMe.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
This directory tree contains the master copy of the FreeRTOS Armv8-M and
22
Armv8.1-M ports.
33
Do not use the files located here! These file are copied into separate
4-
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55]_NNN directories prior to
4+
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55|85]_NNN directories prior to
55
each FreeRTOS release.
66

77
If your Armv8-M/Armv8.1-M application uses TrustZone then use the files from the
8-
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55] directories.
8+
FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55|85] directories.
99

1010
If your Armv8-M/Armv8.1-M application does not use TrustZone then use the files from
11-
the FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55]_NTZ directories.
11+
the FreeRTOS/Source/portable/[compiler]/ARM_CM[23|33|55|85]_NTZ directories.

0 commit comments

Comments
 (0)