From bd89c86c0654c22413144e174bd9e04327efdc81 Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Sun, 22 Mar 2015 11:13:45 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@7793 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/rt/ports/ARMCMx/compilers/GCC/chcoreasm_v7m.s | 10 +++++----- os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v6m.s | 3 +++ os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v7m.s | 5 ++++- os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v6m.s | 3 +++ os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v7m.s | 3 +++ 5 files changed, 18 insertions(+), 6 deletions(-) (limited to 'os/rt') diff --git a/os/rt/ports/ARMCMx/compilers/GCC/chcoreasm_v7m.s b/os/rt/ports/ARMCMx/compilers/GCC/chcoreasm_v7m.s index b7750aebc..8446a0ecd 100644 --- a/os/rt/ports/ARMCMx/compilers/GCC/chcoreasm_v7m.s +++ b/os/rt/ports/ARMCMx/compilers/GCC/chcoreasm_v7m.s @@ -88,12 +88,12 @@ _port_thread_start: #if CH_DBG_STATISTICS bl _stats_stop_measure_crit_thd #endif -#if !CORTEX_SIMPLIFIED_PRIORITY - movs r3, #0 - msr BASEPRI, r3 -#else /* CORTEX_SIMPLIFIED_PRIORITY */ +#if CORTEX_SIMPLIFIED_PRIORITY cpsie i -#endif /* CORTEX_SIMPLIFIED_PRIORITY */ +#else + movs r3, #0 /* CORTEX_BASEPRI_DISABLED */ + msr BASEPRI, r3 +#endif mov r0, r5 blx r4 bl chThdExit diff --git a/os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v6m.s b/os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v6m.s index a00adad88..ad2820dfa 100644 --- a/os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v6m.s +++ b/os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v6m.s @@ -92,6 +92,9 @@ _port_switch: _port_thread_start: #if CH_DBG_SYSTEM_STATE_CHECK bl _dbg_check_unlock +#endif +#if CH_DBG_STATISTICS + bl _stats_stop_measure_crit_thd #endif cpsie i mov r0, r5 diff --git a/os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v7m.s b/os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v7m.s index 40f539551..12516a2fc 100644 --- a/os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v7m.s +++ b/os/rt/ports/ARMCMx/compilers/IAR/chcoreasm_v7m.s @@ -88,10 +88,13 @@ _port_thread_start: #if CH_DBG_SYSTEM_STATE_CHECK bl _dbg_check_unlock #endif +#if CH_DBG_STATISTICS + bl _stats_stop_measure_crit_thd +#endif #if CORTEX_SIMPLIFIED_PRIORITY cpsie i #else - movs r3, #CORTEX_BASEPRI_DISABLED + movs r3, #0 /* CORTEX_BASEPRI_DISABLED */ msr BASEPRI, r3 #endif mov r0, r5 diff --git a/os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v6m.s b/os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v6m.s index 5ae930381..e61662f38 100644 --- a/os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v6m.s +++ b/os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v6m.s @@ -88,6 +88,9 @@ _port_switch PROC _port_thread_start PROC #if CH_DBG_SYSTEM_STATE_CHECK bl _dbg_check_unlock +#endif +#if CH_DBG_STATISTICS + bl _stats_stop_measure_crit_thd #endif cpsie i mov r0, r5 diff --git a/os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v7m.s b/os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v7m.s index 0a974bf42..1d23a99f3 100644 --- a/os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v7m.s +++ b/os/rt/ports/ARMCMx/compilers/RVCT/chcoreasm_v7m.s @@ -84,6 +84,9 @@ _port_thread_start PROC #if CH_DBG_SYSTEM_STATE_CHECK bl _dbg_check_unlock #endif +#if CH_DBG_STATISTICS + bl _stats_stop_measure_crit_thd +#endif #if CORTEX_SIMPLIFIED_PRIORITY cpsie i #else -- cgit v1.2.3