[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAK8P3a15Q=97iWyGu6=2aKfVtrYNL2BgmszHqoqYxFT_uHoP4A@mail.gmail.com>
Date: Mon, 30 Nov 2020 14:42:41 +0100
From: Arnd Bergmann <arnd@...nel.org>
To: Daniel Palmer <daniel@...f.com>
Cc: DTML <devicetree@...r.kernel.org>,
Linux ARM <linux-arm-kernel@...ts.infradead.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Arnd Bergmann <arnd@...db.de>, Rob Herring <robh@...nel.org>,
Willy Tarreau <w@....eu>
Subject: Re: [PATCH 9/9] ARM: mstar: SMP support
On Mon, Nov 30, 2020 at 2:10 PM Daniel Palmer <daniel@...f.com> wrote:
> +#ifdef CONFIG_SMP
> +static int mstarv7_boot_secondary(unsigned int cpu, struct task_struct *idle)
> +{
> + struct device_node *np;
> + u32 bootaddr = (u32) __pa_symbol(secondary_startup_arm);
> + void __iomem *smpctrl = 0;
The initialization is wrong here: it's not a pointer and the value '0'
is not useful.
> +struct smp_operations __initdata mstarv7_smp_ops = {
> + .smp_boot_secondary = mstarv7_boot_secondary,
> +};
> +#endif
So no hotplug operations?
> @@ -78,4 +125,7 @@ static void __init mstarv7_init(void)
> DT_MACHINE_START(MSTARV7_DT, "MStar/Sigmastar Armv7 (Device Tree)")
> .dt_compat = mstarv7_board_dt_compat,
> .init_machine = mstarv7_init,
> +#ifdef CONFIG_SMP
> + .smp = smp_ops(mstarv7_smp_ops),
> +#endif
> MACHINE_END
Drop the #ifdef, smp_ops() already makes the assignment conditional.
Or better, use CPU_METHOD_OF_DECLARE() instead of smp_ops.
Arnd
Powered by blists - more mailing lists