summaryrefslogtreecommitdiff
path: root/board/rsdproto/flash_asm.S
diff options
context:
space:
mode:
authorwdenk <wdenk>2001-04-28 17:59:11 +0000
committerwdenk <wdenk>2001-04-28 17:59:11 +0000
commit4a5b6a356a79123d3fcd780139629213afcedca8 (patch)
treea54c1cec31c73462ba2c04fac3318a0990dd21b1 /board/rsdproto/flash_asm.S
parentb631bb9cad6b5553846f508fbfa5ba6362fb0677 (diff)
downloadu-boot-imx-4a5b6a356a79123d3fcd780139629213afcedca8.zip
u-boot-imx-4a5b6a356a79123d3fcd780139629213afcedca8.tar.gz
u-boot-imx-4a5b6a356a79123d3fcd780139629213afcedca8.tar.bz2
Initial revision
Diffstat (limited to 'board/rsdproto/flash_asm.S')
-rw-r--r--board/rsdproto/flash_asm.S39
1 files changed, 39 insertions, 0 deletions
diff --git a/board/rsdproto/flash_asm.S b/board/rsdproto/flash_asm.S
new file mode 100644
index 0000000..c65fb87
--- /dev/null
+++ b/board/rsdproto/flash_asm.S
@@ -0,0 +1,39 @@
+/*
+ * -*- mode:c -*-
+ *
+ * (C) Copyright 2000
+ * Marius Groeger <mgroeger@sysgo.de>
+ * Sysgo Real-Time Solutions, GmbH <www.elinos.com>
+ *
+ * void ull_write(unsigned long long volatile *address,
+ * unsigned long long volatile *data)
+ * r3 = address
+ * r4 = data
+ *
+ * void ull_read(unsigned long long volatile *address,
+ * unsigned long long volatile *data)
+ * r3 = address
+ * r4 = data
+ *
+ * Uses the floating point unit to read and write 64 bit wide
+ * data (unsigned long long) on the 60x bus. This is necessary
+ * because all 4 flash chips use the /WE line from byte lane 0
+ *
+ * IMPORTANT: data should always be 8-aligned, otherwise an exception will
+ * occur.
+ */
+
+#include <ppc_asm.tmpl>
+#include <ppc_defs.h>
+
+.globl ull_write
+ull_write:
+ lfd 0,0(r4)
+ stfd 0,0(r3)
+ blr
+
+ .globl ull_read
+ull_read:
+ lfd 0, 0(r3)
+ stfd 0, 0(r4)
+ blr