From 291e2b1ae6149b6864fd05053378a9491a9c518c Mon Sep 17 00:00:00 2001 From: Rafaël Carré Date: Sun, 14 Mar 2010 21:38:30 +0000 Subject: sd-as3525v2: delay a bit before reading the command response Especially when using caches we might read the response too fast and get the response for the previous command instead. Now Clip+ boots fine with both instruction & data caches enabled, the delay might need to be lowered though: boot time is a bit longer. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25183 a1c6a512-1295-4272-9138-f99709370657 --- firmware/target/arm/as3525/sd-as3525v2.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/firmware/target/arm/as3525/sd-as3525v2.c b/firmware/target/arm/as3525/sd-as3525v2.c index 9175ef0f09..94b46017da 100644 --- a/firmware/target/arm/as3525/sd-as3525v2.c +++ b/firmware/target/arm/as3525/sd-as3525v2.c @@ -377,6 +377,9 @@ static bool send_cmd(const int cmd, const int arg, const int flags, if(flags & MCI_RESP) { + mci_delay(); /* if we read the response too fast we might read the + * response of the previous command instead */ + if(flags & MCI_LONG_RESP) { /* store the response in little endian order for the words */ -- cgit v1.2.3