summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/arch/armv7/include/arch/cache.h3
-rw-r--r--src/arch/armv7/lib/cache.c6
2 files changed, 9 insertions, 0 deletions
diff --git a/src/arch/armv7/include/arch/cache.h b/src/arch/armv7/include/arch/cache.h
index 31ed34579a..c00325629a 100644
--- a/src/arch/armv7/include/arch/cache.h
+++ b/src/arch/armv7/include/arch/cache.h
@@ -215,6 +215,9 @@ static inline void write_sctlr(unsigned int val)
/* dcache clean and invalidate all (on current level given by CCSELR) */
void dcache_clean_invalidate_all(void);
+/* dcache clean by modified virtual address to PoC */
+void dcache_clean_by_mva(unsigned long addr, unsigned long len);
+
/* dcache clean and invalidate by modified virtual address to PoC */
void dcache_clean_invalidate_by_mva(unsigned long addr, unsigned long len);
diff --git a/src/arch/armv7/lib/cache.c b/src/arch/armv7/lib/cache.c
index 8fb238af9b..63e406c03f 100644
--- a/src/arch/armv7/lib/cache.c
+++ b/src/arch/armv7/lib/cache.c
@@ -79,6 +79,7 @@ enum dcache_op {
OP_DCCISW,
OP_DCISW,
OP_DCCIMVAC,
+ OP_DCCMVAC,
};
/*
@@ -193,6 +194,11 @@ static void dcache_op_mva(unsigned long addr,
}
}
+void dcache_clean_by_mva(unsigned long addr, unsigned long len)
+{
+ dcache_op_mva(addr, len, OP_DCCMVAC);
+}
+
void dcache_clean_invalidate_by_mva(unsigned long addr, unsigned long len)
{
dcache_op_mva(addr, len, OP_DCCIMVAC);