NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

kern/52147: deadlock when booting from USB disk

>Number:         52147
>Category:       kern
>Synopsis:       deadlock when booting from USB disk
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Apr 09 10:25:00 +0000 2017
>Originator:     Michael van Elst
>Release:        NetBSD 7.99.67
                                Michael van Elst
                                "A potential Snark may lurk in every tree."
System: NetBSD hoppa 7.99.67 NetBSD 7.99.67 (HOPPA) #6: Sun Apr 9 02:46:58 CEST 2017 mlelstv@gossam:/home/netbsd-current/obj.evbarm/home/netbsd-current/src/sys/arch/evbarm/compile/HOPPA evbarm
Architecture: earmv6hf
Machine: evbarm

The latest changes to sd(4) to support FUA/DPO have a funny side effect
when booting from USB disk (on a modular kernel).

The requested settings trigger a SCSI error, since USB disks rarely support
these commands.

The scsipi layer tries to write error messages to the console using the
scsiverbose module.

On the first message, the scsiverbose module needs to be loaded from
the same disk that is currently in error processing.

-> instant deadlock.

Boot a system, in this case an RPI, with root on a USB disk.

There are several errors.

The FUA/DP0 support needs some refinement to not cause error messages
on devices that do not support these settings.

There needs to be some notion of "module load path is unavailable" so
that autoloading a module doesn't happen when this would cause a
deadlock. I think scsipi is the only such place for now. A quick
solution is to just load scsiverbose unconditionally instead of


Home | Main Index | Thread Index | Old Index