[U-Boot] [PATCH 3/3] common: bouncebuf: handle address in sram for rockchip platform
Kever Yang
kever.yang at rock-chips.com
Tue Apr 2 08:46:54 UTC 2019
Rockchip SOC's mmc controller does not support read data
from mmc to sram, we need a bounce buffer(in sdram), and then
copy to sram.
Signed-off-by: Kever Yang <kever.yang at rock-chips.com>
---
common/bouncebuf.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/common/bouncebuf.c b/common/bouncebuf.c
index a7098e2caf..364fb17c96 100644
--- a/common/bouncebuf.c
+++ b/common/bouncebuf.c
@@ -26,6 +26,18 @@ static int addr_aligned(struct bounce_buffer *state)
return 0;
}
+#ifdef CONFIG_ARCH_ROCKCHIP
+ /*
+ * Rockchip SOC's mmc controller does not support read data
+ * from mmc to sram, we need a bounce buffer(in sdram), and then
+ * copy to sram.
+ */
+ if (((ulong)state->user_buffer & 0xfff80000) ==
+ CONFIG_ROCKCHIP_IRAM_BASE) {
+ debug("Unsupport IRAM space %p\n", state->user_buffer);
+ return 0;
+ }
+#endif
/* Aligned */
return 1;
}
--
2.20.1
More information about the U-Boot
mailing list