Skip to content

Commit ff21881

Browse files
committed
Make changes for Cortex-A5 support
1 parent a57b892 commit ff21881

File tree

7 files changed

+8
-6
lines changed

7 files changed

+8
-6
lines changed

platform/include/platform/mbed_application.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
#include<stdint.h>
2222

2323
#if defined(__CORTEX_M0PLUS) || defined(__CORTEX_M3) || defined(__CORTEX_M4) || defined(__CORTEX_M7)\
24-
|| defined(__CORTEX_M23) || defined(__CORTEX_A9) || defined(__CORTEX_M33)
24+
|| defined(__CORTEX_M23) || defined(__CORTEX_A9) || defined(__CORTEX_A5) || defined(__CORTEX_M33)
2525
#define MBED_APPLICATION_SUPPORT 1
2626
#else
2727
#define MBED_APPLICATION_SUPPORT 0

platform/source/mbed_application.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
#if MBED_APPLICATION_SUPPORT
2525

26-
#if defined(__CORTEX_A9)
26+
#if defined(__CORTEX_A9) || defined(__CORTEX_A5)
2727

2828
static void powerdown_gic(void);
2929

platform/source/mbed_wait_api_no_rtos.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ void wait_us(int us)
9191
#define LOOP_SCALER 2000
9292
#endif
9393
#elif defined __CORTEX_A
94-
#if __CORTEX_A == 9
94+
#if __CORTEX_A == 9 || __CORTEX_A == 5
9595
// Cortex-A9 can dual issue for 3 cycles per iteration (SUB,NOP) = 1, (NOP,BCS) = 2
9696
#define LOOP_SCALER 3000
9797
#endif

platform/tests/TESTS/mbed_platform/stats_cpu/main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ DigitalOut led1(LED1);
3333
#endif
3434

3535
// Targets with these cores have their RAM enough size to create threads with bigger stacks
36-
#if defined(__CORTEX_A9) || defined(__CORTEX_M23) || defined(__CORTEX_M33) || defined(__CORTEX_M7)
36+
#if defined(__CORTEX_A9) || defined(__CORTEX_A5) || defined(__CORTEX_M23) || defined(__CORTEX_M33) || defined(__CORTEX_M7)
3737
#define MAX_THREAD_STACK 512
3838
#else
3939
#define MAX_THREAD_STACK 384

rtos/tests/TESTS/mbed_rtos/malloc/main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ volatile bool thread_should_continue = true;
3232
#define NUM_THREADS 4
3333
#define THREAD_MALLOC_SIZE 100
3434

35-
#if defined(__CORTEX_A9)
35+
#if defined(__CORTEX_A9) || defined(__CORTEX_A5)
3636
#define THREAD_STACK_SIZE 512
3737
#elif defined(__CORTEX_M23) || defined(__CORTEX_M33)
3838
#define THREAD_STACK_SIZE 512

rtos/tests/TESTS/mbed_rtos/threads/main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
#include <type_traits>
3333

3434
#define THREAD_STACK_SIZE 512
35-
#if defined(__CORTEX_A9) || defined(__CORTEX_M23) || defined(__CORTEX_M33) || defined(TARGET_ARM_FM) || defined(TARGET_CY8CKIT_062_WIFI_BT_PSA)
35+
#if defined(__CORTEX_A9) || defined(__CORTEX_A5) || defined(__CORTEX_M23) || defined(__CORTEX_M33) || defined(TARGET_ARM_FM) || defined(TARGET_CY8CKIT_062_WIFI_BT_PSA)
3636
#define PARALLEL_THREAD_STACK_SIZE 512
3737
#define CHILD_THREAD_STACK_SIZE 512
3838
#else

tools/cmake/mbed_toolchain.cmake

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ endfunction()
2525
# Set the system processor depending on the CPU core type
2626
if (MBED_CPU_CORE STREQUAL Cortex-A9)
2727
set(CMAKE_SYSTEM_PROCESSOR cortex-a9)
28+
elseif (MBED_CPU_CORE STREQUAL Cortex-A5)
29+
set(CMAKE_SYSTEM_PROCESSOR cortex-a5)
2830
elseif (MBED_CPU_CORE STREQUAL Cortex-M0+)
2931
set(CMAKE_SYSTEM_PROCESSOR cortex-m0plus)
3032
elseif (MBED_CPU_CORE STREQUAL Cortex-M0)

0 commit comments

Comments
 (0)