aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/scsi_proc.c
diff options
context:
space:
mode:
authorAlan Stern <stern@rowland.harvard.edu>2007-01-08 11:07:41 -0500
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2007-02-16 12:12:07 -0500
commit74feb53e8b5020e790e12c6331cbe885d276cc60 (patch)
tree1ee19f22efedd19bb686c1ee93d5301409d1ba72 /drivers/scsi/scsi_proc.c
parentcc5968c83edc8c797177db3adf95beafa2b7f365 (diff)
[SCSI] scsi_proc.c: display sdev->scsi_level correctly
This patch (as833) fixes the "SCSI revision" output for /proc/scsi/scsi. If the scsi_level value is 0 (UNKNOWN), we want it to show up as "0", not "ffffffff". Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/scsi_proc.c')
-rw-r--r--drivers/scsi/scsi_proc.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/scsi/scsi_proc.c b/drivers/scsi/scsi_proc.c
index 69d6e9b198c4..bb6f051beda8 100644
--- a/drivers/scsi/scsi_proc.c
+++ b/drivers/scsi/scsi_proc.c
@@ -179,9 +179,8 @@ static int proc_print_scsidevice(struct device *dev, void *data)
179 seq_printf(s, "\n"); 179 seq_printf(s, "\n");
180 180
181 seq_printf(s, " Type: %s ", scsi_device_type(sdev->type)); 181 seq_printf(s, " Type: %s ", scsi_device_type(sdev->type));
182 seq_printf(s, " ANSI" 182 seq_printf(s, " ANSI SCSI revision: %02x",
183 " SCSI revision: %02x", (sdev->scsi_level - 1) ? 183 sdev->scsi_level - (sdev->scsi_level > 1));
184 sdev->scsi_level - 1 : 1);
185 if (sdev->scsi_level == 2) 184 if (sdev->scsi_level == 2)
186 seq_printf(s, " CCS\n"); 185 seq_printf(s, " CCS\n");
187 else 186 else