From: axboe@fb.com (Jens Axboe)
Subject: [PATCH] NVMe: allow discard timeouts to be configurable
Date: Sat, 18 Apr 2015 14:13:51 -0600 [thread overview]
Message-ID: <5532BAFF.3010504@fb.com> (raw)
In-Reply-To: <20150418201111.GA20311@infradead.org>
On 04/18/2015 02:11 PM, Christoph Hellwig wrote:
>> static void nvme_set_info(struct nvme_cmd_info *cmd, void *ctx,
>> nvme_completion_fn handler)
>> {
>> + struct request *rq = blk_mq_rq_from_pdu(cmd);
>> +
>> cmd->fn = handler;
>> cmd->ctx = ctx;
>> cmd->aborted = 0;
>> - blk_mq_start_request(blk_mq_rq_from_pdu(cmd));
>> +
>> + if (rq->cmd_flags & REQ_DISCARD)
>> + rq->timeout = nvme_discard_timeout * HZ;
>> +
>
> Can you move this to the discard-specific branch of nvme_queue_rq
> please?
Sure, I just wanted to keep it closer to where we call start request.
But I can move it, does save a branch.
--
Jens Axboe
prev parent reply other threads:[~2015-04-18 20:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-17 21:31 [PATCH] NVMe: allow discard timeouts to be configurable Jens Axboe
2015-04-18 20:11 ` Christoph Hellwig
2015-04-18 20:13 ` Jens Axboe [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5532BAFF.3010504@fb.com \
--to=axboe@fb.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox