Enable/Disable cache on MIPS
Hi,
I am working on a MIPS 4KSd core, and I'm having trouble understanding
what operation code to use for the cache instruction. I read somewhere
that 'Hit type' is generally used for running cache maintainence, and
'Index Type' is used for initialization. Does invalidate, flush,
enable/disable and lock come under maintainence?
I am trying to enable/disable instruction and data cache, and I don't
see what op code I need to use.
For example in ARM, we can just do it in a read-modify-write sequence.
Eg. To disable I cache
MRC p15,0,r0,c1,c0,0 ; read CP15 register 1 into
r0
BIC r0,r0,#(0x1 <<12) ; Disable I Cache
MCR p15,0,r0,c1,c0,0 ; write value back
How do I go about doing this on a MIPS processor?
Any help would be appreciated.
Thanks,
Larina
.
Relevant Pages
- Enable/Disable cache on MIPS
... what operation code to use for the cache instruction. ... How do I go about doing this on a MIPS processor? ... (comp.arch.embedded) - Re: [PATCH 1/3] Fix COW D-cache aliasing on fork
... kernel virtual address which will fall into the same cache color as ... Since he does this for every page touched on the kernel side during ... No MIPS processor has something like that. ... D-cache PIPT, I-cache PIPT ... (Linux-Kernel) - Re: [Fwd: Re: connector is missing in 2.6.12-rc2-mm1]
... >> and only instruction not data cache sync on SMP. ... > On MIPS, all the MIPS atomic operations will operate on cached memory. ... this SYNC instruction seems unnecessary even on SMP. ... architecture only offers very weak coherency guarantees. ... (Linux-Kernel) - Re: [Fwd: Re: connector is missing in 2.6.12-rc2-mm1]
... On MIPS, all the MIPS atomic operations will operate on cached memory. ... And as far as a uniprocessor cpu is concerned, updating the cache is ... this SYNC instruction seems unnecessary even on SMP. ... do an atomic.h operation on uncached memory. ... (Linux-Kernel) - Re: Microcontroller suggestions
... Will reach your 150 MIPS for critical loops since you can run from the ... I assume you can lock the cache as well ... meaningless if comparing an ARM instruction set with an AVR32 (or any other ... non ARM) instructions set. ... (comp.sys.arm) |
|