Merge tag 'net-6.12-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
[linux-2.6-block.git] / arch / arm / mach-shmobile / platsmp.c
CommitLineData
e2f2594b 1// SPDX-License-Identifier: GPL-2.0
1c51ed4f
MD
2/*
3 * SMP support for R-Mobile / SH-Mobile
4 *
5 * Copyright (C) 2010 Magnus Damm
c413521e 6 * Copyright (C) 2011 Paul Mundt
1c51ed4f
MD
7 *
8 * Based on vexpress, Copyright (C) 2002 ARM Ltd, All Rights Reserved
1c51ed4f
MD
9 */
10#include <linux/init.h>
cc61591e
MD
11#include <asm/cacheflush.h>
12#include <asm/smp_plat.h>
fd44aa5e 13#include "common.h"
1c51ed4f 14
cc61591e
MD
15extern unsigned long shmobile_smp_fn[];
16extern unsigned long shmobile_smp_arg[];
17extern unsigned long shmobile_smp_mpidr[];
18
19void shmobile_smp_hook(unsigned int cpu, unsigned long fn, unsigned long arg)
20{
21 shmobile_smp_fn[cpu] = 0;
22 flush_cache_all();
23
24 shmobile_smp_mpidr[cpu] = cpu_logical_map(cpu);
25 shmobile_smp_fn[cpu] = fn;
26 shmobile_smp_arg[cpu] = arg;
27 flush_cache_all();
28}
5c4dfcd6
MD
29
30#ifdef CONFIG_HOTPLUG_CPU
787047ee 31bool shmobile_smp_cpu_can_disable(unsigned int cpu)
5c4dfcd6 32{
787047ee 33 return true; /* Hotplug of any CPU is supported */
5c4dfcd6
MD
34}
35#endif