]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blame - releases/2.6.32.17/0034-ext4-fix-quota-accounting-in-case-of-fallocate.patch
4.9-stable patches
[thirdparty/kernel/stable-queue.git] / releases / 2.6.32.17 / 0034-ext4-fix-quota-accounting-in-case-of-fallocate.patch
CommitLineData
7d777456
GKH
1From 93984006ca6af7d067409fd6db2bedd999af2b0d Mon Sep 17 00:00:00 2001
2From: Dmitry Monakhov <dmonakhov@openvz.org>
3Date: Sun, 30 May 2010 22:49:48 -0400
4Subject: ext4: fix quota accounting in case of fallocate
5
6commit 35121c9860316d7799cea0fbc359a9186e7c2747 upstream (as of v2.6.34-git13)
7
8allocated_meta_data is already included in 'used' variable.
9
10Signed-off-by: Dmitry Monakhov <dmonakhov@openvz.org>
11Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
12Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
13---
14 fs/ext4/inode.c | 3 ++-
15 1 file changed, 2 insertions(+), 1 deletion(-)
16
17--- a/fs/ext4/inode.c
18+++ b/fs/ext4/inode.c
19@@ -1149,7 +1149,8 @@ void ext4_da_update_reserve_space(struct
20 */
21 if (allocated_meta_blocks)
22 vfs_dq_claim_block(inode, allocated_meta_blocks);
23- vfs_dq_release_reservation_block(inode, mdb_free + used);
24+ vfs_dq_release_reservation_block(inode, mdb_free + used -
25+ allocated_meta_blocks);
26 }
27
28 /*