From: Kurt Martin Date: Thu, 9 Jul 2009 02:22:35 +0000 (-0700) Subject: MIPS: SMTC: Move cross VPE writes to after a TC is assigned to VPE. X-Git-Tag: v3.0~8277^2~23 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d8e5f9fe5dab0e07985f2456cb6cc57788f53131;p=platform%2Fkernel%2Flinux-amlogic.git MIPS: SMTC: Move cross VPE writes to after a TC is assigned to VPE. Signed-off-by: Chris Dearman Signed-off-by: Raghu Gandham Signed-off-by: Ralf Baechle --- diff --git a/arch/mips/kernel/smtc.c b/arch/mips/kernel/smtc.c index 8a0626c..c16bb6d 100644 --- a/arch/mips/kernel/smtc.c +++ b/arch/mips/kernel/smtc.c @@ -465,11 +465,8 @@ void smtc_prepare_cpus(int cpus) smtc_configure_tlb(); for (tc = 0, vpe = 0 ; (vpe < nvpe) && (tc < ntc) ; vpe++) { - /* - * Set the MVP bits. - */ - settc(tc); - write_vpe_c0_vpeconf0(read_vpe_c0_vpeconf0() | VPECONF0_MVP); + if (tcpervpe[vpe] == 0) + continue; if (vpe != 0) printk(", "); printk("VPE %d: TC", vpe); @@ -488,6 +485,12 @@ void smtc_prepare_cpus(int cpus) } if (vpe != 0) { /* + * Allow this VPE to control others. + */ + write_vpe_c0_vpeconf0(read_vpe_c0_vpeconf0() | + VPECONF0_MVP); + + /* * Clear any stale software interrupts from VPE's Cause */ write_vpe_c0_cause(0);