|
@@ -81,25 +81,31 @@ ENDPROC(__flush_cache_user_range)
|
|
/*
|
|
/*
|
|
* __flush_dcache_area(kaddr, size)
|
|
* __flush_dcache_area(kaddr, size)
|
|
*
|
|
*
|
|
- * Ensure that the data held in the page kaddr is written back to the
|
|
|
|
- * page in question.
|
|
|
|
|
|
+ * Ensure that any D-cache lines for the interval [kaddr, kaddr+size)
|
|
|
|
+ * are cleaned and invalidated to the PoC.
|
|
*
|
|
*
|
|
* - kaddr - kernel address
|
|
* - kaddr - kernel address
|
|
* - size - size in question
|
|
* - size - size in question
|
|
*/
|
|
*/
|
|
ENTRY(__flush_dcache_area)
|
|
ENTRY(__flush_dcache_area)
|
|
- dcache_line_size x2, x3
|
|
|
|
- add x1, x0, x1
|
|
|
|
- sub x3, x2, #1
|
|
|
|
- bic x0, x0, x3
|
|
|
|
-1: dc civac, x0 // clean & invalidate D line / unified line
|
|
|
|
- add x0, x0, x2
|
|
|
|
- cmp x0, x1
|
|
|
|
- b.lo 1b
|
|
|
|
- dsb sy
|
|
|
|
|
|
+ dcache_by_line_op civac, sy, x0, x1, x2, x3
|
|
ret
|
|
ret
|
|
ENDPIPROC(__flush_dcache_area)
|
|
ENDPIPROC(__flush_dcache_area)
|
|
|
|
|
|
|
|
+/*
|
|
|
|
+ * __clean_dcache_area_pou(kaddr, size)
|
|
|
|
+ *
|
|
|
|
+ * Ensure that any D-cache lines for the interval [kaddr, kaddr+size)
|
|
|
|
+ * are cleaned to the PoU.
|
|
|
|
+ *
|
|
|
|
+ * - kaddr - kernel address
|
|
|
|
+ * - size - size in question
|
|
|
|
+ */
|
|
|
|
+ENTRY(__clean_dcache_area_pou)
|
|
|
|
+ dcache_by_line_op cvau, ish, x0, x1, x2, x3
|
|
|
|
+ ret
|
|
|
|
+ENDPROC(__clean_dcache_area_pou)
|
|
|
|
+
|
|
/*
|
|
/*
|
|
* __inval_cache_range(start, end)
|
|
* __inval_cache_range(start, end)
|
|
* - start - start address of region
|
|
* - start - start address of region
|