RT-Thread RTOS 1.2.0
An open source embedded real-time operating system
载入中...
搜索中...
未找到
scsi.h 文件参考
#include <rthw.h>
#include <rtthread.h>
#include <drivers/byteorder.h>
+ scsi.h 的引用(Include)关系图:
+ 此图展示该文件被哪些文件直接或间接地引用了:

浏览该文件的源代码.

结构体

struct  rt_scsi_mode_select_data
 
struct  rt_scsi_cmd
 
struct  rt_scsi_host
 
struct  rt_scsi_device
 
struct  rt_scsi_ops
 

宏定义

#define RT_SCSI_LUN_SHIFT   5
 
#define RT_SCSI_DEVTYPE_MASK   31
 
#define RT_SCSI_REMOVABLE_BIT   7
 
#define RT_SCSI_UNMAP_SHIFT   3
 
#define RT_SCSI_PF_SHIFT   4
 
#define RT_SCSI_RTD_SHIFT   1
 
#define RT_SCSI_SP_SHIFT   0
 
#define RT_SCSI_DBD_SHIFT   3
 
#define RT_SCSI_LLBAA_SHIFT   4
 
#define RT_SCSI_PC_SHIFT   6
 
#define RT_SCSI_PAGE_CODE_SHIFT   0
 
#define RT_SCSI_CMD_TEST_UNIT_READY   0x00
 
#define RT_SCSI_CMD_REQUEST_SENSE   0x03
 
#define RT_SCSI_CMD_INQUIRY   0x12
 
#define RT_SCSI_CMD_MODE_SELECT   0x15
 
#define RT_SCSI_CMD_MODE_SENSE   0x1a
 
#define RT_SCSI_CMD_READ_CAPACITY10   0x25
 
#define RT_SCSI_CMD_READ10   0x28
 
#define RT_SCSI_CMD_WRITE10   0x2a
 
#define RT_SCSI_CMD_SYNCHRONIZE_CACHE10   0x35
 
#define RT_SCSI_CMD_WRITE_SAME10   0x41
 
#define RT_SCSI_CMD_MODE_SELECT10   0x55
 
#define RT_SCSI_CMD_MODE_SENSE10   0x5a
 
#define RT_SCSI_CMD_READ16   0x88
 
#define RT_SCSI_CMD_WRITE16   0x8a
 
#define RT_SCSI_CMD_SYNCHRONIZE_CACHE16   0x91
 
#define RT_SCSI_CMD_WRITE_SAME16   0x93
 
#define RT_SCSI_CMD_READ_CAPACITY16   0x9e
 
#define RT_SCSI_CMD_READ12   0xa8
 
#define RT_SCSI_CMD_WRITE12   0xaa
 

枚举

enum  {
  SCSI_DEVICE_TYPE_DIRECT = 0x00 , SCSI_DEVICE_TYPE_SEQUENTIAL = 0x01 , SCSI_DEVICE_TYPE_PRINTER = 0x02 , SCSI_DEVICE_TYPE_PROCESSOR = 0x03 ,
  SCSI_DEVICE_TYPE_WRITE_ONCE_READ_MULTIPLE = 0x04 , SCSI_DEVICE_TYPE_CDROM = 0x05 , SCSI_DEVICE_TYPE_SCANNER = 0x06 , SCSI_DEVICE_TYPE_OPTICAL = 0x07 ,
  SCSI_DEVICE_TYPE_MEDIUM_CHANGER = 0x08 , SCSI_DEVICE_TYPE_COMMUNICATION = 0x09 , SCSI_DEVICE_TYPE_ASC_PREPRESS_GRAPHICS10 = 0x0a , SCSI_DEVICE_TYPE_ASC_PREPRESS_GRAPHICS11 = 0x0b ,
  SCSI_DEVICE_TYPE_ARRAY = 0x0c , SCSI_DEVICE_TYPE_ENCLOSURE = 0x0d , SCSI_DEVICE_TYPE_RBC = 0x0e , SCSI_DEVICE_TYPE_CARDREADER = 0x0f ,
  SCSI_DEVICE_TYPE_BRIDGE = 0x10 , SCSI_DEVICE_TYPE_OTHER = 0x11 , SCSI_DEVICE_TYPE_MAX
}
 

