[PATCH v2 0/2] scsi: mpt3sas: Fix delayed not-responding sdev block handling
From: Jeff Layton
Date: Mon Nov 02 2026 - 08:46:18 EST
v2 fixes a couple of issues that Sashiko pointed out.
This fix is for a deadlock that we see regularly in Meta's fleet. The
idea is to break the deadlock by unblocking sdevs after a timeout.
I don't do a lot of SCSI driver work, but this one fell in my lap. I
leaned heavily on agentic help for this series.
If this looks good, it'd be nice to see this in linux-next soon.
Thanks,
Jeff
Signed-off-by: Jeff Layton <jlayton@xxxxxxxxxx>
---
Changes in v2:
- New patch 1: serialize the interrupt-time sdev block with hostdata
teardown in scsih_sdev_destroy() via new ioc->block_lock (fixes a
pre-existing UAF)
- Do the timed unblock under ioc->block_lock, so it can't race with an
interrupt-time block
- Clear block_deadline before the fw event worker polls a returning
device with TURs, so dnr_unblock_work can't unblock it mid-poll
- Link to v1: https://lore.kernel.org/r/20261030-sas-abba-v1-1-b8cdd714a37c@xxxxxxxxxx
---
Jeff Layton (2):
scsi: mpt3sas: Serialize interrupt-time sdev block with hostdata teardown
scsi: mpt3sas: Time out delayed not-responding device blocks
drivers/scsi/mpt3sas/mpt3sas_base.c | 10 +++
drivers/scsi/mpt3sas/mpt3sas_base.h | 10 +++
drivers/scsi/mpt3sas/mpt3sas_scsih.c | 142 +++++++++++++++++++++++++++++++++--
3 files changed, 156 insertions(+), 6 deletions(-)
---
base-commit: 65ba8f34ec886ec72b2c07ddc8cf3d815c32869d
change-id: 20261030-sas-abba-eacfcc45fe36
Best regards,
--
Jeff Layton <jlayton@xxxxxxxxxx>