[rtems commit] bsp/mpc55xx: Add and use chip features

Sebastian Huber sebh at rtems.org
Tue Apr 3 15:10:40 UTC 2012


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

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Tue Apr  3 17:11:10 2012 +0200

bsp/mpc55xx: Add and use chip features

Add defines MPC55XX_HAS_SIU and MPC55XX_HAS_SIU_LITE.

---

 .../libbsp/powerpc/mpc55xxevb/network/smsc9218i.c  |   10 +++++-----
 c/src/lib/libcpu/powerpc/mpc55xx/include/regs.h    |    7 ++++++-
 2 files changed, 11 insertions(+), 6 deletions(-)

diff --git a/c/src/lib/libbsp/powerpc/mpc55xxevb/network/smsc9218i.c b/c/src/lib/libbsp/powerpc/mpc55xxevb/network/smsc9218i.c
index 4202a49..758c78e 100644
--- a/c/src/lib/libbsp/powerpc/mpc55xxevb/network/smsc9218i.c
+++ b/c/src/lib/libbsp/powerpc/mpc55xxevb/network/smsc9218i.c
@@ -7,7 +7,7 @@
  */
 
 /*
- * Copyright (c) 2009-2011 embedded brains GmbH.  All rights reserved.
+ * Copyright (c) 2009-2012 embedded brains GmbH.  All rights reserved.
  *
  *  embedded brains GmbH
  *  Obere Lagerstr. 30
@@ -24,13 +24,13 @@
 
 #include <rtems.h>
 
-#ifdef RTEMS_NETWORKING
+#include <mpc55xx/regs.h>
+
+#if defined(RTEMS_NETWORKING) && defined(MPC55XX_HAS_SIU)
 
 #define __INSIDE_RTEMS_BSD_TCPIP_STACK__ 1
 #define __BSD_VISIBLE 1
 
-#include <mpc55xx/regs.h>
-
 #include <errno.h>
 #include <assert.h>
 #include <stdlib.h>
@@ -1913,4 +1913,4 @@ int smsc9218i_attach_detach(
   return 0;
 }
 
-#endif /* RTEMS_NETWORKING */
+#endif /* defined(RTEMS_NETWORKING) && defined(MPC55XX_HAS_SIU) */
diff --git a/c/src/lib/libcpu/powerpc/mpc55xx/include/regs.h b/c/src/lib/libcpu/powerpc/mpc55xx/include/regs.h
index d9e0f3a..a5043f1 100644
--- a/c/src/lib/libcpu/powerpc/mpc55xx/include/regs.h
+++ b/c/src/lib/libcpu/powerpc/mpc55xx/include/regs.h
@@ -8,7 +8,7 @@
  */
 
 /*
- * Copyright (c) 2008-2011 embedded brains GmbH.  All rights reserved.
+ * Copyright (c) 2008-2012 embedded brains GmbH.  All rights reserved.
  *
  *  embedded brains GmbH
  *  Obere Lagerstr. 30
@@ -34,6 +34,7 @@
   #define MPC55XX_HAS_ESCI
   #define MPC55XX_HAS_EMIOS
   #define MPC55XX_HAS_FMPLL_ENHANCED
+  #define MPC55XX_HAS_SIU
 #elif MPC55XX_CHIP_TYPE / 10 == 555
   #include <mpc55xx/fsl-mpc555x.h>
   #define MPC55XX_HAS_EBI
@@ -41,6 +42,7 @@
   #define MPC55XX_HAS_EMIOS
   #define MPC55XX_HAS_FMPLL
   #define MPC55XX_HAS_UNIFIED_CACHE
+  #define MPC55XX_HAS_SIU
 #elif MPC55XX_CHIP_TYPE / 10 == 556
   #include <mpc55xx/fsl-mpc556x.h>
   #define MPC55XX_HAS_EBI
@@ -48,6 +50,7 @@
   #define MPC55XX_HAS_EMIOS
   #define MPC55XX_HAS_FMPLL
   #define MPC55XX_HAS_UNIFIED_CACHE
+  #define MPC55XX_HAS_SIU
 #elif MPC55XX_CHIP_TYPE / 10 == 564
   #include <mpc55xx/fsl-mpc564xL.h>
   #define MPC55XX_HAS_STM
@@ -56,6 +59,7 @@
   #define MPC55XX_HAS_INSTRUCTION_CACHE
   #define MPC55XX_HAS_LINFLEX
   #define MPC55XX_HAS_SECOND_INTERNAL_RAM_AREA
+  #define MPC55XX_HAS_SIU_LITE
 #elif MPC55XX_CHIP_TYPE / 10 == 567
   #include <mpc55xx/fsl-mpc567x.h>
   #define MPC55XX_HAS_EBI
@@ -64,6 +68,7 @@
   #define MPC55XX_HAS_FMPLL_ENHANCED
   #define MPC55XX_HAS_INSTRUCTION_CACHE
   #define MPC55XX_HAS_DATA_CACHE
+  #define MPC55XX_HAS_SIU
 #else
   #error "unsupported chip type"
 #endif




More information about the vc mailing list