Page MenuHomeFreeBSD

ufshci: do not reset the device in the XPT_RESET_DEV handler
ClosedPublic

Authored by jaeyoon on Aug 5 2026, 8:15 AM.
Tags
None
Referenced Files
F171429954: D58671.id183434.diff
Fri, Sep 11, 2:33 AM
F171412657: D58671.id183434.diff
Fri, Sep 11, 12:04 AM
F171372619: D58671.diff
Thu, Sep 10, 6:26 PM
F171363426: D58671.id183434.diff
Thu, Sep 10, 4:52 PM
F171338091: D58671.id183768.diff
Thu, Sep 10, 12:58 PM
Unknown Object (File)
Thu, Sep 10, 4:15 AM
Unknown Object (File)
Tue, Sep 8, 12:24 AM
Unknown Object (File)
Mon, Sep 7, 10:58 PM
Subscribers
None

Details

Summary

CAM calls the SIM action callback with the SIM lock and the CAM
device lock held. The XPT_RESET_DEV handler called
ufshci_dev_reset(), which sleeps on device commands. Sleeping there
panics when another thread contends for the lock: "panic: sleeping
thread holds CAM device lock".

Report success without touching the device, as nvme_sim(4) does.
A real device reset needs the controller reset path. That rework is
planned together with in-flight request recovery.

Sponsored by: Samsung Electronics

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable