Blob Blame History Raw
From: Hannes Reinecke <hare@suse.de>
Date: Tue, 24 May 2022 07:56:31 +0200
Subject: [PATCH] scsi: core: Return BLK_STS_TRANSPORT for ALUA transitioning
Git-commit: b3bc1a88b534b3ef880a5124f3db45c149e601ee
Patch-mainline: v5.19-rc1
References: jsc#PED-1559

When the 'ALUA state transitioning' sense code is returned we cannot use
BLK_STS_AGAIN, as this has a very specific use-case.  So return
BLK_STS_TRANSPORT here.

Link: https://lore.kernel.org/r/20220524055631.85480-3-hare@suse.de
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Signed-off-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Acked-by: Hannes Reinecke <hare@suse.com>
---
 drivers/scsi/scsi_lib.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c
index e9db7da0c79c..6ffc9e4258a8 100644
--- a/drivers/scsi/scsi_lib.c
+++ b/drivers/scsi/scsi_lib.c
@@ -779,7 +779,7 @@ static void scsi_io_completion_action(struct scsi_cmnd *cmd, int result)
 					action = ACTION_DELAYED_RETRY;
 					break;
 				case 0x0a: /* ALUA state transition */
-					blk_stat = BLK_STS_AGAIN;
+					blk_stat = BLK_STS_TRANSPORT;
 					fallthrough;
 				default:
 					action = ACTION_FAIL;
-- 
2.35.3