函数

 rt_packed (struct rt_scsi_unknow { rt_uint8_t opcode;})
 
 rt_packed (struct rt_scsi_test_unit_ready { rt_uint8_t opcode;rt_uint8_t reserved[4];rt_uint8_t control;rt_uint8_t pad[6];})
 
 rt_packed (struct rt_scsi_inquiry { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t page;rt_uint8_t reserved;rt_uint8_t alloc_length;rt_uint8_t control;rt_uint8_t pad[6];})
 
 rt_packed (struct rt_scsi_inquiry_data { #define RT_SCSI_DEVTYPE_MASK rt_uint8_t devtype;#define RT_SCSI_REMOVABLE_BIT rt_uint8_t rmb;rt_uint8_t reserved[2];rt_uint8_t length;rt_uint8_t reserved1[3];char vendor[8];char prodid[16];char prodrev[4];})
 
 rt_packed (struct rt_scsi_request_sense { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t reserved[2];rt_uint8_t alloc_length;rt_uint8_t control;rt_uint8_t pad[6];})
 
 rt_packed (struct rt_scsi_request_sense_data { rt_uint8_t error_code;rt_uint8_t segment_number;rt_uint8_t sense_key;rt_be32_t information;rt_uint8_t additional_sense_length;rt_be32_t cmd_specific_info;rt_uint8_t additional_sense_code;rt_uint8_t additional_sense_code_qualifier;rt_uint8_t field_replaceable_unit_code;rt_uint8_t sense_key_specific[3];})
 
 rt_packed (struct rt_scsi_read_capacity10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t logical_block_addr;rt_uint8_t reserved[2];rt_uint8_t pmi;rt_uint8_t control;rt_be16_t pad;})
 
 rt_packed (struct rt_scsi_read_capacity10_data { rt_be32_t last_block;rt_be32_t block_size;})
 
 rt_packed (struct rt_scsi_read_capacity16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t logical_block_addr;rt_be32_t alloc_len;rt_uint8_t pmi;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_read_capacity16_data { rt_be64_t last_block;rt_be32_t block_size;rt_uint8_t pad[20];})
 
 rt_packed (struct rt_scsi_read10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_uint8_t reserved;rt_be16_t size;rt_uint8_t reserved2;rt_be16_t pad;})
 
 rt_packed (struct rt_scsi_read12 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_read16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_write10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_uint8_t reserved;rt_be16_t size;rt_uint8_t reserved2;rt_be16_t pad;})
 
 rt_packed (struct rt_scsi_write12 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_write16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_synchronize_cache10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_uint8_t reserved;rt_be16_t size;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_synchronize_cache16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_write_same10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_uint8_t reserved;rt_be16_t size;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_write_same16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_mode_select6 { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t reserved[2];rt_uint8_t param_list_len;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_mode_select10 { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t reserved[5];rt_be16_t param_list_len;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_mode_sense6 { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t page_control_code;rt_uint8_t subpage_code;rt_uint8_t allocation_len;rt_uint8_t control;})
 
 rt_packed (struct rt_scsi_mode_sense10 { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t page_control_code;rt_uint8_t subpage_code;rt_uint8_t reserved[3];rt_be16_t allocation_len;rt_uint8_t control;})
 
rt_err_t rt_scsi_host_register (struct rt_scsi_host *scsi)
 
rt_err_t rt_scsi_host_unregister (struct rt_scsi_host *scsi)
 
rt_inline rt_bool_t rt_scsi_cmd_is_write (struct rt_scsi_cmd *cmd)
 
rt_err_t rt_scsi_request_sense (struct rt_scsi_device *sdev, struct rt_scsi_request_sense_data *out_data)
 
rt_err_t rt_scsi_test_unit_ready (struct rt_scsi_device *sdev)
 
rt_err_t rt_scsi_inquiry (struct rt_scsi_device *sdev, struct rt_scsi_inquiry_data *out_data)
 
rt_err_t rt_scsi_read_capacity10 (struct rt_scsi_device *sdev, struct rt_scsi_read_capacity10_data *out_data)
 
rt_err_t rt_scsi_read_capacity16 (struct rt_scsi_device *sdev, struct rt_scsi_read_capacity16_data *out_data)
 
rt_err_t rt_scsi_read10 (struct rt_scsi_device *sdev, rt_off_t lba, void *buffer, rt_size_t size)
 
rt_err_t rt_scsi_read12 (struct rt_scsi_device *sdev, rt_off_t lba, void *buffer, rt_size_t size)
 
rt_err_t rt_scsi_read16 (struct rt_scsi_device *sdev, rt_off_t lba, void *buffer, rt_size_t size)
 
rt_err_t rt_scsi_write10 (struct rt_scsi_device *sdev, rt_off_t lba, const void *buffer, rt_size_t size)
 
rt_err_t rt_scsi_write12 (struct rt_scsi_device *sdev, rt_off_t lba, const void *buffer, rt_size_t size)
 
rt_err_t rt_scsi_write16 (struct rt_scsi_device *sdev, rt_off_t lba, const void *buffer, rt_size_t size)
 
rt_err_t rt_scsi_synchronize_cache10 (struct rt_scsi_device *sdev, rt_off_t lba, rt_size_t size)
 
rt_err_t rt_scsi_synchronize_cache16 (struct rt_scsi_device *sdev, rt_off_t lba, rt_size_t size)
 
rt_err_t rt_scsi_write_same10 (struct rt_scsi_device *sdev, rt_off_t lba, rt_size_t size)
 
rt_err_t rt_scsi_write_same16 (struct rt_scsi_device *sdev, rt_off_t lba, rt_size_t size)
 
rt_err_t rt_scsi_mode_select6 (struct rt_scsi_device *sdev, rt_uint8_t pf, rt_uint8_t sp, void *buffer, rt_size_t size, struct rt_scsi_mode_select_data *data)
 
rt_err_t rt_scsi_mode_select10 (struct rt_scsi_device *sdev, rt_uint8_t pf, rt_uint8_t sp, void *buffer, rt_size_t size, struct rt_scsi_mode_select_data *data)
 
rt_err_t rt_scsi_mode_sense6 (struct rt_scsi_device *sdev, rt_uint8_t dbd, rt_uint8_t modepage, rt_uint8_t subpage, void *buffer, rt_size_t size, struct rt_scsi_mode_select_data *data)
 
rt_err_t rt_scsi_mode_sense10 (struct rt_scsi_device *sdev, rt_uint8_t dbd, rt_uint8_t modepage, rt_uint8_t subpage, void *buffer, rt_size_t size, struct rt_scsi_mode_select_data *data)
 

宏定义说明

◆ RT_SCSI_LUN_SHIFT

#define RT_SCSI_LUN_SHIFT   5

在文件 scsi.h18 行定义.

◆ RT_SCSI_DEVTYPE_MASK

#define RT_SCSI_DEVTYPE_MASK   31

◆ RT_SCSI_REMOVABLE_BIT

#define RT_SCSI_REMOVABLE_BIT   7

◆ RT_SCSI_UNMAP_SHIFT

#define RT_SCSI_UNMAP_SHIFT   3

在文件 scsi.h198 行定义.

◆ RT_SCSI_PF_SHIFT

#define RT_SCSI_PF_SHIFT   4

在文件 scsi.h220 行定义.

◆ RT_SCSI_RTD_SHIFT

#define RT_SCSI_RTD_SHIFT   1

在文件 scsi.h221 行定义.

◆ RT_SCSI_SP_SHIFT

#define RT_SCSI_SP_SHIFT   0

在文件 scsi.h222 行定义.

◆ RT_SCSI_DBD_SHIFT

#define RT_SCSI_DBD_SHIFT   3

在文件 scsi.h252 行定义.

◆ RT_SCSI_LLBAA_SHIFT

#define RT_SCSI_LLBAA_SHIFT   4

在文件 scsi.h253 行定义.

◆ RT_SCSI_PC_SHIFT

#define RT_SCSI_PC_SHIFT   6

在文件 scsi.h254 行定义.

◆ RT_SCSI_PAGE_CODE_SHIFT

#define RT_SCSI_PAGE_CODE_SHIFT   0

在文件 scsi.h255 行定义.

◆ RT_SCSI_CMD_TEST_UNIT_READY

#define RT_SCSI_CMD_TEST_UNIT_READY   0x00

在文件 scsi.h278 行定义.

◆ RT_SCSI_CMD_REQUEST_SENSE

#define RT_SCSI_CMD_REQUEST_SENSE   0x03

在文件 scsi.h279 行定义.

◆ RT_SCSI_CMD_INQUIRY

#define RT_SCSI_CMD_INQUIRY   0x12

在文件 scsi.h280 行定义.

◆ RT_SCSI_CMD_MODE_SELECT

#define RT_SCSI_CMD_MODE_SELECT   0x15

在文件 scsi.h281 行定义.

◆ RT_SCSI_CMD_MODE_SENSE

#define RT_SCSI_CMD_MODE_SENSE   0x1a

在文件 scsi.h282 行定义.

◆ RT_SCSI_CMD_READ_CAPACITY10

#define RT_SCSI_CMD_READ_CAPACITY10   0x25

在文件 scsi.h283 行定义.

◆ RT_SCSI_CMD_READ10

#define RT_SCSI_CMD_READ10   0x28

在文件 scsi.h284 行定义.

◆ RT_SCSI_CMD_WRITE10

#define RT_SCSI_CMD_WRITE10   0x2a

在文件 scsi.h285 行定义.

◆ RT_SCSI_CMD_SYNCHRONIZE_CACHE10

#define RT_SCSI_CMD_SYNCHRONIZE_CACHE10   0x35

在文件 scsi.h286 行定义.

◆ RT_SCSI_CMD_WRITE_SAME10

#define RT_SCSI_CMD_WRITE_SAME10   0x41

在文件 scsi.h287 行定义.

◆ RT_SCSI_CMD_MODE_SELECT10

#define RT_SCSI_CMD_MODE_SELECT10   0x55

在文件 scsi.h288 行定义.

◆ RT_SCSI_CMD_MODE_SENSE10

#define RT_SCSI_CMD_MODE_SENSE10   0x5a

在文件 scsi.h289 行定义.

◆ RT_SCSI_CMD_READ16

#define RT_SCSI_CMD_READ16   0x88

在文件 scsi.h290 行定义.

◆ RT_SCSI_CMD_WRITE16

#define RT_SCSI_CMD_WRITE16   0x8a

在文件 scsi.h291 行定义.

◆ RT_SCSI_CMD_SYNCHRONIZE_CACHE16

#define RT_SCSI_CMD_SYNCHRONIZE_CACHE16   0x91

在文件 scsi.h292 行定义.

◆ RT_SCSI_CMD_WRITE_SAME16

#define RT_SCSI_CMD_WRITE_SAME16   0x93

在文件 scsi.h293 行定义.

◆ RT_SCSI_CMD_READ_CAPACITY16

#define RT_SCSI_CMD_READ_CAPACITY16   0x9e

在文件 scsi.h294 行定义.

◆ RT_SCSI_CMD_READ12

#define RT_SCSI_CMD_READ12   0xa8

在文件 scsi.h295 行定义.

◆ RT_SCSI_CMD_WRITE12

#define RT_SCSI_CMD_WRITE12   0xaa

在文件 scsi.h296 行定义.

枚举类型说明

◆ anonymous enum

anonymous enum
枚举值
SCSI_DEVICE_TYPE_DIRECT 0x00 
SCSI_DEVICE_TYPE_SEQUENTIAL 0x01 
SCSI_DEVICE_TYPE_PRINTER 0x02 
SCSI_DEVICE_TYPE_PROCESSOR 0x03 
SCSI_DEVICE_TYPE_WRITE_ONCE_READ_MULTIPLE 0x04 
SCSI_DEVICE_TYPE_CDROM 0x05 
SCSI_DEVICE_TYPE_SCANNER 0x06 
SCSI_DEVICE_TYPE_OPTICAL 0x07 
SCSI_DEVICE_TYPE_MEDIUM_CHANGER 0x08 
SCSI_DEVICE_TYPE_COMMUNICATION 0x09 
SCSI_DEVICE_TYPE_ASC_PREPRESS_GRAPHICS10 0x0a 
SCSI_DEVICE_TYPE_ASC_PREPRESS_GRAPHICS11 0x0b 
SCSI_DEVICE_TYPE_ARRAY 0x0c 
SCSI_DEVICE_TYPE_ENCLOSURE 0x0d 
SCSI_DEVICE_TYPE_RBC 0x0e 
SCSI_DEVICE_TYPE_CARDREADER 0x0f 
SCSI_DEVICE_TYPE_BRIDGE 0x10 
SCSI_DEVICE_TYPE_OTHER 0x11 
SCSI_DEVICE_TYPE_MAX  

在文件 scsi.h342 行定义.

343{
344 SCSI_DEVICE_TYPE_DIRECT = 0x00, /* DiskPeripheral (GenDisk) */
345 SCSI_DEVICE_TYPE_SEQUENTIAL = 0x01, /* TapePeripheral */
346 SCSI_DEVICE_TYPE_PRINTER = 0x02, /* PrinterPeripheral (GenPrinter) */
347 SCSI_DEVICE_TYPE_PROCESSOR = 0x03, /* OtherPeripheral */
348 SCSI_DEVICE_TYPE_WRITE_ONCE_READ_MULTIPLE = 0x04, /* WormPeripheral (GenWorm) */
349 SCSI_DEVICE_TYPE_CDROM = 0x05, /* CdRomPeripheral (GenCdRom) */
350 SCSI_DEVICE_TYPE_SCANNER = 0x06, /* ScannerPeripheral (GenScanner) */
351 SCSI_DEVICE_TYPE_OPTICAL = 0x07, /* OpticalDiskPeripheral (GenOptical) */
352 SCSI_DEVICE_TYPE_MEDIUM_CHANGER = 0x08, /* MediumChangerPeripheral (ScsiChanger) */
353 SCSI_DEVICE_TYPE_COMMUNICATION = 0x09, /* CommunicationsPeripheral (ScsiNet) */
354 SCSI_DEVICE_TYPE_ASC_PREPRESS_GRAPHICS10 = 0x0a, /* ASCPrePressGraphicsPeripheral (ScsiASCIT8) */
355 SCSI_DEVICE_TYPE_ASC_PREPRESS_GRAPHICS11 = 0x0b, /* ASCPrePressGraphicsPeripheral (ScsiASCIT8) */
356 SCSI_DEVICE_TYPE_ARRAY = 0x0c, /* ArrayPeripheral (ScsiArray) */
357 SCSI_DEVICE_TYPE_ENCLOSURE = 0x0d, /* EnclosurePeripheral (ScsiEnclosure) */
358 SCSI_DEVICE_TYPE_RBC = 0x0e, /* RBCPeripheral (ScsiRBC) */
359 SCSI_DEVICE_TYPE_CARDREADER = 0x0f, /* CardReaderPeripheral (ScsiCardReader) */
360 SCSI_DEVICE_TYPE_BRIDGE = 0x10, /* BridgePeripheral (ScsiBridge) */
361 SCSI_DEVICE_TYPE_OTHER = 0x11, /* OtherPeripheral (ScsiOther) */
363};
@ SCSI_DEVICE_TYPE_OTHER
定义 scsi.h:361
@ SCSI_DEVICE_TYPE_MAX
定义 scsi.h:362
@ SCSI_DEVICE_TYPE_RBC
定义 scsi.h:358
@ SCSI_DEVICE_TYPE_PRINTER
定义 scsi.h:346
@ SCSI_DEVICE_TYPE_ARRAY
定义 scsi.h:356
@ SCSI_DEVICE_TYPE_COMMUNICATION
定义 scsi.h:353
@ SCSI_DEVICE_TYPE_SCANNER
定义 scsi.h:350
@ SCSI_DEVICE_TYPE_BRIDGE
定义 scsi.h:360
@ SCSI_DEVICE_TYPE_ASC_PREPRESS_GRAPHICS11
定义 scsi.h:355
@ SCSI_DEVICE_TYPE_PROCESSOR
定义 scsi.h:347
@ SCSI_DEVICE_TYPE_ENCLOSURE
定义 scsi.h:357
@ SCSI_DEVICE_TYPE_CARDREADER
定义 scsi.h:359
@ SCSI_DEVICE_TYPE_OPTICAL
定义 scsi.h:351
@ SCSI_DEVICE_TYPE_SEQUENTIAL
定义 scsi.h:345
@ SCSI_DEVICE_TYPE_MEDIUM_CHANGER
定义 scsi.h:352
@ SCSI_DEVICE_TYPE_CDROM
定义 scsi.h:349
@ SCSI_DEVICE_TYPE_WRITE_ONCE_READ_MULTIPLE
定义 scsi.h:348
@ SCSI_DEVICE_TYPE_DIRECT
定义 scsi.h:344
@ SCSI_DEVICE_TYPE_ASC_PREPRESS_GRAPHICS10
定义 scsi.h:354

函数说明

◆ rt_packed() [1/24]

rt_packed ( struct rt_scsi_unknow { rt_uint8_t opcode;} )

◆ rt_packed() [2/24]

rt_packed ( struct rt_scsi_test_unit_ready { rt_uint8_t opcode;rt_uint8_t reserved[4];rt_uint8_t control;rt_uint8_t pad[6];} )

引用了 rt_scsi_test_unit_ready().

+ 函数调用图:

◆ rt_packed() [3/24]

rt_packed ( struct rt_scsi_inquiry { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t page;rt_uint8_t reserved;rt_uint8_t alloc_length;rt_uint8_t control;rt_uint8_t pad[6];} )

引用了 rt_scsi_inquiry().

+ 函数调用图:

◆ rt_packed() [4/24]

rt_packed ( struct rt_scsi_inquiry_data { #define RT_SCSI_DEVTYPE_MASK rt_uint8_t devtype;#define RT_SCSI_REMOVABLE_BIT rt_uint8_t rmb;rt_uint8_t reserved[2];rt_uint8_t length;rt_uint8_t reserved1[3];char vendor[8];char prodid[16];char prodrev[4];} )

◆ rt_packed() [5/24]

rt_packed ( struct rt_scsi_request_sense { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t reserved[2];rt_uint8_t alloc_length;rt_uint8_t control;rt_uint8_t pad[6];} )

引用了 rt_scsi_request_sense().

+ 函数调用图:

◆ rt_packed() [6/24]

rt_packed ( struct rt_scsi_request_sense_data { rt_uint8_t error_code;rt_uint8_t segment_number;rt_uint8_t sense_key;rt_be32_t information;rt_uint8_t additional_sense_length;rt_be32_t cmd_specific_info;rt_uint8_t additional_sense_code;rt_uint8_t additional_sense_code_qualifier;rt_uint8_t field_replaceable_unit_code;rt_uint8_t sense_key_specific[3];} )

◆ rt_packed() [7/24]

rt_packed ( struct rt_scsi_read_capacity10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t logical_block_addr;rt_uint8_t reserved[2];rt_uint8_t pmi;rt_uint8_t control;rt_be16_t pad;} )

引用了 rt_scsi_read_capacity10().

+ 函数调用图:

◆ rt_packed() [8/24]

rt_packed ( struct rt_scsi_read_capacity10_data { rt_be32_t last_block;rt_be32_t block_size;} )

◆ rt_packed() [9/24]

rt_packed ( struct rt_scsi_read_capacity16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t logical_block_addr;rt_be32_t alloc_len;rt_uint8_t pmi;rt_uint8_t control;} )

引用了 rt_scsi_read_capacity16().

+ 函数调用图:

◆ rt_packed() [10/24]

rt_packed ( struct rt_scsi_read_capacity16_data { rt_be64_t last_block;rt_be32_t block_size;rt_uint8_t pad[20];} )

◆ rt_packed() [11/24]

rt_packed ( struct rt_scsi_read10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_uint8_t reserved;rt_be16_t size;rt_uint8_t reserved2;rt_be16_t pad;} )

引用了 rt_scsi_read10().

+ 函数调用图:

◆ rt_packed() [12/24]

rt_packed ( struct rt_scsi_read12 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;} )

