Page MenuHomeFreeBSD

D62312.1796264750.diff
No OneTemporary

Authored By
Unknown
Size
869 B
Referenced Files
None
Subscribers
None

D62312.1796264750.diff

diff --git a/sys/dev/ufshci/ufshci_req_queue.c b/sys/dev/ufshci/ufshci_req_queue.c
--- a/sys/dev/ufshci/ufshci_req_queue.c
+++ b/sys/dev/ufshci/ufshci_req_queue.c
@@ -589,6 +589,8 @@
* Step 5. All previous commands were timeout.
* Recovery failed, reset the host controller.
*/
+ mtx_assert(&hwq->recovery_lock, MA_OWNED);
+
ufshci_printf(ctrlr,
"Recovery step 5: Resetting controller due to a timeout.\n");
hwq->recovery_state = RECOVERY_WAITING;
@@ -644,8 +646,13 @@
return;
}
- /* Abort Task failed. Perform recovery steps 2-5 */
+ /*
+ * Abort Task failed. Perform recovery steps 2-5 under the
+ * recovery lock, as the watchdog does.
+ */
+ mtx_lock(&tr->hwq->recovery_lock);
ufshci_req_queue_timeout_recovery(tr->hwq->ctrlr, tr->hwq);
+ mtx_unlock(&tr->hwq->recovery_lock);
} else {
mtx_unlock(&tr->hwq->qlock);
}

File Metadata

Mime Type
text/plain
Expires
Thu, Dec 3, 2:25 AM (20 h, 56 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
42164991
Default Alt Text
D62312.1796264750.diff (869 B)

Event Timeline