[rtems commit] SMC91111: ERC32 was never supported by driver

gedare at rtems.org gedare at rtems.org
Wed Mar 21 16:36:17 UTC 2012


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

Author:    Daniel Hellstrom <daniel at gaisler.com>
Date:      Mon Feb  6 15:15:49 2012 +0100

SMC91111: ERC32 was never supported by driver

Moved the intelligence whether the driver is supported or not
completely to the BSP, now that bsp.h is included (even though it
is a driver... hmm). The ERC32 was never supported, so HAS_SMC91111
is not added to erc32/include/bsp.h.

Signed-off-by: Daniel Hellstrom <daniel at gaisler.com>

---

 c/src/lib/libbsp/sparc/leon2/include/bsp.h |    2 ++
 c/src/lib/libbsp/sparc/leon3/include/bsp.h |    2 ++
 c/src/libchip/network/smc91111.c           |    4 ++--
 3 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/c/src/lib/libbsp/sparc/leon2/include/bsp.h b/c/src/lib/libbsp/sparc/leon2/include/bsp.h
index 34e31ce..3375d10 100644
--- a/c/src/lib/libbsp/sparc/leon2/include/bsp.h
+++ b/c/src/lib/libbsp/sparc/leon2/include/bsp.h
@@ -58,6 +58,8 @@ extern int rtems_smc91111_driver_attach_leon2(
 #define RTEMS_BSP_NETWORK_DRIVER_ATTACH_SMC91111 \
           rtems_smc91111_driver_attach_leon2
 
+#define HAS_SMC91111
+
 /*
  *  The synchronous trap is an arbitrarily chosen software trap.
  */
diff --git a/c/src/lib/libbsp/sparc/leon3/include/bsp.h b/c/src/lib/libbsp/sparc/leon3/include/bsp.h
index 89b36d4..340ec6f 100644
--- a/c/src/lib/libbsp/sparc/leon3/include/bsp.h
+++ b/c/src/lib/libbsp/sparc/leon3/include/bsp.h
@@ -71,6 +71,8 @@ extern int rtems_leon_greth_driver_attach(
 #define RTEMS_BSP_NETWORK_DRIVER_ATTACH RTEMS_BSP_NETWORK_DRIVER_ATTACH_GRETH
 #endif
 
+#define HAS_SMC91111
+
 extern int   CPU_SPARC_HAS_SNOOPING;
 
 
diff --git a/c/src/libchip/network/smc91111.c b/c/src/libchip/network/smc91111.c
index 9313aa6..41961ae 100644
--- a/c/src/libchip/network/smc91111.c
+++ b/c/src/libchip/network/smc91111.c
@@ -15,11 +15,11 @@
  *
  */
 
-#if defined(__sparc__) || defined(HAS_SMC91111)
+#if defined(HAS_SMC91111)
   #define SMC91111_SUPPORTED
 #endif
 
-#if defined(SMC91111_SUPPORTED)
+#if defined(HAS_SMC91111)
 
 #include <stdlib.h>
 #include <stdio.h>




More information about the vc mailing list