引用了 rt_scsi_read12().

+ 函数调用图:

◆ rt_packed() [13/24]

rt_packed ( struct rt_scsi_read16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;} )

引用了 rt_scsi_read16().

+ 函数调用图:

◆ rt_packed() [14/24]

rt_packed ( struct rt_scsi_write10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_uint8_t reserved;rt_be16_t size;rt_uint8_t reserved2;rt_be16_t pad;} )

引用了 rt_scsi_write10().

+ 函数调用图:

◆ rt_packed() [15/24]

rt_packed ( struct rt_scsi_write12 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;} )

引用了 rt_scsi_write12().

+ 函数调用图:

◆ rt_packed() [16/24]

rt_packed ( struct rt_scsi_write16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;} )

引用了 rt_scsi_write16().

+ 函数调用图:

◆ rt_packed() [17/24]

rt_packed ( struct rt_scsi_synchronize_cache10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_uint8_t reserved;rt_be16_t size;rt_uint8_t control;} )

引用了 rt_scsi_synchronize_cache10().

+ 函数调用图:

◆ rt_packed() [18/24]

rt_packed ( struct rt_scsi_synchronize_cache16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;} )

引用了 rt_scsi_synchronize_cache16().

+ 函数调用图:

◆ rt_packed() [19/24]

