On Sun, 16 Oct 2016, Matthieu Herrb wrote:
> my Sabre Lite board paniced during the night for the 1st time in several
> month. Here is the information I collected:
> kernel diagnostic assertion "p->p_wchan == NULL" failed: file
> n/kern_sched.c", line 333
This means a thread was somehow in the CPU's run-queue...but had a wait
channel as if it was waiting to be woken.
> ddb> ps
> TID PPID PGRP UID S FLAGS WAIT COMMAND
> 86009 0 0 0 2 0x40014200 miiaut idle0
Bingo: S=2 --> SRUN! Or in this case, WTF!? idle threads must *NEVER*
have a wait channel. That smells like someone called tsleep() from an
interrupt and arm doesn't have the low-level machinery to detect and panic
at the call.
mii_phy_auto() is the source of the "miiaut" wait channel; are the mii
flags not set right that it's taking the tsleep() path instead of