kernel 5.15 and 4.19 sparc64 boot panic

From: 2b57
Date: Fri Feb 04 2022 - 13:16:29 EST


Hi,

I'm trying to boot 5.15 kernel (Gentoo) on sparc64 machine (Sun Netra X1), and it crashes right in the beginning; same happens with Debian 10 (which should be using 4.19). There was something similar described here already: https://lkml.org/lkml/2012/2/13/64 , but it was almost 10 years ago. I don't believe it's the same issue, but it should be related:

PROMLIB: Sun IEEE Boot Prom 'OBP 4.0.18 2002/05/23 18:22'
PROMLIB: Root node compatible: sun4u
Linux version 5.15.16-gentoo-sparc64 (root@catalyst) (sparc64-unknown-linux-gnu-gcc (Gentoo 11.2.0 p1) 11.2.0, GNU ld (Gentoo 2.37_p1 p0) 2.37) #1 SMP Sat Jan 29 07:50:57 UTC 2022
printk: bootconsole [earlyprom0] enabled
ARCH: SUN4U
Ethernet address: 00:03:ba:36:42:cc
MM: PAGE_OFFSET is 0xfffff80000000000 (max_phys_bits == 40)
MM: VMALLOC [0x0000000100000000 --> 0x0000060000000000]
MM: VMEMMAP [0x0000060000000000 --> 0x00000c0000000000]
Kernel: Using 3 locked TLB entries for main kernel image.
Remapping the kernel...
done.
Unable to handle kernel NULL pointer dereference
tsk->{mm,active_mm}->context = 0000000000000000
tsk->{mm,active_mm}->pgd = fffff8005f002000
\|/ ____ \|/
"@'/ .. \`@"
/_| \__/ |_\
\__U_/
swapper(0): Oops [#1]
CPU: 0 PID: 0 Comm: swapper Not tainted 5.15.16-gentoo-sparc64 #1
TSTATE: 0000008880e01607 TPC: 0000000000764bc0 TNPC: 0000000000764bc4 Y: 00000000 Not tainted
TPC: <strchr+0x0/0x60>
g0: 0000000000000000 g1: 0000000000000001 g2: 000000000000002f g3: 000000000000006c
g4: 0000000000ca3940 g5: 0000000000000000 g6: 0000000000c34000 g7: 0000000000000000
o0: 0000000000000000 o1: 000000000000003a o2: 0000000000000022 o3: 0000000000000001
o4: fffff8005febe4d9 o5: fffff8005febe4d0 sp: 0000000000c37211 ret_pc: 00000000008f62e8
RPC: <of_find_node_opts_by_path+0x8/0x160>
l0: 00000000000286c4 l1: 0000000000c37b50 l2: 0000000000000049 l3: 0000000000000080
l4: 0000000000000013 l5: 0000000000000000 l6: 0000000000000000 l7: 0000000000000000
i0: 0000000000000000 i1: 0000000000000000 i2: 0000000001010101 i3: 0000000080808080
i4: fffff8005febe488 i5: 0000000000000000 i6: 0000000000c372c1 i7: 00000000008f7140
I7: <of_alias_scan+0x100/0x240>
Call Trace:
[<00000000008f7140>] of_alias_scan+0x100/0x240
[<0000000000dd6bf0>] prom_build_devicetree+0x18/0x38
[<0000000000ddae9c>] paging_init+0xa4c/0xdb8
[<0000000000dd602c>] setup_arch+0x284/0x6e4
[<0000000000dd2660>] start_kernel+0x54/0x6a0
[<0000000000aa0480>] tlb_fixup_done+0x4c/0x6c
[<000000000016b398>] 0x16b398
Disabling lock debugging due to kernel taint
Caller[00000000008f7140]: of_alias_scan+0x100/0x240
Caller[0000000000dd6bf0]: prom_build_devicetree+0x18/0x38
Caller[0000000000ddae9c]: paging_init+0xa4c/0xdb8
Caller[0000000000dd602c]: setup_arch+0x284/0x6e4
Caller[0000000000dd2660]: start_kernel+0x54/0x6a0
Caller[0000000000aa0480]: tlb_fixup_done+0x4c/0x6c
Caller[000000000016b398]: 0x16b398
Instruction DUMP:
913a2000
81c3e008
913a2000
<c20a0000>
852a6018
83286018
80a08001
0240000e
8738a018

Kernel panic - not syncing: Attempted to kill the idle task!
Press Stop-A (L1-A) from sun keyboard or send break
twice on console to return to the boot prom
---[ end Kernel panic - not syncing: Attempted to kill the idle task! ]---