[rtems commit] bsp/qoriq: Add QORIQ_HAS_WRITE_BACK_L1_CACHE
Sebastian Huber
sebh at rtems.org
Thu Jul 28 10:06:55 UTC 2016
Module: rtems
Branch: master
Commit: b1ef3674c0bffdd169e070f039d413cceb5e706c
Changeset: http://git.rtems.org/rtems/commit/?id=b1ef3674c0bffdd169e070f039d413cceb5e706c
Author: Sebastian Huber <sebastian.huber at embedded-brains.de>
Date: Wed Jul 27 11:30:09 2016 +0200
bsp/qoriq: Add QORIQ_HAS_WRITE_BACK_L1_CACHE
Fixes start via U-Boot on P1020.
---
c/src/lib/libbsp/powerpc/qoriq/configure.ac | 4 ++++
c/src/lib/libbsp/powerpc/qoriq/start/start.S | 7 +++++++
2 files changed, 11 insertions(+)
diff --git a/c/src/lib/libbsp/powerpc/qoriq/configure.ac b/c/src/lib/libbsp/powerpc/qoriq/configure.ac
index 10dd17c..9e63763 100644
--- a/c/src/lib/libbsp/powerpc/qoriq/configure.ac
+++ b/c/src/lib/libbsp/powerpc/qoriq/configure.ac
@@ -172,6 +172,10 @@ RTEMS_BSPOPTS_SET([QORIQ_HAS_HYPERVISOR_MODE],[qoriq_t*],[1])
RTEMS_BSPOPTS_SET([QORIQ_HAS_HYPERVISOR_MODE],[*],[])
RTEMS_BSPOPTS_HELP([QORIQ_HAS_HYPERVISOR_MODE],[defined if the processor core has a hypervisor mode])
+RTEMS_BSPOPTS_SET([QORIQ_HAS_WRITE_BACK_L1_CACHE],[qoriq_t*],[])
+RTEMS_BSPOPTS_SET([QORIQ_HAS_WRITE_BACK_L1_CACHE],[*],[1])
+RTEMS_BSPOPTS_HELP([QORIQ_HAS_WRITE_BACK_L1_CACHE],[defined if the L1 cache supports write-back])
+
RTEMS_BSPOPTS_SET([QORIQ_CLUSTER_1_L2CSR0],[qoriq_t*],[0xfec20000])
RTEMS_BSPOPTS_SET([QORIQ_CLUSTER_1_L2CSR0],[*],[])
RTEMS_BSPOPTS_HELP([QORIQ_CLUSTER_1_L2CSR0],[address of Cluster 1 L2CSR0 register])
diff --git a/c/src/lib/libbsp/powerpc/qoriq/start/start.S b/c/src/lib/libbsp/powerpc/qoriq/start/start.S
index 959347c..6d6cd94 100644
--- a/c/src/lib/libbsp/powerpc/qoriq/start/start.S
+++ b/c/src/lib/libbsp/powerpc/qoriq/start/start.S
@@ -60,7 +60,14 @@ _start:
bl bsp_fdt_copy
#endif /* U_BOOT_USE_FDT */
+#ifdef QORIQ_HAS_WRITE_BACK_L1_CACHE
+ LWI r3, bsp_section_start_begin
+ LWI r4, bsp_section_data_load_end
+ sub r4, r4, r3
+ bl rtems_cache_flush_multiple_data_lines
+#else
bl qoriq_l1cache_invalidate
+#endif
#ifdef QORIQ_CLUSTER_1_L2CSR0
LWI r3, QORIQ_CLUSTER_1_L2CSR0
More information about the vc
mailing list