From: Chengming Zhou <zhouchengming@bytedance.com>
To: Jens Axboe <axboe@kernel.dk>
Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] blk-mq: move bio merge attempt to blk_mq_submit_bio()
Date: Fri, 12 Aug 2022 22:48:20 +0800 [thread overview]
Message-ID: <686b645c-c4e1-357f-7c57-b961a1feeda0@bytedance.com> (raw)
In-Reply-To: <330468da-a778-6cfc-ce46-a62566d71c8d@kernel.dk>
On 2022/8/12 20:40, Jens Axboe wrote:
> On 8/12/22 2:39 AM, Chengming Zhou wrote:
>> We will try to get request from cache before alloc request, in
>> both cases will first attempt bio merge.
>>
>> This patch move this common part to blk_mq_submit_bio(), which
>> simplify the code and avoid passing in the pointer of bio.
>
> I don't think this will work. If we get a cached request, then we
> know we have a reference to the queue. If you swap these around,
> then that's no longer the case and we can have a use-after-free if
> the queue goes away.
>
Sorry, thanks for your reply!
prev parent reply other threads:[~2022-08-12 14:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-12 8:39 Chengming Zhou
2022-08-12 12:40 ` Jens Axboe
2022-08-12 14:48 ` Chengming Zhou [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=686b645c-c4e1-357f-7c57-b961a1feeda0@bytedance.com \
--to=zhouchengming@bytedance.com \
--cc=axboe@kernel.dk \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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
all inboxes | Powered by JetHome®