Kernel panic (5.5.0-rc2) running "gpio readall"

Hello,

I’m getting a kernel panic just executing “gpio readall”, I’m missing something?

[    0.000000] Linux version 5.5.0-rc2 (khadas@3a97a4844f91) (gcc version 7.3.1 20180425 [linaro-7.3-2018.05 revision d29120a424ecfbc167ef90065c0eeb7f91977701] (Linaro GCC 7.3-2018.05)) #0.8.2 SMP PREEMPT Fri Jan 3 09:48:06 CST 2020
[    0.000000] Machine model: Khadas VIM3

root@Khadas:~# gpio readall
+------+-----+-------------------+------+---+----+--- Model  Kha
[   44.306249] SError Interrupt on CPU2, code 0xbf000002 -- SError
[   44.306251] CPU: 2 PID: 2682 Comm: gpio Tainted: G         C        5.5.0-rc2 #0.8.2
[   44.306252] Hardware name: Khadas VIM3 (DT)
[   44.306252] pstate: 60000005 (nZCv daif -PAN -UAO)
[   44.306253] pc : el0_sync_handler+0x158/0x188
[   44.306254] lr : el0_sync+0x140/0x180
[   44.306254] sp : ffff8000123bbeb0
[   44.306255] x29: ffff8000123bbeb0 x28: ffff000053fe3600 
[   44.306256] x27: 0000000000000000 x26: 0000000000000000 
[   44.306258] x25: 0000000000000000 x24: 0000000000000000 
[   44.306259] x23: 0000000080000000 x22: 0000ffff9174bc8c 
[   44.306260] x21: 00000000ffffffff x20: ffff800065b43000 
[   44.306261] x19: 0000000000000000 x18: 0000000000000000 
[   44.306262] x17: 0000000000000000 x16: 0000000000000000 
[   44.306263] x15: 0000000000000000 x14: 0000000000000000 
[   44.306264] x13: 0000000000000000 x12: 0000000000000000 
[   44.306266] x11: 0000000000000000 x10: 0000000000000000 
[   44.306267] x9 : 0000000000000000 x8 : 0000000000000000 
[   44.306268] x7 : 0000000000000000 x6 : 0000000000000000 
[   44.306269] x5 : 0000000000000000 x4 : ffff8000123bbec0 
[   44.306270] x3 : 000000009200004f x2 : 0000000000000000 
[   44.306271] x1 : 0000000000000024 x0 : 0000ffff9179c37c 
[   44.306273] Kernel panic - not syncing: Asynchronous SError Interrupt
[   44.306274] CPU: 2 PID: 2682 Comm: gpio Tainted: G         C        5.5.0-rc2 #0.8.2
[   44.306274] Hardware name: Khadas VIM3 (DT)
[   44.306275] Call trace:
[   44.306275]  dump_backtrace+0x0/0x1c0
[   44.306275]  show_stack+0x14/0x20
[   44.306276]  dump_stack+0xb4/0xdc
[   44.306276]  panic+0x160/0x34c
[   44.306277]  __stack_chk_fail+0x0/0x18
[   44.306277]  arm64_serror_panic+0x74/0x88
[   44.306278]  do_serror+0x70/0x138
[   44.306278]  el1_error+0x84/0x100
[   44.306279]  el0_sync_handler+0x158/0x188
[   44.306279]  el0_sync+0x140/0x180
[   44.306289] SMP: stopping secondary CPUs
[   44.306290] Kernel Offset: disabled
[   44.306290] CPU features: 0x00002,20002004
[   44.306291] Memory Limit: none

@damocles Which version firmware you use ?

Mainline kernel doesn’t support WiringPi.