patch-2.4.6 linux/drivers/scsi/constants.c
Next file: linux/drivers/scsi/cpqfcTSinit.c
Previous file: linux/drivers/scsi/aic7xxx_old.c
Back to the patch index
Back to the overall index
- Lines: 29
- Date:
Tue Jun 12 11:17:17 2001
- Orig file:
v2.4.5/linux/drivers/scsi/constants.c
- Orig date:
Mon Jan 15 13:08:15 2001
diff -u --recursive --new-file v2.4.5/linux/drivers/scsi/constants.c linux/drivers/scsi/constants.c
@@ -689,7 +689,7 @@
kdev_t dev)
{
int i, s;
- int sense_class, valid, code;
+ int sense_class, valid, code, info;
const char * error = NULL;
sense_class = (sense_buffer[0] >> 4) & 0x07;
@@ -701,11 +701,14 @@
if(s > SCSI_SENSE_BUFFERSIZE)
s = SCSI_SENSE_BUFFERSIZE;
- if (!valid)
- printk("[valid=0] ");
- printk("Info fld=0x%x, ", (int)((sense_buffer[3] << 24) |
- (sense_buffer[4] << 16) | (sense_buffer[5] << 8) |
- sense_buffer[6]));
+ info = ((sense_buffer[3] << 24) | (sense_buffer[4] << 16) |
+ (sense_buffer[5] << 8) | sense_buffer[6]);
+ if (info || valid) {
+ printk("Info fld=0x%x", info);
+ if (!valid) /* info data not according to standard */
+ printk(" (nonstd)");
+ printk(", ");
+ }
if (sense_buffer[2] & 0x80)
printk( "FMK "); /* current command has read a filemark */
if (sense_buffer[2] & 0x40)
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)