diff options
| author | Jeff Garzik <jgarzik@pobox.com> | 2005-06-30 00:49:18 -0400 |
|---|---|---|
| committer | Jeff Garzik <jgarzik@pobox.com> | 2005-06-30 00:49:18 -0400 |
| commit | 0c168775709faa74c1b87f1e61046e0c51ade7f3 (patch) | |
| tree | c40fd8818c64c5d7d1d90afab0bd6ffd94505526 /fs/ext3/file.c | |
| parent | 9bd481f85940726bf66aae5cd03c5b912ad0ae4c (diff) | |
| parent | 9b4311eedb17fa88f02e4876cd6aa9a08e383cd6 (diff) | |
Merge upstream 2.6.13-rc1-git1 into 'ieee80211' branch of netdev-2.6.
Diffstat (limited to 'fs/ext3/file.c')
| -rw-r--r-- | fs/ext3/file.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/ext3/file.c b/fs/ext3/file.c index 5ad8cf0292df..98e78345ead9 100644 --- a/fs/ext3/file.c +++ b/fs/ext3/file.c @@ -36,7 +36,11 @@ static int ext3_release_file (struct inode * inode, struct file * filp) /* if we are the last writer on the inode, drop the block reservation */ if ((filp->f_mode & FMODE_WRITE) && (atomic_read(&inode->i_writecount) == 1)) + { + down(&EXT3_I(inode)->truncate_sem); ext3_discard_reservation(inode); + up(&EXT3_I(inode)->truncate_sem); + } if (is_dx(inode) && filp->private_data) ext3_htree_free_dir_info(filp->private_data); |
