[Bisected] PowerMac G5 fails booting kernel 6.6-rc3 (BUG: Unable to handle kernel data access at 0xfeffbb62ffec65fe)

Erhard Furtner erhard_f at mailbox.org
Wed Oct 18 21:34:18 AEDT 2023


On Wed, 18 Oct 2023 16:45:04 +1100
Michael Ellerman <mpe at ellerman.id.au> wrote:

> Thanks. Yeah text is generally better, it archives better and can be
> grepped etc. but in this case I was going a bit mad trying to make sense
> of the oops :)
> 
> In hindsight the bug is an obvious boot time ordering problem, can you
> confirm this fixes it. That should apply on top of Linus' current
> master.
> 
> cheers
> 
> diff --git a/arch/powerpc/kernel/setup-common.c b/arch/powerpc/kernel/setup-common.c
> index 2f1026fba00d..71f16fb32ceb 100644
> --- a/arch/powerpc/kernel/setup-common.c
> +++ b/arch/powerpc/kernel/setup-common.c
> @@ -948,6 +948,7 @@ void __init setup_arch(char **cmdline_p)
>  
>  	/* Parse memory topology */
>  	mem_topology_setup();
> +	set_max_mapnr(max_pfn);
>  
>  	/*
>  	 * Release secondary cpus out of their spinloops at 0x60 now that
> diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/mem.c
> index 8b121df7b08f..07e8f4f1e07f 100644
> --- a/arch/powerpc/mm/mem.c
> +++ b/arch/powerpc/mm/mem.c
> @@ -288,7 +288,6 @@ void __init mem_init(void)
>  #endif
>  
>  	high_memory = (void *) __va(max_low_pfn * PAGE_SIZE);
> -	set_max_mapnr(max_pfn);
>  
>  	kasan_late_init();
>  

Yes, this fix actually does the trick. v6.6-rc6 booting up fine now (dmesg attached) on the G5. Patch also applies on 6.5.7 with seemingly no side effects . Many thanks to all involved!

I'll check whether this also helps on a older memory related bug I bisected recently. And post the bug if not. ;)

Regards,
Erhard
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dmesg_66-rc6_g5
Type: application/octet-stream
Size: 44714 bytes
Desc: not available
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20231018/9af47f8a/attachment-0001.obj>


More information about the Linuxppc-dev mailing list