Commit dccfb4c4 ("MIPS: BMIPS: support booting from physical CPU other
than 0") introduces the following warning when building for non
BMIPS43xx builds:
arch/mips/kernel/smp-bmips.c:150:6: error: unused variable 'tpid'
[-Werror=unused-variable]
Fix this by getting rid of this variable and directly using
cpu_logical_map(cpu).
Signed-off-by: Florian Fainelli <florian@openwrt.org>
---
Ralf,
You might want to fold this into the commit that actually introduced the
build warning.
Thanks!
arch/mips/kernel/smp-bmips.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/arch/mips/kernel/smp-bmips.c b/arch/mips/kernel/smp-bmips.c
index 62c5c7c..aea6c08 100644
--- a/arch/mips/kernel/smp-bmips.c
+++ b/arch/mips/kernel/smp-bmips.c
@@ -147,7 +147,6 @@ static void bmips_prepare_cpus(unsigned int max_cpus)
*/
static void bmips_boot_secondary(int cpu, struct task_struct *idle)
{
- int tpid = cpu_logical_map(cpu);
bmips_smp_boot_sp = __KSTK_TOS(idle);
bmips_smp_boot_gp = (unsigned long)task_thread_info(idle);
mb();@@ -174,7 +173,7 @@ static void bmips_boot_secondary(int cpu, struct task_struct *idle)
else {
#if defined(CONFIG_CPU_BMIPS4350) || defined(CONFIG_CPU_BMIPS4380)
/* Reset slave TP1 if booting from TP0 */
- if (tpid == 0)
+ if (cpu_logical_map(cpu) == 0)
set_c0_brcm_cmt_ctrl(0x01);
#elif defined(CONFIG_CPU_BMIPS5000)
if (cpu & 0x01)--
1.8.1.2