Always disable dcache after the flush operation
The following sequence is advisable while disabling d-cache:
1. disable_dcache() - flushes and disables d-cache
2. invalidate_dcache_all() - invalid any entry that came to the cache
in the short period after the cache was flushed but before the
cache got disabled
Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
if (!(sctlr & CR_C))
return;
- set_sctlr(sctlr & ~(CR_C|CR_M));
-
flush_dcache_all();
__asm_invalidate_tlb_all();
+
+ set_sctlr(sctlr & ~(CR_C|CR_M));
}
int dcache_status(void)