Skip to content

scsi: remove devices in ALUA transitioning status

Hannes Reinecke linux-scsi 1 version Applied

Status from this message: Applied to 5.11/scsi-staging, thanks!

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 5 repliesApplied

Patches in v1 Applied

#Subject and filesSizeRepliesApplied
1/4block: return status code in blk_mq_end_request()block/blk-mq.c+1 -10 replies
2/4scsi_dh_alua: return BLK_STS_AGAIN for ALUA transitioning statedrivers/scsi/device_handler/scsi_dh_alua.c drivers/scsi/scsi_lib.c+6 -12 replies
3/4scsi_dh_alua: set 'transitioning' state on unit attentiondrivers/scsi/device_handler/scsi_dh_alua.c+8 -00 replies
4/4scsi: return BLK_STS_AGAIN for ALUA transitioningdrivers/scsi/scsi_lib.c+3 -00 replies

Reviews trailers per patch

None of the 4 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchEwan D. Milne
SeriesR-b
1/4
2/4
3/4
4/4

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/4] scsi: remove devices in ALUA transitioning status

Hi all,

during testing we found that there is an issue with dev_loss_tmo and devices in ALUA transitioning state.
What happens is that I/O gets requeued via BLK_STS_RESOURCE for these devices, so when dev_loss_tmo triggers the SCSI core cannot flush the request list as I/O is simply requeued.

So when the driver is trying to re-establish the device it'll wait for that last reference to drop in order to re-attach the device, but as I/O is still outstanding on the (old) device it'll wait for ever.

Fix this by returning 'BLK_STS_AGAIN' from scsi_dh_alua when the device is in ALUA transitioning, and also set the 'transitioning' state when scsi_dh_alua is receiving a sense code, and not only after scsi_dh_alua successfully received the response to a REPORT TARGET PORT GROUPS command.

Hannes Reinecke (4):
block: return status code in blk_mq_end_request()
scsi_dh_alua: return BLK_STS_AGAIN for ALUA transitioning state
scsi_dh_alua: set 'transitioning' state on unit attention
scsi: return BLK_STS_AGAIN for ALUA transitioning

 block/blk-mq.c                             |  2 +-
 drivers/scsi/device_handler/scsi_dh_alua.c | 10 +++++++++-
 drivers/scsi/scsi_lib.c                    |  8 ++++++++
 3 files changed, 18 insertions(+), 2 deletions(-)
Signature · 1 line
2.16.4