From: Christoph Hellwig <hch@infradead.org>
To: Shaohua Li <shli@fb.com>
Cc: Christoph Hellwig <hch@infradead.org>,
linux-block@vger.kernel.org, linux-kernel@vger.kernel.org,
axboe@fb.com, Kernel-team@fb.com, "4.2+" <stable@vger.kernel.org>,
Ming Lei <ming.lei@canonical.com>,
kent.overstreet@gmail.com
Subject: Re: [PATCH] block: don't make BLK_DEF_MAX_SECTORS too big
Date: Wed, 30 Mar 2016 10:40:35 -0700 [thread overview]
Message-ID: <20160330174035.GA14356@infradead.org> (raw)
In-Reply-To: <20160330165019.GC3552828@devbig084.prn1.facebook.com>
On Wed, Mar 30, 2016 at 09:50:30AM -0700, Shaohua Li wrote:
> > bcache should be fixed to not allocate larger than allowed bios then.
> > And handling too large arguments to bio_alloc_bioset is still useful to
> > avoid the checks in the callers and make it robust.
>
> Doesn't this conflict the goal of arbitrary bio size?
I don't think we ever had the goal of entirely arbitrary bio sizes,
we wanted to get rid of the driver imposed limits. And I/O submitter
deciding that it's not bound by BIO_MAX_PAGES is something entirely
different.
> I think nothing is
> wrong in bcache side. The caller can allocate any size of bio, the block
> layer will split the bio into proper size according to block layer
> limitatio and driver limitation.
If we get actual arbitrary large bios we
a) assume drivers can handle bios larger than BIO_MAX_PAGES, which
we've just noticed md can't
b) have to handle all sorts of mempools to handle this giant size
nothing that can't be be done, but it's pretty obvious that we're not
there yet. And I'm not really sure it's necessarily worth it, but
I'm happy to be proven wrong.
> As long as bio_split can do the right
> job, caller of bio allo is good.
But it's pretty clear that it currently doesn't do the right job,
and reducing general queue limits for a single submitter that doesn't
follow the protocol isn't the way to go. The obvious fix is to
make bcache behave like everyone else for now, and then look into
how useful and painful it would be to move to larger bios in general.
next prev parent reply other threads:[~2016-03-30 17:40 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-29 16:42 [PATCH] block: don't make BLK_DEF_MAX_SECTORS too big Shaohua Li
2016-03-29 21:18 ` Christoph Hellwig
2016-03-29 22:01 ` Shaohua Li
2016-03-30 6:51 ` Christoph Hellwig
2016-03-30 16:50 ` Shaohua Li
2016-03-30 17:40 ` Christoph Hellwig [this message]
2016-03-31 0:52 ` Kent Overstreet
2016-03-30 1:39 ` Ming Lei
2016-03-30 2:27 ` Shaohua Li
2016-03-30 12:13 ` Ming Lei
2016-03-30 17:07 ` Shaohua Li
2016-03-31 0:49 ` Ming Lei
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=20160330174035.GA14356@infradead.org \
--to=hch@infradead.org \
--cc=Kernel-team@fb.com \
--cc=axboe@fb.com \
--cc=kent.overstreet@gmail.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=ming.lei@canonical.com \
--cc=shli@fb.com \
--cc=stable@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