Skip to contentSkip to conversation

Patch "scsi_dh_rdac: always retry MODE SELECT on command lock violation" has been added to the 3.14-stable tree

PATCH [email protected] 1 participant 1 message Feb 24, 2016

Subsystems (2)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

scsi_dh_rdac: always retry MODE SELECT on command lock violation

to the 3.14-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
scsi_dh_rdac-always-retry-mode-select-on-command-lock-violation.patch
and it can be found in the queue-3.14 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From d2d06d4fe0f2cc2df9b17fefec96e6e1a1271d91 Mon Sep 17 00:00:00 2001

From: Hannes Reinecke <[email protected]>
Date: Fri, 22 Jan 2016 15:42:41 +0100
Subject: scsi_dh_rdac: always retry MODE SELECT on command lock violation

From: Hannes Reinecke <[email protected]>

commit d2d06d4fe0f2cc2df9b17fefec96e6e1a1271d91 upstream.

If MODE SELECT returns with sense '05/91/36' (command lock violation) it should always be retried without counting the number of retries. During an HBA upgrade or similar circumstances one might see a flood of MODE SELECT command from various HBAs, which will easily trigger the sense code and exceed the retry count.

---
 drivers/scsi/device_handler/scsi_dh_rdac.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/scsi/device_handler/scsi_dh_rdac.c +3 -1
@@ -569,7 +569,7 @@ static int mode_select_handle_sense(stru
 			/*
 			 * Command Lock contention
 			 */
-			err = SCSI_DH_RETRY;
+			err = SCSI_DH_IMM_RETRY;
 		break;
 	default:
 		break;
@@ -619,6 +619,8 @@ retry:
 		err = mode_select_handle_sense(sdev, h->sense);
 		if (err == SCSI_DH_RETRY && retry_cnt--)
 			goto retry;
+		if (err == SCSI_DH_IMM_RETRY)
+			goto retry;
 	}
 	if (err == SCSI_DH_OK) {
 		h->state = RDAC_STATE_ACTIVE;

Patches currently in stable-queue which might be from [email protected] are

queue-3.14/scsi_sysfs-fix-queue_ramp_up_period-return-code.patch queue-3.14/scsi_dh_rdac-always-retry-mode-select-on-command-lock-violation.patch queue-3.14/iscsi-target-fix-potential-dead-lock-during-node-acl-delete.patch queue-3.14/fix-a-memory-leak-in-scsi_host_dev_release.patch