函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:block\blk-mq.c Create Date:2022-07-27 18:44:01
Last Modify:2020-03-17 23:18:05 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:blk_mq_alloc_request

函数原型:struct request *blk_mq_alloc_request(struct request_queue *q, unsigned int op, blk_mq_req_flags_t flags)

返回类型:struct request

参数:

类型参数名称
struct request_queue *q
unsigned intop
blk_mq_req_flags_tflags
403  struct blk_mq_alloc_data alloc_data = {flags = flags, cmd_flags = op}
407  ret等于lk_queue_enter() - try to increase q->q_usage_counter*@q: request queue pointer*@flags: BLK_MQ_REQ_NOWAIT and/or BLK_MQ_REQ_PREEMPT
408  如果ret则返回:错误号
411  rq等于blk_mq_get_request(q, NULL, & alloc_data)
412  blk_queue_exit(q)
414  如果非rq则返回:错误号
417  total data len 等于0
418  sector cursor = (sector_t) - 1
419  bio = biotail = NULL
420  返回:rq
调用者
名称描述
blk_get_requestlk_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.