[rtems commit] powerpc: Fix ss555 build

Sebastian Huber sebh at rtems.org
Mon Jun 11 12:48:16 UTC 2018


Module:    rtems
Branch:    master
Commit:    5249a4cc283af9faf17d45889a124b60784fe64d
Changeset: http://git.rtems.org/rtems/commit/?id=5249a4cc283af9faf17d45889a124b60784fe64d

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Thu Jun  7 07:18:23 2018 +0200

powerpc: Fix ss555 build

The mpc555 define is provided via <bspopts.h>.  It must not be used in
cpukit header files.

Update #3425.

---

 bsps/powerpc/ss555/include/bsp.h             | 13 ++++++++++---
 bsps/powerpc/ss555/start/irq_asm.S           |  2 +-
 bsps/powerpc/ss555/start/vectors.S           |  1 +
 cpukit/score/cpu/powerpc/include/rtems/asm.h |  6 ------
 4 files changed, 12 insertions(+), 10 deletions(-)

diff --git a/bsps/powerpc/ss555/include/bsp.h b/bsps/powerpc/ss555/include/bsp.h
index a82d10a..3226f5e 100644
--- a/bsps/powerpc/ss555/include/bsp.h
+++ b/bsps/powerpc/ss555/include/bsp.h
@@ -19,9 +19,16 @@
 #ifndef LIBBSP_POWERPC_SS555_BSP_H
 #define LIBBSP_POWERPC_SS555_BSP_H
 
-#ifndef ASM
-
 #include <bspopts.h>
+
+#ifdef ASM
+
+#define eie     0x050   /* External Interrupt Enable Register */
+#define eid     0x051   /* External Interrupt Disable Register */
+#define nri     0x052   /* Non-Recoverable Interrupt Register */
+
+#else /* !ASM */
+
 #include <bsp/default-initial-extension.h>
 
 #include <rtems.h>
@@ -39,7 +46,7 @@ extern "C" {
  */
 
 #define BSP_CRYSTAL_HZ 	 4000000	/* crystal frequency, Hz */
-#define BSP_CLOCK_HZ	40000000	/* CPU clock frequency, Hz
+#define BSP_CLOCK_HZ	40000000	/* CPU clock frequency, Hz */
 
 /*
  * I/O definitions
diff --git a/bsps/powerpc/ss555/start/irq_asm.S b/bsps/powerpc/ss555/start/irq_asm.S
index 52911c4..eff4128 100644
--- a/bsps/powerpc/ss555/start/irq_asm.S
+++ b/bsps/powerpc/ss555/start/irq_asm.S
@@ -27,7 +27,7 @@
 #include <rtems/score/percpu.h>
 #include <libcpu/vectors.h>
 #include <libcpu/raw_exception.h>
-
+#include <bsp.h>
 
 #define SYNC \
 	sync; \
diff --git a/bsps/powerpc/ss555/start/vectors.S b/bsps/powerpc/ss555/start/vectors.S
index 35d2f23..6df8984 100644
--- a/bsps/powerpc/ss555/start/vectors.S
+++ b/bsps/powerpc/ss555/start/vectors.S
@@ -16,6 +16,7 @@
 #include <rtems/asm.h>
 #include <rtems/score/cpu.h>
 #include <libcpu/vectors.h>
+#include <bsp.h>
 
 #define SYNC \
 	sync; \
diff --git a/cpukit/score/cpu/powerpc/include/rtems/asm.h b/cpukit/score/cpu/powerpc/include/rtems/asm.h
index 2fddf56..5bf307b 100644
--- a/cpukit/score/cpu/powerpc/include/rtems/asm.h
+++ b/cpukit/score/cpu/powerpc/include/rtems/asm.h
@@ -240,12 +240,6 @@
 
 /* end of IBM400 series register definitions */
 
-#elif defined(mpc555)
-/* The following registers are for the MPC5xx */
-#define eie     0x050   /* External Interrupt Enable Register */
-#define eid     0x051   /* External Interrupt Disable Register */
-#define nri     0x052   /* Non-Recoverable Interrupt Register */
-
 #elif defined(mpc860) || defined(mpc821)
 /* The following registers are for the MPC8x0 */
 #define der     0x095   /* Debug Enable Register */




More information about the vc mailing list