Skip to content

Commit

Permalink
ext4: Remove wait for unwritten extents in ext4_ind_direct_IO()
Browse files Browse the repository at this point in the history
We don't have to wait for unwritten extent conversion in
ext4_ind_direct_IO() as all writes that happened before DIO are
flushed by the generic code and extent conversion has happened before
we cleared PageWriteback bit.

Reviewed-by: Zheng Liu <wenqing.lz@taobao.com>
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
  • Loading branch information
Jan Kara authored and Theodore Ts'o committed Jun 4, 2013
1 parent 92e6222 commit 38b8ff7
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions fs/ext4/indirect.c
Original file line number Diff line number Diff line change
Expand Up @@ -675,11 +675,6 @@ ssize_t ext4_ind_direct_IO(int rw, struct kiocb *iocb,

retry:
if (rw == READ && ext4_should_dioread_nolock(inode)) {
if (unlikely(atomic_read(&EXT4_I(inode)->i_unwritten))) {
mutex_lock(&inode->i_mutex);
ext4_flush_unwritten_io(inode);
mutex_unlock(&inode->i_mutex);
}
/*
* Nolock dioread optimization may be dynamically disabled
* via ext4_inode_block_unlocked_dio(). Check inode's state
Expand Down

0 comments on commit 38b8ff7

Please sign in to comment.