From 5068e9657f170340d66abb759907b32f6cad1093 Mon Sep 17 00:00:00 2001 From: Kumar Gala Date: Wed, 25 Jan 2017 08:24:57 -0600 Subject: arm: cmsis: Convert _ScbPendsvSet to use direct CMSIS register access Jira: ZEP-1568 Change-Id: I25653d8fbe3842fbfa79191d388c6f6693fca39c Signed-off-by: Kumar Gala --- arch/arm/core/thread_abort.c | 2 +- include/arch/arm/cortex_m/scb.h | 15 --------------- 2 files changed, 1 insertion(+), 16 deletions(-) diff --git a/arch/arm/core/thread_abort.c b/arch/arm/core/thread_abort.c index ec1a18e53..a24e2bbcf 100644 --- a/arch/arm/core/thread_abort.c +++ b/arch/arm/core/thread_abort.c @@ -39,7 +39,7 @@ void k_thread_abort(k_tid_t thread) _Swap(key); CODE_UNREACHABLE; } else { - _ScbPendsvSet(); + SCB->ICSR |= SCB_ICSR_PENDSVSET_Msk; } } diff --git a/include/arch/arm/cortex_m/scb.h b/include/arch/arm/cortex_m/scb.h index 967b492b2..df9e3a88d 100644 --- a/include/arch/arm/cortex_m/scb.h +++ b/include/arch/arm/cortex_m/scb.h @@ -51,21 +51,6 @@ extern "C" { #include #include -/** - * - * @brief Set the PendSV exception - * - * Set the PendSV exception: it will be handled when the last nested exception - * returns, or immediately if running in thread mode. - * - * @return N/A - */ - -static inline void _ScbPendsvSet(void) -{ - __scs.scb.icsr.bit.pendsvset = 1; -} - /** * * @brief Find out if running in thread mode -- cgit v1.2.3