函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:block\bsg-lib.c Create Date:2022-07-27 19:13:54
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:bsg_transport_fill_hdr

函数原型:static int bsg_transport_fill_hdr(struct request *rq, struct sg_io_v4 *hdr, fmode_t mode)

返回类型:int

参数:

类型参数名称
struct request *rq
struct sg_io_v4 *hdr
fmode_tmode
39  job等于lk_mq_rq_to_pdu - cast a request to a PDU*@rq: the request to be casted* Return: pointer to the PDU* Driver command data is immediately after the request. So add request to get* the PDU.
42  request_len等于 [i] in bytes
43  Transport/driver specific request/reply structs 等于memdup_user - duplicate memory region from user space*@src: source address in user space*@len: number of bytes to copy* Return: an ERR_PTR() on failure. Result is physically* contiguous, to be freed by kfree().
44  如果是错误则返回:错误
47  如果 [i] bytes to be transferred to device [i] bytes to be transferred from device
48  BIDI support 等于lk_get_request - allocate a request*@q: request queue to allocate a request for*@op: operation (REQ_OP_*) and REQ_* flags, e.g. REQ_SYNC.*@flags: BLK_MQ_REQ_* flags, e.g. BLK_MQ_REQ_NOWAIT.
49  如果是错误
50  ret等于错误
51  转到:out
54  ret等于REQ_BLOCK_PC请求
57  如果ret则转到:out_free_bidi_rq
60  bidi_bio等于bio
61  否则
62  BIDI support = NULL
63  bidi_bio = NULL
66  返回:0
68  out_free_bidi_rq :
69  如果 BIDI support blk_put_request( BIDI support )
71  out :
72  释放内存
73  返回:ret