]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
sh: Implement a default flush_dcache_all
authorTom Rini <trini@konsulko.com>
Wed, 19 Jun 2024 21:27:55 +0000 (15:27 -0600)
committerTom Rini <trini@konsulko.com>
Wed, 3 Jul 2024 20:42:01 +0000 (14:42 -0600)
Implement a weak default version of flush_dcache_all which is based on
the ARM default, which is to flush the entire range via
flush_dcache_range(...).

Acked-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Tom Rini <trini@konsulko.com>
arch/sh/cpu/sh4/cache.c

index 8c1839935ca1acf4b5a29fbe6bbef53cb05f99fb..f0cb39d6a923e3c4b0119026c6840ac10259d73c 100644 (file)
@@ -65,6 +65,15 @@ void flush_dcache_range(unsigned long start, unsigned long end)
        }
 }
 
+/*
+ * Default implementation:
+ * do a range flush for the entire range
+ */
+void flush_dcache_all(void)
+{
+       flush_dcache_range(0, ~0);
+}
+
 void invalidate_dcache_range(unsigned long start, unsigned long end)
 {
        u32 v;