Skip to content

Commit

Permalink
MIPS: Netlogic: Split XLP L1 i-cache among threads
Browse files Browse the repository at this point in the history
Since we now use r4k cache code for Netlogic XLP, it is
better to split L1 icache among the active threads, so that
threads won't step on each other while flushing icache.

The L1 dcache is already split among the threads in the core.

Signed-off-by: Jayachandran C <jchandra@broadcom.com>
Patchwork: http://patchwork.linux-mips.org/patch/4787/
Signed-off-by: John Crispin <blogic@openwrt.org>
  • Loading branch information
Jayachandran C authored and John Crispin committed Feb 16, 2013
1 parent a264b5e commit a69ba62
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/mips/include/asm/netlogic/xlp-hal/cpucontrol.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@
#define CPU_BLOCKID_FPU 9
#define CPU_BLOCKID_MAP 10

#define ICU_DEFEATURE 0x100

#define LSU_DEFEATURE 0x304
#define LSU_DEBUG_ADDR 0x305
#define LSU_DEBUG_DATA0 0x306
Expand Down
6 changes: 6 additions & 0 deletions arch/mips/netlogic/common/smpboot.S
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,12 @@
#endif
mtcr t1, t0

li t0, ICU_DEFEATURE
mfcr t1, t0
ori t1, 0x1000 /* Enable Icache partitioning */
mtcr t1, t0


#ifdef XLP_AX_WORKAROUND
li t0, SCHED_DEFEATURE
lui t1, 0x0100 /* Disable BRU accepting ALU ops */
Expand Down

0 comments on commit a69ba62

Please sign in to comment.