summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorKenneth R Westerback <krw@cvs.openbsd.org>2020-09-02 22:00:27 +0000
committerKenneth R Westerback <krw@cvs.openbsd.org>2020-09-02 22:00:27 +0000
commit51cf437f393031fc9487e6e9bc85fc0588c3ea11 (patch)
treeaa1fc3f86b20796c49d5ec58b2404d59a997ccba /sys
parent9c6ad5050b4e29663cd26a07838ebdaa3f9bd466 (diff)
When building emulated INQUIRY results use the SCSI_REV_* #define's to
initialize the 'version' field. Not numbers.
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/ic/twe.c4
-rw-r--r--sys/dev/pv/vioblk.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/sys/dev/ic/twe.c b/sys/dev/ic/twe.c
index b277a592299..497eca1d8eb 100644
--- a/sys/dev/ic/twe.c
+++ b/sys/dev/ic/twe.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: twe.c,v 1.59 2020/09/01 12:17:53 krw Exp $ */
+/* $OpenBSD: twe.c,v 1.60 2020/09/02 22:00:26 krw Exp $ */
/*
* Copyright (c) 2000-2002 Michael Shalayeff. All rights reserved.
@@ -829,7 +829,7 @@ twe_scsi_cmd(xs)
(sc->sc_hdr[target].hd_devtype & 4) ? T_CDROM : T_DIRECT;
inq.dev_qual2 =
(sc->sc_hdr[target].hd_devtype & 1) ? SID_REMOVABLE : 0;
- inq.version = 2;
+ inq.version = SCSI_REV_2;
inq.response_format = 2;
inq.additional_length = 32;
strlcpy(inq.vendor, "3WARE ", sizeof inq.vendor);
diff --git a/sys/dev/pv/vioblk.c b/sys/dev/pv/vioblk.c
index dedde088838..f399474f05c 100644
--- a/sys/dev/pv/vioblk.c
+++ b/sys/dev/pv/vioblk.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vioblk.c,v 1.27 2020/09/01 12:17:53 krw Exp $ */
+/* $OpenBSD: vioblk.c,v 1.28 2020/09/02 22:00:26 krw Exp $ */
/*
* Copyright (c) 2012 Stefan Fritsch.
@@ -573,7 +573,7 @@ vioblk_scsi_inq(struct scsi_xfer *xs)
bzero(&inqd, sizeof(inqd));
inqd.device = T_DIRECT;
- inqd.version = 0x05; /* SPC-3 */
+ inqd.version = SCSI_REV_SPC3;
inqd.response_format = 2;
inqd.additional_length = 32;
inqd.flags |= SID_CmdQue;