diff options
Diffstat (limited to 'fs/ext4/inode.c')
-rw-r--r-- | fs/ext4/inode.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index 34d7e0703cc6..213d1857a7cf 100644 --- a/fs/ext4/inode.c +++ b/fs/ext4/inode.c | |||
@@ -391,7 +391,7 @@ void ext4_da_update_reserve_space(struct inode *inode, | |||
391 | * inode's preallocations. | 391 | * inode's preallocations. |
392 | */ | 392 | */ |
393 | if ((ei->i_reserved_data_blocks == 0) && | 393 | if ((ei->i_reserved_data_blocks == 0) && |
394 | (atomic_read(&inode->i_writecount) == 0)) | 394 | !inode_is_open_for_write(inode)) |
395 | ext4_discard_preallocations(inode); | 395 | ext4_discard_preallocations(inode); |
396 | } | 396 | } |
397 | 397 | ||