Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

at v4.13-rc6 32 lines 628 B view raw
1#ifndef _SCSI_SCSI_REQUEST_H 2#define _SCSI_SCSI_REQUEST_H 3 4#include <linux/blk-mq.h> 5 6#define BLK_MAX_CDB 16 7 8struct scsi_request { 9 unsigned char __cmd[BLK_MAX_CDB]; 10 unsigned char *cmd; 11 unsigned short cmd_len; 12 int result; 13 unsigned int sense_len; 14 unsigned int resid_len; /* residual count */ 15 int retries; 16 void *sense; 17}; 18 19static inline struct scsi_request *scsi_req(struct request *rq) 20{ 21 return blk_mq_rq_to_pdu(rq); 22} 23 24static inline void scsi_req_free_cmd(struct scsi_request *req) 25{ 26 if (req->cmd != req->__cmd) 27 kfree(req->cmd); 28} 29 30void scsi_req_init(struct scsi_request *req); 31 32#endif /* _SCSI_SCSI_REQUEST_H */