qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH for 2.10 20/35] arm/boot: fix undefined instruct


From: Philippe Mathieu-Daudé
Subject: Re: [Qemu-devel] [PATCH for 2.10 20/35] arm/boot: fix undefined instruction on secondary smp cpu bootloader
Date: Wed, 26 Jul 2017 20:00:00 -0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1

On 07/24/2017 06:06 PM, Peter Maydell wrote:
On 24 July 2017 at 19:27, Philippe Mathieu-Daudé <address@hidden> wrote:
In a ARM multicore system, write_secondary_boot() only initializes fixups for
FIXUP_GIC_CPU_IF and FIXUP_BOOTREG, while smpboot[] also uses FIXUP_DSB.
This results in write_bootloader() using uninitialized fixupcontext[FIXUP_DSB]
instruction in the bootloader code...

Hmm? The code does:

     if (arm_feature(&cpu->env, ARM_FEATURE_V7)) {
         fixupcontext[FIXUP_DSB] = DSB_INSN;
     } else {
         fixupcontext[FIXUP_DSB] = CP15_DSB_INSN;
     }

so fixupcontext[FIXUP_DSB] is guaranteed initialized,
as are FIXUP_GIC_CPU_IF and FIXUP_BOOTREG, which are
the only fixups that the smpboot[] code uses.

Indeed :)

Sorry for the noise, I'll add few hints to the analyzer.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]