[PATCH v2] ARM: initialize jump labels before setup_machine_fdt()

Jason A. Donenfeld Jason at zx2c4.com
Tue Jun 7 08:14:59 PDT 2022


Hey again,

On Tue, Jun 07, 2022 at 10:15:27AM +0100, Phil Elwell wrote:
> On 07/06/2022 09:43, Jason A. Donenfeld wrote:
> > Hi Phil,
> > 
> > On Tue, Jun 7, 2022 at 10:29 AM Phil Elwell <phil at raspberrypi.com> wrote:
> >>
> >> This patch is fatal for me in the downstream Raspberry Pi kernel - it locks up
> >> on boot even before the earlycon output is available. Hacking jump_label_init to
> >> skip the jump_entry for "crng_is_ready" allows it to boot, but is likely to have
> >> consequences further down the line.
> > 
> > Also, reading this a few times, I'm not 100% sure I understand what
> > you did to hack around this and why that works. Think you could paste
> > your hackpatch just out of interest to the discussion (but obviously
> > not to be applied)?
> 
> This is the minimal version of my workaround patch that at least allows the 
> board to boot. Bear in mind that it was written with no previous knowledge of 
> jump labels and was arrived at by iteratively bisecting the list of jump_labels 
> until the first dangerous one was found, then later working out that there was 
> only one.

Looks like this patch fails due to CONFIG_STRICT_KERNEL_RWX.
Investigating deeper now, but that for starters seems to be the
differentiating factor between my prior test rig and one that reproduces
the error. I assume your raspi also sets CONFIG_STRICT_KERNEL_RWX.

Jason



More information about the linux-arm-kernel mailing list