]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/spdk/include/spdk/scsi_spec.h
update sources to ceph Nautilus 14.2.1
[ceph.git] / ceph / src / spdk / include / spdk / scsi_spec.h
index e8d949a1d3099bae5552d6398a8d7c26d58dfcbe..22723f328c0c7b5c2d4a6b5e186b534792a35174 100644 (file)
@@ -39,7 +39,7 @@
 #ifndef SPDK_SCSI_SPEC_H
 #define SPDK_SCSI_SPEC_H
 
-#include <stdint.h>
+#include "spdk/stdinc.h"
 
 #include "spdk/assert.h"
 
@@ -102,6 +102,7 @@ enum spdk_scsi_asc {
        SPDK_SCSI_ASC_LOGICAL_UNIT_NOT_SUPPORTED = 0x25,
        SPDK_SCSI_ASC_WRITE_PROTECTED = 0x27,
        SPDK_SCSI_ASC_FORMAT_COMMAND_FAILED = 0x31,
+       SPDK_SCSI_ASC_SAVING_PARAMETERS_NOT_SUPPORTED = 0x39,
        SPDK_SCSI_ASC_INTERNAL_TARGET_FAILURE = 0x44,
 };
 
@@ -231,6 +232,8 @@ enum spdk_sbc_opcode {
        SPDK_SBC_VL_XPWRITE_32 = 0x0006,
 };
 
+#define SPDK_SBC_START_STOP_UNIT_START_BIT (1 << 0)
+
 enum spdk_mmc_opcode {
        /* MMC6 */
        SPDK_MMC_READ_DISC_STRUCTURE = 0xad,
@@ -327,6 +330,12 @@ enum spdk_spc_vpd {
        SPDK_SPC_VPD_BLOCK_THIN_PROVISION = 0xb2,
 };
 
+enum spdk_spc_peripheral_qualifier {
+       SPDK_SPC_PERIPHERAL_QUALIFIER_CONNECTED = 0,
+       SPDK_SPC_PERIPHERAL_QUALIFIER_NOT_CONNECTED = 1,
+       SPDK_SPC_PERIPHERAL_QUALIFIER_NOT_CAPABLE = 3,
+};
+
 enum {
        SPDK_SPC_PERIPHERAL_DEVICE_TYPE_DISK = 0x00,
        SPDK_SPC_PERIPHERAL_DEVICE_TYPE_TAPE = 0x01,
@@ -378,7 +387,8 @@ struct spdk_scsi_cdb_inquiry {
 SPDK_STATIC_ASSERT(sizeof(struct spdk_scsi_cdb_inquiry) == 6, "incorrect CDB size");
 
 struct spdk_scsi_cdb_inquiry_data {
-       uint8_t peripheral;
+       uint8_t peripheral_device_type : 5;
+       uint8_t peripheral_qualifier : 3;
        uint8_t rmb;
        uint8_t version;
        uint8_t response;
@@ -396,7 +406,8 @@ struct spdk_scsi_cdb_inquiry_data {
 };
 
 struct spdk_scsi_vpd_page {
-       uint8_t peripheral;
+       uint8_t peripheral_device_type : 5;
+       uint8_t peripheral_qualifier : 3;
        uint8_t page_code;
        uint8_t alloc_len[2];
        uint8_t params[];
@@ -486,7 +497,7 @@ struct spdk_scsi_unmap_bdesc {
        uint32_t reserved;
 };
 
-#define SPDK_SCSI_UNMAP_LBPU                   1 << 7
+#define SPDK_SCSI_UNMAP_LBPU                   1 << 7
 #define SPDK_SCSI_UNMAP_LBPWS                  1 << 6
 #define SPDK_SCSI_UNMAP_LBPWS10                        1 << 5