aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
author <htejun@gmail.com>2005-04-03 14:59:11 -0500
committerJames Bottomley <jejb@titanic>2005-04-16 20:14:26 -0500
commit84011ae88da62a20b3ae7b48e2ae3b1ef0fc810a (patch)
treed88217ed9b422449888310fd49e1709b7e541d67 /include
parent97665e9c22991401dc56968619c6b8b9c09f3268 (diff)
[PATCH] scsi: remove meaningless scsi_cmnd->serial_number_at_timeout field
scsi_cmnd->serial_number_at_timeout doesn't serve any purpose anymore. All serial_number == serial_number_at_timeout tests are always true in abort callbacks. Kill the field. Also, as ->pid always equals ->serial_number and ->serial_number doesn't have any special meaning anymore, update comments above ->serial_number accordingly. Once we remove all uses of this field from all lldd's, this field should go. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'include')
-rw-r--r--include/scsi/scsi_cmnd.h22
1 files changed, 9 insertions, 13 deletions
diff --git a/include/scsi/scsi_cmnd.h b/include/scsi/scsi_cmnd.h
index ae45d6f8f98..07f5c699eaa 100644
--- a/include/scsi/scsi_cmnd.h
+++ b/include/scsi/scsi_cmnd.h
@@ -43,21 +43,17 @@ struct scsi_cmnd {
void (*done) (struct scsi_cmnd *); /* Mid-level done function */
/*
- * A SCSI Command is assigned a nonzero serial_number when internal_cmnd
- * passes it to the driver's queue command function. The serial_number
- * is cleared when scsi_done is entered indicating that the command has
- * been completed. If a timeout occurs, the serial number at the moment
- * of timeout is copied into serial_number_at_timeout. By subsequently
- * comparing the serial_number and serial_number_at_timeout fields
- * during abort or reset processing, we can detect whether the command
- * has already completed. This also detects cases where the command has
- * completed and the SCSI Command structure has already being reused
- * for another command, so that we can avoid incorrectly aborting or
- * resetting the new command.
- * The serial number is only unique per host.
+ * A SCSI Command is assigned a nonzero serial_number before passed
+ * to the driver's queue command function. The serial_number is
+ * cleared when scsi_done is entered indicating that the command
+ * has been completed. It currently doesn't have much use other
+ * than printk's. Some lldd's use this number for other purposes.
+ * It's almost certain that such usages are either incorrect or
+ * meaningless. Please kill all usages other than printk's. Also,
+ * as this number is always identical to ->pid, please convert
+ * printk's to use ->pid, so that we can kill this field.
*/
unsigned long serial_number;
- unsigned long serial_number_at_timeout;
int retries;
int allowed;