summaryrefslogtreecommitdiffstats
path: root/sys/scsi/scsi_sense.c
diff options
context:
space:
mode:
authordufault <dufault@FreeBSD.org>1995-10-01 15:19:05 +0000
committerdufault <dufault@FreeBSD.org>1995-10-01 15:19:05 +0000
commite59ac78c69a43b6bc5d2ce22780fa871a2d2eb18 (patch)
tree5df00001ffab3f98f5c404823e7ffa304fd43657 /sys/scsi/scsi_sense.c
parenta60be9a7dffc9c97cd311efba960be54332e2060 (diff)
downloadFreeBSD-src-e59ac78c69a43b6bc5d2ce22780fa871a2d2eb18.zip
FreeBSD-src-e59ac78c69a43b6bc5d2ce22780fa871a2d2eb18.tar.gz
Say so if a sense code is vendor specific.
Diffstat (limited to 'sys/scsi/scsi_sense.c')
-rw-r--r--sys/scsi/scsi_sense.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/scsi/scsi_sense.c b/sys/scsi/scsi_sense.c
index a21496a..94c5cdf 100644
--- a/sys/scsi/scsi_sense.c
+++ b/sys/scsi/scsi_sense.c
@@ -283,6 +283,13 @@ static struct
char *scsi_sense_desc(int asc, int ascq)
{
int i;
+
+ if (asc >= 0x80 && asc <= 0xff)
+ return "Vendor Specific ASC";
+
+ if (ascq >= 0x80 && ascq <= 0xff)
+ return "Vendor Specific ASCQ";
+
for (i = 0; i < sizeof(tab) / sizeof(tab[0]); i++)
if (tab[i].asc == asc && tab[i].ascq == ascq)
return tab[i].desc;
OpenPOWER on IntegriCloud