From: Jens Axboe <axboe@kernel.dk>
To: Pavel Begunkov <asml.silence@gmail.com>,
Bart Van Assche <bvanassche@acm.org>,
Josef Bacik <josef@toxicpanda.com>,
Keith Busch <kbusch@kernel.org>, Christoph Hellwig <hch@lst.de>,
Sagi Grimberg <sagi@grimberg.me>,
linux-block@vger.kernel.org, linux-kernel@vger.kernel.org,
nbd@other.debian.org, linux-nvme@lists.infradead.org
Subject: Re: [PATCH v2 1/1] blk-mq: Inline request status checkers
Date: Wed, 2 Oct 2019 07:09:28 -0600 [thread overview]
Message-ID: <e4fb245a-5587-866b-8bfa-927d0fb0801b@kernel.dk> (raw)
In-Reply-To: <6da099e2-7e29-3c7b-7682-df86835e9e8c@gmail.com>
On 9/30/19 2:12 PM, Pavel Begunkov wrote:
> On 30/09/2019 22:53, Bart Van Assche wrote:
>> On 9/30/19 12:43 PM, Pavel Begunkov (Silence) wrote:
>>> @@ -282,7 +282,7 @@ static bool bt_tags_iter(struct sbitmap *bitmap, unsigned int bitnr, void *data)
>>> * test and set the bit before assining ->rqs[].
>>> */
>>> rq = tags->rqs[bitnr];
>>> - if (rq && blk_mq_request_started(rq))
>>> + if (rq && blk_mq_rq_state(rq) != MQ_RQ_IDLE)
>>> return iter_data->fn(rq, iter_data->data, reserved);
>>>
>>> return true>
>>> @@ -360,7 +360,7 @@ static bool blk_mq_tagset_count_completed_rqs(struct request *rq,
>>> {
>>> unsigned *count = data;
>>>
>>> - if (blk_mq_request_completed(rq))
>>> + if (blk_mq_rq_state(rq) == MQ_RQ_COMPLETE)
>>> (*count)++;
>>> return true;
>>> }
>>
>> Changes like the above significantly reduce readability of the code in
>> the block layer core. I don't like this. I think this patch is a step
>> backwards instead of a step forwards.
>
> Yep, looks too bulky.
>
> Jens, could you consider the first version?
Yes, first one is fine, I have applied it. Thanks.
--
Jens Axboe
next prev parent reply other threads:[~2019-10-02 13:09 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-30 8:25 [PATCH 1/1] blk-mq: Inline status checkers Pavel Begunkov (Silence)
2019-09-30 8:35 ` Christoph Hellwig
2019-09-30 19:45 ` Pavel Begunkov
2019-09-30 19:43 ` [PATCH v2 1/1] blk-mq: Inline request " Pavel Begunkov (Silence)
2019-09-30 19:53 ` Bart Van Assche
2019-09-30 20:12 ` Pavel Begunkov
2019-10-02 13:09 ` Jens Axboe [this message]
2019-09-30 20:13 ` Mike Snitzer
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=e4fb245a-5587-866b-8bfa-927d0fb0801b@kernel.dk \
--to=axboe@kernel.dk \
--cc=asml.silence@gmail.com \
--cc=bvanassche@acm.org \
--cc=hch@lst.de \
--cc=josef@toxicpanda.com \
--cc=kbusch@kernel.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nvme@lists.infradead.org \
--cc=nbd@other.debian.org \
--cc=sagi@grimberg.me \
/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