summaryrefslogtreecommitdiffstats
path: root/sys/cam/scsi/scsi_all.h
diff options
context:
space:
mode:
authormav <mav@FreeBSD.org>2014-07-12 02:26:11 +0000
committermav <mav@FreeBSD.org>2014-07-12 02:26:11 +0000
commitdcab9610fe2e1b87f31711e4413b53e4396696cf (patch)
treee5c7d07dfa5d2f585e90615e147529a39af04741 /sys/cam/scsi/scsi_all.h
parent38fbbeedcedd76022af18fe34319de1a4a5fd65a (diff)
downloadFreeBSD-src-dcab9610fe2e1b87f31711e4413b53e4396696cf.zip
FreeBSD-src-dcab9610fe2e1b87f31711e4413b53e4396696cf.tar.gz
MFC r267906:
Allow MODE SENSE commands through Write Exclusive persistent reservation, as required by SPC-4. Report that fact in persistent reservation capabilities.
Diffstat (limited to 'sys/cam/scsi/scsi_all.h')
-rw-r--r--sys/cam/scsi/scsi_all.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/sys/cam/scsi/scsi_all.h b/sys/cam/scsi/scsi_all.h
index be681fb..11a500c 100644
--- a/sys/cam/scsi/scsi_all.h
+++ b/sys/cam/scsi/scsi_all.h
@@ -308,6 +308,11 @@ struct scsi_per_res_cap
#define SPRI_PTPL_C 0x01
uint8_t flags2;
#define SPRI_TMV 0x80
+#define SPRI_ALLOW_MASK 0x70
+#define SPRI_ALLOW_0 0x00
+#define SPRI_ALLOW_1 0x10
+#define SPRI_ALLOW_2 0x20
+#define SPRI_ALLOW_3 0x30
#define SPRI_PTPL_A 0x01
uint8_t type_mask[2];
#define SPRI_TM_WR_EX_AR 0x8000
@@ -746,12 +751,16 @@ struct scsi_read_buffer
{
u_int8_t opcode;
u_int8_t byte2;
-#define RWB_MODE 0x07
+#define RWB_MODE 0x1F
#define RWB_MODE_HDR_DATA 0x00
#define RWB_MODE_VENDOR 0x01
#define RWB_MODE_DATA 0x02
+#define RWB_MODE_DESCR 0x03
#define RWB_MODE_DOWNLOAD 0x04
#define RWB_MODE_DOWNLOAD_SAVE 0x05
+#define RWB_MODE_ECHO 0x0A
+#define RWB_MODE_ECHO_DESCR 0x0B
+#define RWB_MODE_ERROR_HISTORY 0x1C
u_int8_t buffer_id;
u_int8_t offset[3];
u_int8_t length[3];
OpenPOWER on IntegriCloud