[PATCH 1/5] nvme: split __nvme_submit_sync_cmd()
Sagi Grimberg
sagi at grimberg.me
Mon Feb 13 01:47:19 PST 2023
>> +struct request *nvme_alloc_request(struct request_queue *q,
>> + struct nvme_command *cmd, int qid,
>> + blk_mq_req_flags_t flags)
>> {
>> struct request *req;
>> - int ret;
>>
>> if (qid == NVME_QID_ANY)
>> req = blk_mq_alloc_request(q, nvme_req_op(cmd), flags);
>> else
>> req = blk_mq_alloc_request_hctx(q, nvme_req_op(cmd), flags,
>> qid - 1);
>> + if (!IS_ERR(req))
>
> As already said last time, please split out a nvme_alloc_request_qid
> function for the few caller that pass a qid.
Agreed.
More information about the Linux-nvme
mailing list