rt_packed ( struct rt_scsi_write_same10 { rt_uint8_t opcode;rt_uint8_t config;rt_be32_t lba;rt_uint8_t reserved;rt_be16_t size;rt_uint8_t control;} )

引用了 rt_scsi_write_same10().

+ 函数调用图:

◆ rt_packed() [20/24]

rt_packed ( struct rt_scsi_write_same16 { rt_uint8_t opcode;rt_uint8_t config;rt_be64_t lba;rt_be32_t size;rt_uint8_t reserved;rt_uint8_t control;} )

引用了 rt_scsi_write_same16().

+ 函数调用图:

◆ rt_packed() [21/24]

rt_packed ( struct rt_scsi_mode_select6 { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t reserved[2];rt_uint8_t param_list_len;rt_uint8_t control;} )

引用了 rt_scsi_mode_select6().

+ 函数调用图:

◆ rt_packed() [22/24]

rt_packed ( struct rt_scsi_mode_select10 { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t reserved[5];rt_be16_t param_list_len;rt_uint8_t control;} )

引用了 rt_scsi_mode_select10().

+ 函数调用图:

◆ rt_packed() [23/24]

rt_packed ( struct rt_scsi_mode_sense6 { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t page_control_code;rt_uint8_t subpage_code;rt_uint8_t allocation_len;rt_uint8_t control;} )

