From: Theodore Ts'o <tytso@mit.edu>
To: Jan Kara <jack@suse.cz>
Cc: Christoph Hellwig <hch@infradead.org>,
Ext4 Developers List <linux-ext4@vger.kernel.org>,
linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH] ext4: optimize ext4 direct I/O locking for reading
Date: Thu, 22 Sep 2016 09:30:31 -0400 [thread overview]
Message-ID: <20160922133031.zjiyudqwthqp742g@thunk.org> (raw)
In-Reply-To: <20160922123143.GO2834@quack2.suse.cz>
On Thu, Sep 22, 2016 at 02:31:43PM +0200, Jan Kara wrote:
>
> So I think what Christoph meant in this case is something like attached
> patch. That achieves more than your dirty hack in a much cleaner way.
> Beware, the patch is only compile-tested.
Your patch also disables dioread_nolock (which is what I think
Christoph was asking about because it's the rest of the dioread nolock
support code which causes the eye-bleeding complexity on the write
path).
> Then there is the case of unlocked direct IO overwrites which we allow to
> run without inode_lock in dioread_nolock mode as well and that is more
> difficult to resolve (there lay the problems with blocksize < pagesize you
> speak about).
Right, by disabling dioread_nolock, it means we lose the feature that
dioread_nolock doesn't require blocking versus _any_ direct I/O writes
(because of the post-write uninit->init conversion) --- not just DIO
overwrites.
But we should be able to support dioread_nolock as well as by only
taking inode_lock_shared() in the non-dioread_nolock case, I think.
Thanks for the prototype patch; I agree it's a cleaner way to go.
- Ted
next prev parent reply other threads:[~2016-09-22 13:33 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-21 5:27 [PATCH] ext4: optimize ext4 direct I/O locking for reading Theodore Ts'o
2016-09-21 13:26 ` Christoph Hellwig
2016-09-21 14:37 ` Theodore Ts'o
2016-09-22 12:31 ` Jan Kara
2016-09-22 13:18 ` Christoph Hellwig
2016-09-22 13:30 ` Theodore Ts'o [this message]
2016-09-30 5:22 ` Theodore Ts'o
2016-10-03 7:41 ` Jan Kara
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=20160922133031.zjiyudqwthqp742g@thunk.org \
--to=tytso@mit.edu \
--cc=hch@infradead.org \
--cc=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-fsdevel@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;
as well as URLs for NNTP newsgroup(s).