Hi everyone,
I need to invalidate the cache between each process switch, in write-trough mode the hardware these instruction seems to do the job correctly :
mov r0, #0 # invalidate entire data cache MCR p15, #0, R0, c15, c5, #0 DSB # invalidate entire instruction cache MCR p15, #0, R0, c7, c5, #0 # ensures that all subsequent instruction fetches ISB
When in write-back mode, the cache is not flushed and we have a coherency problem. the only way we can get it to work with the write-back is to do a line-by-line invalidation of the cache which takes more time.
I just wanted to confirm if there is a single instruction to invalidate and flush the cache, or we absolutely need to go with the line-by-line approach when in write back mode ?
Thank you