[kernel] r16311 - in dists/sid/linux-2.6/debian: . patches/bugfix/all patches/series
Ben Hutchings
benh at alioth.debian.org
Sat Sep 18 17:55:31 UTC 2010
Author: benh
Date: Sat Sep 18 17:55:28 2010
New Revision: 16311
Log:
scsi_dh_emc: Fix mode select request setup (Closes: #591540)
Added:
dists/sid/linux-2.6/debian/patches/bugfix/all/SCSI-scsi_dh_emc-fix-mode-select-request-setup.patch
dists/sid/linux-2.6/debian/patches/bugfix/all/SCSI-scsi_dh_emc-request-flag-cleanup.patch
Modified:
dists/sid/linux-2.6/debian/changelog
dists/sid/linux-2.6/debian/patches/series/24
Modified: dists/sid/linux-2.6/debian/changelog
==============================================================================
--- dists/sid/linux-2.6/debian/changelog Sat Sep 18 16:48:53 2010 (r16310)
+++ dists/sid/linux-2.6/debian/changelog Sat Sep 18 17:55:28 2010 (r16311)
@@ -2,6 +2,7 @@
[ Ben Hutchings ]
* speakup: Update to match Debian package version 3.1.5.dfsg.1-1
+ * scsi_dh_emc: Fix mode select request setup (Closes: #591540)
-- Ben Hutchings <ben at decadent.org.uk> Sat, 18 Sep 2010 17:29:34 +0100
Added: dists/sid/linux-2.6/debian/patches/bugfix/all/SCSI-scsi_dh_emc-fix-mode-select-request-setup.patch
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ dists/sid/linux-2.6/debian/patches/bugfix/all/SCSI-scsi_dh_emc-fix-mode-select-request-setup.patch Sat Sep 18 17:55:28 2010 (r16311)
@@ -0,0 +1,63 @@
+From: Hannes Reinecke <hare at suse.de>
+Date: Wed, 2 Dec 2009 14:28:48 -0600
+Subject: [PATCH] [SCSI] scsi_dh_emc: fix mode select request setup
+
+commit 6c71dcb28ff9b63b814a0b76a256f5dae08d3e0d upstream.
+
+This patch fixes the request setup code for mode selects. I got the fixes from
+Hannes Reinecke while trying to hunt down some problems and merged it
+into one patch. I am sending it because Hannes is busy with other things.
+
+The patch fixes:
+- setting of the length for mode selects.
+- setting of the data direction for mode select 10.
+
+Signed-off-by: Hannes Reinecke <hare at suse.de>
+Signed-off-by: Mike Christie <michaelc at cs.wisc.edu>
+Signed-off-by: James Bottomley <James.Bottomley at suse.de>
+---
+ drivers/scsi/device_handler/scsi_dh_emc.c | 6 ++++--
+ 1 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/drivers/scsi/device_handler/scsi_dh_emc.c b/drivers/scsi/device_handler/scsi_dh_emc.c
+index 6196675..63032ec 100644
+--- a/drivers/scsi/device_handler/scsi_dh_emc.c
++++ b/drivers/scsi/device_handler/scsi_dh_emc.c
+@@ -272,7 +272,7 @@ static struct request *get_req(struct scsi_device *sdev, int cmd,
+ int len = 0;
+
+ rq = blk_get_request(sdev->request_queue,
+- (cmd == MODE_SELECT) ? WRITE : READ, GFP_NOIO);
++ (cmd != INQUIRY) ? WRITE : READ, GFP_NOIO);
+ if (!rq) {
+ sdev_printk(KERN_INFO, sdev, "get_req: blk_get_request failed");
+ return NULL;
+@@ -286,14 +286,17 @@ static struct request *get_req(struct scsi_device *sdev, int cmd,
+ len = sizeof(short_trespass);
+ rq->cmd_flags |= REQ_RW;
+ rq->cmd[1] = 0x10;
++ rq->cmd[4] = len;
+ break;
+ case MODE_SELECT_10:
+ len = sizeof(long_trespass);
+ rq->cmd_flags |= REQ_RW;
+ rq->cmd[1] = 0x10;
++ rq->cmd[8] = len;
+ break;
+ case INQUIRY:
+ len = CLARIION_BUFFER_SIZE;
++ rq->cmd[4] = len;
+ memset(buffer, 0, len);
+ break;
+ default:
+@@ -301,7 +304,6 @@ static struct request *get_req(struct scsi_device *sdev, int cmd,
+ break;
+ }
+
+- rq->cmd[4] = len;
+ rq->cmd_type = REQ_TYPE_BLOCK_PC;
+ rq->cmd_flags |= REQ_FAILFAST_DEV | REQ_FAILFAST_TRANSPORT |
+ REQ_FAILFAST_DRIVER;
+--
+1.7.1
+
Added: dists/sid/linux-2.6/debian/patches/bugfix/all/SCSI-scsi_dh_emc-request-flag-cleanup.patch
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ dists/sid/linux-2.6/debian/patches/bugfix/all/SCSI-scsi_dh_emc-request-flag-cleanup.patch Sat Sep 18 17:55:28 2010 (r16311)
@@ -0,0 +1,37 @@
+From: Mike Christie <michaelc at cs.wisc.edu>
+Date: Fri, 9 Apr 2010 22:07:37 -0500
+Subject: [PATCH] [SCSI] scsi_dh_emc: request flag cleanup
+
+commit 5738d4449c1baf05e8345684d12371f76296473d upstream.
+
+blk_get_request sets the cmd_flags, so we should not and do not
+need to set them. If we did set them to a different value then
+it can cause a oops in the elevator code.
+
+Signed-off-by: Mike Christie <michaelc at cs.wisc.edu>
+Signed-off-by: James Bottomley <James.Bottomley at suse.de>
+---
+ drivers/scsi/device_handler/scsi_dh_emc.c | 2 --
+ 1 files changed, 0 insertions(+), 2 deletions(-)
+
+diff --git a/drivers/scsi/device_handler/scsi_dh_emc.c b/drivers/scsi/device_handler/scsi_dh_emc.c
+index e8a0bc3..6faf472 100644
+--- a/drivers/scsi/device_handler/scsi_dh_emc.c
++++ b/drivers/scsi/device_handler/scsi_dh_emc.c
+@@ -285,13 +285,11 @@ static struct request *get_req(struct scsi_device *sdev, int cmd,
+ switch (cmd) {
+ case MODE_SELECT:
+ len = sizeof(short_trespass);
+- rq->cmd_flags |= REQ_RW;
+ rq->cmd[1] = 0x10;
+ rq->cmd[4] = len;
+ break;
+ case MODE_SELECT_10:
+ len = sizeof(long_trespass);
+- rq->cmd_flags |= REQ_RW;
+ rq->cmd[1] = 0x10;
+ rq->cmd[8] = len;
+ break;
+--
+1.7.1
+
Modified: dists/sid/linux-2.6/debian/patches/series/24
==============================================================================
--- dists/sid/linux-2.6/debian/patches/series/24 Sat Sep 18 16:48:53 2010 (r16310)
+++ dists/sid/linux-2.6/debian/patches/series/24 Sat Sep 18 17:55:28 2010 (r16311)
@@ -1 +1,3 @@
+ features/all/speakup/speakup-3.1.5.dfsg.1-1.patch
++ bugfix/all/SCSI-scsi_dh_emc-fix-mode-select-request-setup.patch
++ bugfix/all/SCSI-scsi_dh_emc-request-flag-cleanup.patch
More information about the Kernel-svn-changes
mailing list