[PATCH] ARM: shmobile: Check MD21 at SMP boot in case of APMU

Magnus Damm magnus.damm at gmail.com
Mon Feb 17 06:14:31 EST 2014


On Mon, Feb 17, 2014 at 5:53 PM, Geert Uytterhoeven
<geert at linux-m68k.org> wrote:
> On Mon, Feb 17, 2014 at 7:31 AM, Magnus Damm <magnus.damm at gmail.com> wrote:
>> From: Magnus Damm <damm at opensource.se>
>>
>> On R-Car Gen2 SoCs such as r8a7790 and r8a7791 the hardware boot
>> mode bit MD21 indicates if hardware debug mode is enabled or not.
>>
>> In case hardware debug mode is enabled print a warning and refrain
>> from booting secondary CPU cores. Without this patch Koelsch boards
>> with SW8-4 set to OFF will hang at SMP boot.
>
> Ah, mine was set to OFF.
>
>> Signed-off-by: Magnus Damm <damm at opensource.se>
>
> Acked-by: Geert Uytterhoeven <geert at linux-m68k.org>

Thanks!

> with one minor nit:
>
>>  int shmobile_smp_apmu_boot_secondary(unsigned int cpu, struct task_struct *idle)
>>  {
>> +       /* Refrain boot when hardware debug mode is enabled */
>> +       if (rcar_gen2_read_mode_pins() & BIT(21)) {
>> +               pr_warn("Unable to boot CPU%d when MD21 is set\n", cpu);
>
> %u

Good catch, will send a V2.

Cheers,

/ magnus



More information about the linux-arm-kernel mailing list