引用了 rt_scsi_mode_sense6().

+ 函数调用图:

◆ rt_packed() [24/24]

rt_packed ( struct rt_scsi_mode_sense10 { rt_uint8_t opcode;rt_uint8_t config;rt_uint8_t page_control_code;rt_uint8_t subpage_code;rt_uint8_t reserved[3];rt_be16_t allocation_len;rt_uint8_t control;} )

引用了 rt_scsi_mode_sense10().

+ 函数调用图:

◆ rt_scsi_host_register()

rt_err_t rt_scsi_host_register ( struct rt_scsi_host * scsi)

◆ rt_scsi_host_unregister()

rt_err_t rt_scsi_host_unregister ( struct rt_scsi_host * scsi)

◆ rt_scsi_cmd_is_write()

rt_inline rt_bool_t rt_scsi_cmd_is_write ( struct rt_scsi_cmd * cmd)

在文件 scsi.h404 行定义.

405{
406 return cmd->op.write10.opcode == RT_SCSI_CMD_WRITE10 ||
407 cmd->op.write12.opcode == RT_SCSI_CMD_WRITE16 ||
408 cmd->op.write16.opcode == RT_SCSI_CMD_WRITE12;
409}
#define RT_SCSI_CMD_WRITE10
定义 scsi.h:285
#define RT_SCSI_CMD_WRITE16
定义 scsi.h:291
#define RT_SCSI_CMD_WRITE12
定义 scsi.h:296
struct rt_scsi_write10 write10
定义 scsi.h:311
struct rt_scsi_write12 write12
定义 scsi.h:312
union rt_scsi_cmd::@110335064260203175325264173125227050061241262006 op
struct rt_scsi_write16 write16
定义 scsi.h:313

