[rtems commit] arm: Include <rtems/score/cpu.h>
Sebastian Huber
sebh at rtems.org
Mon Jan 7 14:05:04 UTC 2013
Module: rtems
Branch: master
Commit: e377ad7d621f9b278a29dbbff25b915a40e6073b
Changeset: http://git.rtems.org/rtems/commit/?id=e377ad7d621f9b278a29dbbff25b915a40e6073b
Author: Sebastian Huber <sebastian.huber at embedded-brains.de>
Date: Mon Jan 7 08:48:45 2013 +0100
arm: Include <rtems/score/cpu.h>
---
cpukit/score/cpu/arm/armv7m-context-initialize.c | 3 +--
cpukit/score/cpu/arm/armv7m-context-restore.c | 3 +--
cpukit/score/cpu/arm/armv7m-context-switch.c | 3 +--
.../score/cpu/arm/armv7m-exception-handler-get.c | 3 +--
.../score/cpu/arm/armv7m-exception-handler-set.c | 4 +---
.../score/cpu/arm/armv7m-exception-priority-get.c | 4 +---
.../cpu/arm/armv7m-exception-priority-handler.c | 4 +---
.../score/cpu/arm/armv7m-exception-priority-set.c | 4 +---
cpukit/score/cpu/arm/armv7m-initialize.c | 4 +---
cpukit/score/cpu/arm/armv7m-isr-dispatch.c | 3 +--
cpukit/score/cpu/arm/armv7m-isr-enter-leave.c | 3 +--
cpukit/score/cpu/arm/armv7m-isr-level-get.c | 4 +---
cpukit/score/cpu/arm/armv7m-isr-level-set.c | 4 +---
cpukit/score/cpu/arm/armv7m-isr-vector-install.c | 3 +--
.../score/cpu/arm/armv7m-multitasking-start-stop.c | 4 +---
cpukit/score/cpu/arm/rtems/score/armv7m.h | 7 +++++--
16 files changed, 20 insertions(+), 40 deletions(-)
diff --git a/cpukit/score/cpu/arm/armv7m-context-initialize.c b/cpukit/score/cpu/arm/armv7m-context-initialize.c
index 640adae..892df4d 100644
--- a/cpukit/score/cpu/arm/armv7m-context-initialize.c
+++ b/cpukit/score/cpu/arm/armv7m-context-initialize.c
@@ -24,12 +24,11 @@
#include <string.h>
+#include <rtems/score/armv7m.h>
#include <rtems/score/thread.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void _CPU_Context_Initialize(
Context_Control *context,
void *stack_area_begin,
diff --git a/cpukit/score/cpu/arm/armv7m-context-restore.c b/cpukit/score/cpu/arm/armv7m-context-restore.c
index 4779049..a9afdf3 100644
--- a/cpukit/score/cpu/arm/armv7m-context-restore.c
+++ b/cpukit/score/cpu/arm/armv7m-context-restore.c
@@ -22,12 +22,11 @@
#include "config.h"
#endif
+#include <rtems/score/armv7m.h>
#include <rtems/score/percpu.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void __attribute__((naked)) _CPU_Context_restore(
Context_Control *heir
)
diff --git a/cpukit/score/cpu/arm/armv7m-context-switch.c b/cpukit/score/cpu/arm/armv7m-context-switch.c
index 0fd3c20..9814ed0 100644
--- a/cpukit/score/cpu/arm/armv7m-context-switch.c
+++ b/cpukit/score/cpu/arm/armv7m-context-switch.c
@@ -22,12 +22,11 @@
#include "config.h"
#endif
+#include <rtems/score/armv7m.h>
#include <rtems/score/percpu.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void __attribute__((naked)) _CPU_Context_switch(
Context_Control *executing,
Context_Control *heir
diff --git a/cpukit/score/cpu/arm/armv7m-exception-handler-get.c b/cpukit/score/cpu/arm/armv7m-exception-handler-get.c
index cf25caf..cf10077 100644
--- a/cpukit/score/cpu/arm/armv7m-exception-handler-get.c
+++ b/cpukit/score/cpu/arm/armv7m-exception-handler-get.c
@@ -22,12 +22,11 @@
#include "config.h"
#endif
+#include <rtems/score/armv7m.h>
#include <rtems/score/cpu.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
ARMV7M_Exception_handler _ARMV7M_Get_exception_handler( int index )
{
return _ARMV7M_SCB->vtor [index];
diff --git a/cpukit/score/cpu/arm/armv7m-exception-handler-set.c b/cpukit/score/cpu/arm/armv7m-exception-handler-set.c
index ea3fce3..0de3a22 100644
--- a/cpukit/score/cpu/arm/armv7m-exception-handler-set.c
+++ b/cpukit/score/cpu/arm/armv7m-exception-handler-set.c
@@ -22,12 +22,10 @@
#include "config.h"
#endif
-#include <rtems/score/cpu.h>
+#include <rtems/score/armv7m.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void _ARMV7M_Set_exception_handler(
int index,
ARMV7M_Exception_handler handler
diff --git a/cpukit/score/cpu/arm/armv7m-exception-priority-get.c b/cpukit/score/cpu/arm/armv7m-exception-priority-get.c
index 79224e1..6a1df1d 100644
--- a/cpukit/score/cpu/arm/armv7m-exception-priority-get.c
+++ b/cpukit/score/cpu/arm/armv7m-exception-priority-get.c
@@ -21,12 +21,10 @@
#include "config.h"
#endif
-#include <rtems/score/cpu.h>
+#include <rtems/score/armv7m.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
int _ARMV7M_Get_exception_priority( int vector )
{
if ( _ARMV7M_Is_vector_an_irq( vector ) ) {
diff --git a/cpukit/score/cpu/arm/armv7m-exception-priority-handler.c b/cpukit/score/cpu/arm/armv7m-exception-priority-handler.c
index de0b020..7b3ff50 100644
--- a/cpukit/score/cpu/arm/armv7m-exception-priority-handler.c
+++ b/cpukit/score/cpu/arm/armv7m-exception-priority-handler.c
@@ -22,12 +22,10 @@
#include "config.h"
#endif
-#include <rtems/score/cpu.h>
+#include <rtems/score/armv7m.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void _ARMV7M_Set_exception_priority_and_handler(
int index,
int priority,
diff --git a/cpukit/score/cpu/arm/armv7m-exception-priority-set.c b/cpukit/score/cpu/arm/armv7m-exception-priority-set.c
index 085ce2d..76dd6d3 100644
--- a/cpukit/score/cpu/arm/armv7m-exception-priority-set.c
+++ b/cpukit/score/cpu/arm/armv7m-exception-priority-set.c
@@ -22,12 +22,10 @@
#include "config.h"
#endif
-#include <rtems/score/cpu.h>
+#include <rtems/score/armv7m.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void _ARMV7M_Set_exception_priority( int vector, int priority )
{
if ( _ARMV7M_Is_vector_an_irq( vector ) ) {
diff --git a/cpukit/score/cpu/arm/armv7m-initialize.c b/cpukit/score/cpu/arm/armv7m-initialize.c
index cb3c196..236a097 100644
--- a/cpukit/score/cpu/arm/armv7m-initialize.c
+++ b/cpukit/score/cpu/arm/armv7m-initialize.c
@@ -22,12 +22,10 @@
#include "config.h"
#endif
-#include <rtems/score/cpu.h>
+#include <rtems/score/armv7m.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void _CPU_Initialize( void )
{
/*
diff --git a/cpukit/score/cpu/arm/armv7m-isr-dispatch.c b/cpukit/score/cpu/arm/armv7m-isr-dispatch.c
index 7c2cd73..3cfe7d7 100644
--- a/cpukit/score/cpu/arm/armv7m-isr-dispatch.c
+++ b/cpukit/score/cpu/arm/armv7m-isr-dispatch.c
@@ -22,12 +22,11 @@
#include "config.h"
#endif
+#include <rtems/score/armv7m.h>
#include <rtems/score/percpu.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
static void __attribute__((naked)) _ARMV7M_Thread_dispatch( void )
{
__asm__ volatile (
diff --git a/cpukit/score/cpu/arm/armv7m-isr-enter-leave.c b/cpukit/score/cpu/arm/armv7m-isr-enter-leave.c
index 1bce10a..5af0a81 100644
--- a/cpukit/score/cpu/arm/armv7m-isr-enter-leave.c
+++ b/cpukit/score/cpu/arm/armv7m-isr-enter-leave.c
@@ -22,12 +22,11 @@
#include "config.h"
#endif
+#include <rtems/score/armv7m.h>
#include <rtems/score/thread.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void _ARMV7M_Interrupt_service_enter( void )
{
++_Thread_Dispatch_disable_level;
diff --git a/cpukit/score/cpu/arm/armv7m-isr-level-get.c b/cpukit/score/cpu/arm/armv7m-isr-level-get.c
index 887e308..7ba13ac 100644
--- a/cpukit/score/cpu/arm/armv7m-isr-level-get.c
+++ b/cpukit/score/cpu/arm/armv7m-isr-level-get.c
@@ -22,12 +22,10 @@
#include "config.h"
#endif
-#include <rtems/score/cpu.h>
+#include <rtems/score/armv7m.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
uint32_t _CPU_ISR_Get_level( void )
{
return 0;
diff --git a/cpukit/score/cpu/arm/armv7m-isr-level-set.c b/cpukit/score/cpu/arm/armv7m-isr-level-set.c
index 2f4c363..81cb9fd 100644
--- a/cpukit/score/cpu/arm/armv7m-isr-level-set.c
+++ b/cpukit/score/cpu/arm/armv7m-isr-level-set.c
@@ -22,12 +22,10 @@
#include "config.h"
#endif
-#include <rtems/score/cpu.h>
+#include <rtems/score/armv7m.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void _CPU_ISR_Set_level( uint32_t level )
{
_ARMV7M_Set_basepri( 0 );
diff --git a/cpukit/score/cpu/arm/armv7m-isr-vector-install.c b/cpukit/score/cpu/arm/armv7m-isr-vector-install.c
index 82b8e02..ef813e3 100644
--- a/cpukit/score/cpu/arm/armv7m-isr-vector-install.c
+++ b/cpukit/score/cpu/arm/armv7m-isr-vector-install.c
@@ -22,12 +22,11 @@
#include "config.h"
#endif
+#include <rtems/score/armv7m.h>
#include <rtems/score/isr.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void _CPU_ISR_install_vector(
uint32_t vector,
proc_ptr new_handler,
diff --git a/cpukit/score/cpu/arm/armv7m-multitasking-start-stop.c b/cpukit/score/cpu/arm/armv7m-multitasking-start-stop.c
index d27bf8b..f3e96e3 100644
--- a/cpukit/score/cpu/arm/armv7m-multitasking-start-stop.c
+++ b/cpukit/score/cpu/arm/armv7m-multitasking-start-stop.c
@@ -22,12 +22,10 @@
#include "config.h"
#endif
-#include <rtems/score/cpu.h>
+#include <rtems/score/armv7m.h>
#ifdef ARM_MULTILIB_ARCH_V7M
-#include <rtems/score/armv7m.h>
-
void __attribute__((naked)) _ARMV7M_Start_multitasking(
Context_Control *bsp,
Context_Control *heir
diff --git a/cpukit/score/cpu/arm/rtems/score/armv7m.h b/cpukit/score/cpu/arm/rtems/score/armv7m.h
index 62f69ff..c8b55c1 100644
--- a/cpukit/score/cpu/arm/rtems/score/armv7m.h
+++ b/cpukit/score/cpu/arm/rtems/score/armv7m.h
@@ -15,13 +15,14 @@
#ifndef RTEMS_SCORE_ARMV7M_H
#define RTEMS_SCORE_ARMV7M_H
-#include <stdint.h>
-#include <stdbool.h>
+#include <rtems/score/cpu.h>
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
+#ifdef ARM_MULTILIB_ARCH_V7M
+
typedef struct {
uint32_t reserved_0;
uint32_t ictr;
@@ -475,6 +476,8 @@ void _ARMV7M_Pendable_service_call( void );
void _ARMV7M_Supervisor_call( void );
+#endif /* ARM_MULTILIB_ARCH_V7M */
+
#ifdef __cplusplus
}
#endif /* __cplusplus */
More information about the vc
mailing list