]> git.baikalelectronics.ru Git - kernel.git/commit
metag: Cache/TLB handling
authorJames Hogan <james.hogan@imgtec.com>
Tue, 9 Oct 2012 09:54:17 +0000 (10:54 +0100)
committerJames Hogan <james.hogan@imgtec.com>
Sat, 2 Mar 2013 20:09:19 +0000 (20:09 +0000)
commit4eb434a115576f80f78a9c8daf05114ca78ce447
treefb34d1df645d7eee43fe2441fd4938b0da7bad6f
parent095771d9eb048b9c0eb061113e68dfe6f859193b
metag: Cache/TLB handling

Add cache and TLB handling code for metag, including the required
callbacks used by MM switches and DMA operations. Caches can be
partitioned between the hardware threads and the global space, however
this is usually configured by the bootloader so Linux doesn't make any
changes to this configuration. TLBs aren't configurable, so only need
consideration to flush them.

On Meta1 the L1 cache was VIVT which required a full flush on MM switch.
Meta2 has a VIPT L1 cache so it doesn't require the full flush on MM
switch. Meta2 can also have a writeback L2 with hardware prefetch which
requires some special handling. Support is optional, and the L2 can be
detected and initialised by Linux.

Signed-off-by: James Hogan <james.hogan@imgtec.com>
arch/metag/include/asm/cache.h [new file with mode: 0644]
arch/metag/include/asm/cacheflush.h [new file with mode: 0644]
arch/metag/include/asm/l2cache.h [new file with mode: 0644]
arch/metag/include/asm/tlb.h [new file with mode: 0644]
arch/metag/include/asm/tlbflush.h [new file with mode: 0644]
arch/metag/mm/cache.c [new file with mode: 0644]
arch/metag/mm/l2cache.c [new file with mode: 0644]