引用了 rt_scsi_cmd::op, RT_SCSI_CMD_WRITE10, RT_SCSI_CMD_WRITE12, RT_SCSI_CMD_WRITE16, rt_scsi_cmd::write10, rt_scsi_cmd::write12 , 以及 rt_scsi_cmd::write16.

◆ rt_scsi_request_sense()

rt_err_t rt_scsi_request_sense ( struct rt_scsi_device * sdev,
struct rt_scsi_request_sense_data * out_data )
+ 这是这个函数的调用关系图:

◆ rt_scsi_test_unit_ready()

rt_err_t rt_scsi_test_unit_ready ( struct rt_scsi_device * sdev)
+ 这是这个函数的调用关系图:

◆ rt_scsi_inquiry()

rt_err_t rt_scsi_inquiry ( struct rt_scsi_device * sdev,
struct rt_scsi_inquiry_data * out_data )
+ 这是这个函数的调用关系图:

◆ rt_scsi_read_capacity10()

rt_err_t rt_scsi_read_capacity10 ( struct rt_scsi_device * sdev,
struct rt_scsi_read_capacity10_data * out_data )
+ 这是这个函数的调用关系图:

◆ rt_scsi_read_capacity16()

rt_err_t rt_scsi_read_capacity16 ( struct rt_scsi_device * sdev,
struct rt_scsi_read_capacity16_data * out_data )
+ 这是这个函数的调用关系图:

