[patch] fix START_STOP method in HP/COMPAQ MSA Device Handler

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



When retry encountered, the count of retries is computed incorrectly,
since it is one less.

And a typo is also cleaned.

Signed-off-by: Hillf Danton <dhillf@xxxxxxxxx>
---

--- a/drivers/scsi/device_handler/scsi_dh_hp_sw.c	2010-11-01
19:54:12.000000000 +0800
+++ b/drivers/scsi/device_handler/scsi_dh_hp_sw.c	2010-11-17
20:57:58.000000000 +0800
@@ -216,7 +216,7 @@ static void start_stop_endio(struct requ
 		err = start_done(h->sdev, h->sense);
 		if (err == SCSI_DH_RETRY) {
 			err = SCSI_DH_IO;
-			if (--h->retry_cnt) {
+			if (h->retry_cnt--) {
 				blk_put_request(req);
 				err = hp_sw_start_stop(h);
 				if (err == SCSI_DH_OK)
@@ -343,7 +343,7 @@ static int hp_sw_bus_attach(struct scsi_
 	if (!scsi_dh_data) {
 		sdev_printk(KERN_ERR, sdev, "%s: Attach Failed\n",
 			    HP_SW_NAME);
-		return 0;
+		return -ENOMEM;
 	}

 	scsi_dh_data->scsi_dh = &hp_sw_dh;
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux