openharmony 鸿蒙 capi-scsi-peripheral-types-h

2026-08-25 浏览 (1)

scsi_peripheral_types.h

Overview

Provides the enum variables, structures, and macros used in the SCSI Peripheral DDK APIs.

File to include: <scsi_peripheral/scsi_peripheral_types.h>

Library: libscsi.z.so

System capability: SystemCapability.Driver.SCSI.Extension

Since: 18

Related module: ScsiPeripheralDDK

Summary

Structs

Nametypedef KeywordDescription
ScsiPeripheral_DeviceMemMapScsiPeripheral_DeviceMemMapRepresents the device memory mapping created by calling OH_ScsiPeripheral_CreateDeviceMemMap. The buffer that uses the device memory mapping can provide better performance.
ScsiPeripheral_IORequestScsiPeripheral_IORequestDefines the read/write operation request.
ScsiPeripheral_RequestScsiPeripheral_RequestDefines the request structure.
ScsiPeripheral_ResponseScsiPeripheral_ResponseDefines the response structure.
ScsiPeripheral_TestUnitReadyRequestScsiPeripheral_TestUnitReadyRequestDefines the request structure of the test unit ready command.
ScsiPeripheral_InquiryRequestScsiPeripheral_InquiryRequestDefines the request structure of the inquiry command.
ScsiPeripheral_InquiryInfoScsiPeripheral_InquiryInfoDefines the SCSI inquiry data.
ScsiPeripheral_ReadCapacityRequestScsiPeripheral_ReadCapacityRequestDefines the request structure of the read capacity command.
ScsiPeripheral_CapacityInfoScsiPeripheral_CapacityInfoSCSI read capacity.
ScsiPeripheral_RequestSenseRequestScsiPeripheral_RequestSenseRequestDefines the request structure of the Request Sense command.
ScsiPeripheral_BasicSenseInfoScsiPeripheral_BasicSenseInfoDefines the basic information about the sense data.
ScsiPeripheral_VerifyRequestScsiPeripheral_VerifyRequestDefines the request structure of the verify command.
ScsiPeripheral_DeviceScsiPeripheral_DeviceDefines the opaque SCSI device structure.

Enums

Nametypedef KeywordDescription
ScsiPeripheral_DdkErrCodeScsiPeripheral_DdkErrCodeEnumerates the SCSI Peripheral DDK error codes.
ScsiPeripheral_StatusScsiPeripheral_StatusEnumerates the SCSI status codes used for the response.

Enum Description

ScsiPeripheral_DdkErrCode

enum ScsiPeripheral_DdkErrCode

Description

Enumerates the SCSI Peripheral DDK error codes.

Since: 18

EnumDescription
SCSIPERIPHERAL_DDK_NO_PERM = 201Permission denied.
SCSIPERIPHERAL_DDK_INVALID_PARAMETER = 401Invalid parameter.
SCSIPERIPHERAL_DDK_SUCCESS = 31700000Operation success.
SCSIPERIPHERAL_DDK_MEMORY_ERROR = 31700001Memory-related errors, such as insufficient memory, memory data replication failure, or memory request failure.
SCSIPERIPHERAL_DDK_INVALID_OPERATION = 31700002Invalid operation.
SCSIPERIPHERAL_DDK_IO_ERROR = 31700003Device input/output operation failed.
SCSIPERIPHERAL_DDK_TIMEOUT = 31700004Transfer timeout.
SCSIPERIPHERAL_DDK_INIT_ERROR = 31700005DDK initialization error, or DDK uninitialized.
SCSIPERIPHERAL_DDK_SERVICE_ERROR = 31700006Communication with the SCSI Peripheral DDK failed.
SCSIPERIPHERAL_DDK_DEVICE_NOT_FOUND = 31700007Device not found.

ScsiPeripheral_Status

enum ScsiPeripheral_Status

Description

Enumerates the SCSI status codes used for the response.

Since: 18

EnumDescription
SCSIPERIPHERAL_STATUS_GOOD = 0x00Normal state.
SCSIPERIPHERAL_STATUS_CHECK_CONDITION_NEEDED = 0x02Status check required.
SCSIPERIPHERAL_STATUS_CONDITION_MET = 0x04Conditions met.
SCSIPERIPHERAL_STATUS_BUSY = 0x08Occupying.
SCSIPERIPHERAL_STATUS_RESERVATION_CONFLICT = 0x18Resource reservation conflict.
SCSIPERIPHERAL_STATUS_TASK_SET_FULL = 0x28Task set already full.
SCSIPERIPHERAL_STATUS_ACA_ACTIVE = 0x30ACA activity status.
SCSIPERIPHERAL_STATUS_TASK_ABORTED = 0x40Task aborted.

SCSIPERIPHERAL_MIN_DESCRIPTOR_FORMAT_SENSE

SCSIPERIPHERAL_MIN_DESCRIPTOR_FORMAT_SENSE 8

Description

Defines the minimum length of the sensing data in the descriptor format.

Since: 18

SCSIPERIPHERAL_MIN_FIXED_FORMAT_SENSE

SCSIPERIPHERAL_MIN_FIXED_FORMAT_SENSE 18

Description

Defines the minimum length of the sensing data in the fixed format.

Since: 18

SCSIPERIPHERAL_MAX_CMD_DESC_BLOCK_LEN

SCSIPERIPHERAL_MAX_CMD_DESC_BLOCK_LEN 16

Description

Maximum length of a command description block.

Since: 18

SCSIPERIPHERAL_MAX_SENSE_DATA_LEN

SCSIPERIPHERAL_MAX_SENSE_DATA_LEN 252

Description

Defines the maximum length of the sensing data.

Since: 18

SCSIPERIPHERAL_VENDOR_ID_LEN

SCSIPERIPHERAL_VENDOR_ID_LEN 8

Description

Defines the length of a vendor ID.

Since: 18

SCSIPERIPHERAL_PRODUCT_ID_LEN

SCSIPERIPHERAL_PRODUCT_ID_LEN 16

Description

Defines the length of a product ID.

Since: 18

SCSIPERIPHERAL_PRODUCT_REV_LEN

SCSIPERIPHERAL_PRODUCT_REV_LEN 4

Description

Defines the length of a product revision version.

Since: 18

你可能感兴趣的鸿蒙文章

openharmony 鸿蒙 capi-scsiperipheralddk-scsiperipheral-request

openharmony 鸿蒙 capi-usbddk-usbconfigdescriptor

openharmony 鸿蒙 capi-hidddk

openharmony 鸿蒙 capi-usbddk

openharmony 鸿蒙 capi-hidddk-hid-absaxesarray

openharmony 鸿蒙 capi-scsiperipheralddk-scsiperipheral-response

openharmony 鸿蒙 capi-scsi-peripheral-api-h

openharmony 鸿蒙 capi-hidddk-hid-relaxesarray

openharmony 鸿蒙 js-apis-driver-deviceManager

openharmony 鸿蒙 capi-hidddk-hid-eventtypearray

  • 所属分类: 后端技术
  • 本文标签: 鸿蒙 软件
  • 版权声明: 本文链接 https://seaxiang.com/blog/0EQFAUe2