◆ rt_scsi_read10()

rt_err_t rt_scsi_read10 ( struct rt_scsi_device * sdev,
rt_off_t lba,
void * buffer,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_read12()

rt_err_t rt_scsi_read12 ( struct rt_scsi_device * sdev,
rt_off_t lba,
void * buffer,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_read16()

rt_err_t rt_scsi_read16 ( struct rt_scsi_device * sdev,
rt_off_t lba,
void * buffer,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_write10()

rt_err_t rt_scsi_write10 ( struct rt_scsi_device * sdev,
rt_off_t lba,
const void * buffer,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_write12()

rt_err_t rt_scsi_write12 ( struct rt_scsi_device * sdev,
rt_off_t lba,
const void * buffer,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_write16()

rt_err_t rt_scsi_write16 ( struct rt_scsi_device * sdev,
rt_off_t lba,
const void * buffer,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_synchronize_cache10()

rt_err_t rt_scsi_synchronize_cache10 ( struct rt_scsi_device * sdev,
rt_off_t lba,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_synchronize_cache16()

rt_err_t rt_scsi_synchronize_cache16 ( struct rt_scsi_device * sdev,
rt_off_t lba,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_write_same10()

rt_err_t rt_scsi_write_same10 ( struct rt_scsi_device * sdev,
rt_off_t lba,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_write_same16()

rt_err_t rt_scsi_write_same16 ( struct rt_scsi_device * sdev,
rt_off_t lba,
rt_size_t size )
+ 这是这个函数的调用关系图:

◆ rt_scsi_mode_select6()

rt_err_t rt_scsi_mode_select6 ( struct rt_scsi_device * sdev,
rt_uint8_t pf,
rt_uint8_t sp,
void * buffer,
rt_size_t size,
struct rt_scsi_mode_select_data * data )
+ 这是这个函数的调用关系图:

◆ rt_scsi_mode_select10()

rt_err_t rt_scsi_mode_select10 ( struct rt_scsi_device * sdev,
rt_uint8_t pf,
rt_uint8_t sp,
void * buffer,
rt_size_t size,
struct rt_scsi_mode_select_data * data )
+ 这是这个函数的调用关系图:

◆ rt_scsi_mode_sense6()

rt_err_t rt_scsi_mode_sense6 ( struct rt_scsi_device * sdev,
rt_uint8_t dbd,
rt_uint8_t modepage,
rt_uint8_t subpage,
void * buffer,
rt_size_t size,
struct rt_scsi_mode_select_data * data )
+ 这是这个函数的调用关系图:

◆ rt_scsi_mode_sense10()

rt_err_t rt_scsi_mode_sense10 ( struct rt_scsi_device * sdev,
rt_uint8_t dbd,
rt_uint8_t modepage,
rt_uint8_t subpage,
void * buffer,
rt_size_t size,
struct rt_scsi_mode_select_data * data )
+ 这是这个函数的调用关系图: