[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160922133031.zjiyudqwthqp742g@thunk.org>
Date: Thu, 22 Sep 2016 09:30:31 -0400
From: Theodore Ts'o <tytso@....edu>
To: Jan Kara <jack@...e.cz>
Cc: Christoph Hellwig <hch@...radead.org>,
Ext4 Developers List <linux-ext4@...r.kernel.org>,
linux-fsdevel@...r.kernel.org
Subject: Re: [PATCH] ext4: optimize ext4 direct I/O locking for reading
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
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists