* [PATCH 26/60] btrfs: set NO_MP for request queues behind BTRFS
[not found] <1477728600-12938-1-git-send-email-tom.leiming@gmail.com>
@ 2016-10-29 8:08 ` Ming Lei
2016-10-31 15:36 ` Christoph Hellwig
0 siblings, 1 reply; 4+ messages in thread
From: Ming Lei @ 2016-10-29 8:08 UTC (permalink / raw)
To: Jens Axboe, linux-kernel
Cc: linux-block, linux-fsdevel, Christoph Hellwig,
Kirill A . Shutemov, Ming Lei, Chris Mason, Josef Bacik,
David Sterba, open list:BTRFS FILE SYSTEM
There are lots of direct access to .bi_vcnt & .bi_io_vec
of bio, and it isn't ready to support multipage bvecs
for BTRFS, so set NO_MP for these request queues.
Signed-off-by: Ming Lei <tom.leiming@gmail.com>
---
fs/btrfs/volumes.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
index 71a60cc01451..2e7237a3b84d 100644
--- a/fs/btrfs/volumes.c
+++ b/fs/btrfs/volumes.c
@@ -1011,6 +1011,9 @@ static int __btrfs_open_devices(struct btrfs_fs_devices *fs_devices,
if (blk_queue_discard(q))
device->can_discard = 1;
+ /* BTRFS isn't ready to support multipage bvecs */
+ set_bit(QUEUE_FLAG_NO_MP, &q->queue_flags);
+
device->bdev = bdev;
device->in_fs_metadata = 0;
device->mode = flags;
--
2.7.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 26/60] btrfs: set NO_MP for request queues behind BTRFS
2016-10-29 8:08 ` [PATCH 26/60] btrfs: set NO_MP for request queues behind BTRFS Ming Lei
@ 2016-10-31 15:36 ` Christoph Hellwig
2016-10-31 17:58 ` Chris Mason
0 siblings, 1 reply; 4+ messages in thread
From: Christoph Hellwig @ 2016-10-31 15:36 UTC (permalink / raw)
To: Ming Lei
Cc: Jens Axboe, linux-kernel, linux-block, linux-fsdevel,
Christoph Hellwig, Kirill A . Shutemov, Chris Mason, Josef Bacik,
David Sterba, open list:BTRFS FILE SYSTEM
On Sat, Oct 29, 2016 at 04:08:25PM +0800, Ming Lei wrote:
> There are lots of direct access to .bi_vcnt & .bi_io_vec
> of bio, and it isn't ready to support multipage bvecs
> for BTRFS, so set NO_MP for these request queues.
For one bio is an I/O submitter, it has absolutely no business changing
queue flags - if we need to stick to this limitation it simply needs
a version of bio_add_page that doesn't create multi-page bvecs.
Second I don't think making it multipage bvec aware is all that hard,
and we should aim for doing the proper thing.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 26/60] btrfs: set NO_MP for request queues behind BTRFS
2016-10-31 15:36 ` Christoph Hellwig
@ 2016-10-31 17:58 ` Chris Mason
2016-10-31 18:00 ` Christoph Hellwig
0 siblings, 1 reply; 4+ messages in thread
From: Chris Mason @ 2016-10-31 17:58 UTC (permalink / raw)
To: Christoph Hellwig
Cc: Ming Lei, Jens Axboe, linux-kernel, linux-block, linux-fsdevel,
Kirill A . Shutemov, Josef Bacik, David Sterba,
open list:BTRFS FILE SYSTEM
On Mon, Oct 31, 2016 at 08:36:44AM -0700, Christoph Hellwig wrote:
>On Sat, Oct 29, 2016 at 04:08:25PM +0800, Ming Lei wrote:
>> There are lots of direct access to .bi_vcnt & .bi_io_vec
>> of bio, and it isn't ready to support multipage bvecs
>> for BTRFS, so set NO_MP for these request queues.
>
>For one bio is an I/O submitter, it has absolutely no business changing
>queue flags - if we need to stick to this limitation it simply needs
>a version of bio_add_page that doesn't create multi-page bvecs.
>
>Second I don't think making it multipage bvec aware is all that hard,
>and we should aim for doing the proper thing.
Yeah, I'd rather make us less special. The direct access was a short
term fix to adjust to the new bio interfaces, we should clean it up.
-chris
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 26/60] btrfs: set NO_MP for request queues behind BTRFS
2016-10-31 17:58 ` Chris Mason
@ 2016-10-31 18:00 ` Christoph Hellwig
0 siblings, 0 replies; 4+ messages in thread
From: Christoph Hellwig @ 2016-10-31 18:00 UTC (permalink / raw)
To: Chris Mason, Christoph Hellwig, Ming Lei, Jens Axboe,
linux-kernel, linux-block, linux-fsdevel, Kirill A . Shutemov,
Josef Bacik, David Sterba, open list:BTRFS FILE SYSTEM
On Mon, Oct 31, 2016 at 11:58:29AM -0600, Chris Mason wrote:
> Yeah, I'd rather make us less special. The direct access was a short term
> fix to adjust to the new bio interfaces, we should clean it up.
I've got patches for a few areas in progress, I'll send them your way
once I've finished testing. There will be a few more areas left where
I'll need a little help, though.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2016-10-31 18:00 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1477728600-12938-1-git-send-email-tom.leiming@gmail.com>
2016-10-29 8:08 ` [PATCH 26/60] btrfs: set NO_MP for request queues behind BTRFS Ming Lei
2016-10-31 15:36 ` Christoph Hellwig
2016-10-31 17:58 ` Chris Mason
2016-10-31 18:00 ` Christoph Hellwig
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).