HomeFreeBSD

cam(4): Fix quick unplug/replug for SCSI.

Description

cam(4): Fix quick unplug/replug for SCSI.

If some device is plugged back in after unplug before the probe periph
destroyed, it will just restart the probe process. But I've found that
PROBE_INQUIRY_CKSUM flag not cleared between the iterations may cause
AC_FOUND_DEVICE not reported on the second iteration, and because of
AC_LOST_DEVICE reported during the first iteration, the device end up
configured, but without any periphs attached.

We've found that enabled serial console and 102-disk JBOD cause enough
probe delays to easily trigger the issue for half of the disks. This
change fixes it reliably on my tests.

MFC after: 2 weeks
Sponsored by: iXsystems, Inc.

(cherry picked from commit 84d5b6bd68ce6496592adb8fdcd8cf0c246ed935)

Details

Provenance
mavAuthored on Aug 21 2021, 1:31 PM
Parents
rG0eb56e7496f6: vmm: Fix wrong assert in ivhd_dev_add_entry
Branches
Unknown
Tags
Unknown