summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/sparc/leon2/include/bsp.h
diff options
context:
space:
mode:
authorDaniel Hellstrom <daniel@gaisler.com>2011-12-02 10:53:35 +0100
committerGedare Bloom <gedare@rtems.org>2012-03-27 16:29:22 -0400
commit39671330dc7db16955af7fb240f93d1ae192603f (patch)
tree58260d6cc5c4cf125366168c9bd54d0b26de507a /c/src/lib/libbsp/sparc/leon2/include/bsp.h
parentARM: PR2042: Provide stub for ARMv6-M (diff)
downloadrtems-39671330dc7db16955af7fb240f93d1ae192603f.tar.bz2
GRETH: added support for non-snooping GRETH 10/100 systems
When data cache snooping is not present the cache needs flushing, the SPARC LEON CPUs does not have to ability to flush individual cache rows and flushing all cache is expensive. Instead the LDA instruction is used to force cache miss on individual loads during the IP-align copy operation required anyway. GRETH GBIT non-snooping systems are still unsupported, since it use zero-copy (can deal with unaligned DMA). Let the bsp.h select if the GRETH driver is supported. Currently only the LEON2/LEON3 platforms BSPs builds the driver. Signed-off-by: Daniel Hellstrom <daniel@gaisler.com>
Diffstat (limited to '')
-rw-r--r--c/src/lib/libbsp/sparc/leon2/include/bsp.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/sparc/leon2/include/bsp.h b/c/src/lib/libbsp/sparc/leon2/include/bsp.h
index 3375d1034f..994f89bd8c 100644
--- a/c/src/lib/libbsp/sparc/leon2/include/bsp.h
+++ b/c/src/lib/libbsp/sparc/leon2/include/bsp.h
@@ -60,6 +60,10 @@ extern int rtems_smc91111_driver_attach_leon2(
#define HAS_SMC91111
+/* Configure GRETH driver */
+#define GRETH_SUPPORTED
+#define GRETH_MEM_LOAD(addr) leon_r32_no_cache(addr)
+
/*
* The synchronous trap is an arbitrarily chosen software trap.
*/