]> rtime.felk.cvut.cz Git - sojka/nv-tegra/linux-3.10.git/commitdiff
arm64: mm: Add __clean_dcache_louis
authorKrishna Reddy <vdumpa@nvidia.com>
Mon, 6 Apr 2015 18:30:13 +0000 (11:30 -0700)
committerMatthew Pedro <mapedro@nvidia.com>
Thu, 14 May 2015 17:01:09 +0000 (10:01 -0700)
This allows perform L1 cache clean alone.

Bug 200077334

Change-Id: I776de6e6726862e330b626fd19f8ae8f70055538
Signed-off-by: Krishna Reddy <vdumpa@nvidia.com>
Reviewed-on: http://git-master/r/742254
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bibek Basu <bbasu@nvidia.com>
arch/arm64/mm/cache.S

index e64b6d8405e9931abbc86ddae9663f4c18ef023c..334d4f90c9b4eca25fe26dc15dadd3ae321abfbe 100644 (file)
@@ -102,6 +102,21 @@ ENTRY(__clean_dcache_all)
        v8_op_dcache_all csw
 ENDPROC(__clean_dcache_all)
 
+/*
+ *     __clean_dcache_louis()
+ *
+ *     Clean D-cache to the level of unification inner shareable
+ *
+ *     Corrupted registers: x0-x7, x9-x11
+ */
+ENTRY(__clean_dcache_louis)
+       dsb     sy                              // ensure ordering with previous memory accesses
+       mrs     x0, clidr_el1                   // read clidr
+       and     x3, x0, #0xe00000               // extract louis from clidr
+       lsr     x3, x3, #20                     // left align louis bit field
+       v8_op_dcache_all csw
+ENDPROC(__clean_dcache_louis)
+
 /*
  *     flush_cache_all()
  *