Whamcloud - gitweb
e2fsck: update quota accounting after directory optimization
authorLuis Henriques (SUSE) <luis.henriques@linux.dev>
Fri, 5 Apr 2024 14:24:02 +0000 (15:24 +0100)
committerTheodore Ts'o <tytso@mit.edu>
Tue, 16 Apr 2024 03:59:35 +0000 (23:59 -0400)
commiteb782652045e67a5379dd319613b0d3d924901dd
tree3d75addc5f9c2e1e1d52d69a695f93a0f81440ff
parent87cbb381f2e2fb9aab316187a70acca9f6d5061b
e2fsck: update quota accounting after directory optimization

In "Pass 3A: Optimizing directories", a directory may have it's size reduced.
If that happens and quota is enabled in the filesystem, the quota information
will be incorrect because it doesn't take the rehash into account.  This issue
was detected by running fstest ext4/014.

This patch simply updates the quota data accordingly, after the directory is
written and it's size has been updated.

Link: https://bugzilla.kernel.org/show_bug.cgi?id=218626
Signed-off-by: Luis Henriques (SUSE) <luis.henriques@linux.dev>
Reviewed-by: Andreas Dilger <adilger@dilger.ca>
Link: https://lore.kernel.org/r/20240405142405.12312-2-luis.henriques@linux.dev
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
e2fsck/rehash.c