SCSI: Add TASK_ABORTED to status_byte macro
PATCH 1/1 SCSI: Add TASK_ABORTED to status_byte macro
Here is a refresh of an update to the status_byte macro.
Previous mail
http://marc.theaimsgroup.com/?l=linux-scsi&m=110322214824566&w=2
-andmike
--
Michael Anderson
[email protected]
Add TASK_ABORTED and ACA_ACTIVE to status_byte macro.
Signed-off-by Mike Anderson <[email protected]>
---
linux-2.6.11-andmike/drivers/scsi/scsi_error.c | 2 ++ linux-2.6.11-andmike/include/scsi/scsi.h | 6 ++++-- 2 files changed, 6 insertions(+), 2 deletions(-)
drivers/scsi/scsi_error.c renamed from drivers/scsi/scsi_error.c~tsk_abrt +2 -0
@@ -1373,6 +1373,7 @@ int scsi_decide_disposition(struct scsi_return ADD_TO_MLQUEUE ;case GOOD :case COMMAND_TERMINATED : +case TASK_ABORTED :return SUCCESS ;case CHECK_CONDITION : rtn =scsi_check_sense (scmd);
@@ -1386,6 +1387,7 @@ int scsi_decide_disposition(struct scsi_case CONDITION_GOOD :case INTERMEDIATE_GOOD :case INTERMEDIATE_C_GOOD : +case ACA_ACTIVE :/* * who knows? FIXME(eric) */
include/scsi/scsi.h renamed from include/scsi/scsi.h~tsk_abrt +4 -2
@@ -169,8 +169,10 @@ static inline int scsi_status_is_good(in#define RESERVATION_CONFLICT 0x0c#define COMMAND_TERMINATED 0x11#define QUEUE_FULL 0x14 +#define ACA_ACTIVE 0x18 +#define TASK_ABORTED 0x20 -#define STATUS_MASK 0x3e +#define STATUS_MASK 0xfe/* * SENSE KEYS
@@ -348,7 +350,7 @@ struct scsi_lun {* host_byte = set by low-level driver to indicate status. * driver_byte = set by mid-level. */ -#define status_byte (result) (((result) >> 1) & 0x1f) +#define status_byte (result) (((result) >> 1) & 0x7f)#define msg_byte (result) (((result) >> 8) & 0xff)#define host_byte (result) (((result) >> 16) & 0xff)#define driver_byte (result) (((result) >> 24) & 0xff)
_