linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ext4: fix quota accounting in case of fallocate
@ 2010-03-30 14:24 Dmitry Monakhov
  2010-03-30 14:27 ` Dmitry Monakhov
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Dmitry Monakhov @ 2010-03-30 14:24 UTC (permalink / raw)
  To: linux-ext4; +Cc: tytso, aneesh.kumar, Dmitry Monakhov

allocated_meta_data is already included in 'used' variable.

Signed-off-by: Dmitry Monakhov <dmonakhov@openvz.org>
---
 fs/ext4/inode.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index bec222c..bf989fb 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -1110,7 +1110,8 @@ void ext4_da_update_reserve_space(struct inode *inode,
 		 */
 		if (allocated_meta_blocks)
 			dquot_claim_block(inode, allocated_meta_blocks);
-		dquot_release_reservation_block(inode, mdb_free + used);
+		dquot_release_reservation_block(inode, mdb_free + used -
+			allocated_meta_blocks);
 	}
 
 	/*
-- 
1.6.6.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-04-03 15:57 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-30 14:24 [PATCH] ext4: fix quota accounting in case of fallocate Dmitry Monakhov
2010-03-30 14:27 ` Dmitry Monakhov
2010-03-30 18:08 ` Aneesh Kumar K. V
2010-03-31  4:51   ` dmonakhov
2010-04-03 15:56 ` tytso

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).