Greg Steuck <gne...@openbsd.org> writes: > I don't see anything suspicious (at the end) having added the prints > to the Mark's patch (immediately below). > > One observation: sometimes it takes a long time of IO failures (like > shell commands yielding "Input/output error") before the crash. Maybe > something else is going on? Interrupts not getting reenabled? I > don't know how this could lead to the eventual crash as don't understand > what's going on at this layer.
Since I don't understand it, I decided to look in some well-lit places. I added nvme_dumpregs(sc); before return (0) in nvme_resume() and at the start of nvme_shutdown. In both cases the dumped values are identical. So whatever state differs is not displayed here. nvme1: cap 0x00000020ff01ffff nvme1: mpsmax 12 (4096) nvme1: mpsmin 12 (4096) nvme1: css 1 nvme1: nssrs 0 nvme1: dstrd 4 nvme1: to 127500 msec nvme1: ams 0 nvme1: cqr 65536 nvme1: mqes 65536 nvme1: vs 0x10300 nvme1: cc 0x460001 nvme1: iocqes 4 nvme1: iosqes 6 nvme1: shn 0 nvme1: ams 0 nvme1: mps 12 nvme1: css 0 nvme1: en 1 nvme1: csts 0x00000001 nvme1: aqa 0x007f007f nvme1: asq 0x00000000bd133000 nvme1: acq 0x00000000bd0f6000 nvme_shutdown:546 nvme1 0xffff800000254580 nvme_shutdown:552 nvme1 0x0 nvme_resume:458 nvme1 0x0 nvme_resume:460 nvme1 0xffff800001184a80 nvme1: cap 0x00000020ff01ffff nvme1: mpsmax 12 (4096) nvme1: mpsmin 12 (4096) nvme1: css 1 nvme1: nssrs 0 nvme1: dstrd 4 nvme1: to 127500 msec nvme1: ams 0 nvme1: cqr 65536 nvme1: mqes 65536 nvme1: vs 0x10300 nvme1: cc 0x460001 nvme1: iocqes 4 nvme1: iosqes 6 nvme1: shn 0 nvme1: ams 0 nvme1: mps 12 nvme1: css 0 nvme1: en 1 nvme1: csts 0x00000001 nvme1: aqa 0x007f007f nvme1: asq 0x00000000bd133000 nvme1: acq 0x00000000bd0f6000