https://github.com/torvalds/linux
Revision f4881bc7a83eff263789dd524b7c269d138d4af5 authored by Josef Bacik on 25 March 2013, 20:03:35 UTC, committed by Josef Bacik on 28 March 2013, 13:51:26 UTC
Dave reported a warning when running xfstest 275.  We have been leaking delalloc
metadata space when our reservations fail.  This is because we were improperly
calculating how much space to free for our checksum reservations.  The problem
is we would sometimes free up space that had already been freed in another
thread and we would end up with negative usage for the delalloc space.  This
patch fixes the problem by calculating how much space the other threads would
have already freed, and then calculate how much space we need to free had we not
done the reservation at all, and then freeing any excess space.  This makes
xfstests 275 no longer have leaked space.  Thanks

Cc: stable@vger.kernel.org
Reported-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
1 parent adaa4b8
History
Tip revision: f4881bc7a83eff263789dd524b7c269d138d4af5 authored by Josef Bacik on 25 March 2013, 20:03:35 UTC
Btrfs: fix space leak when we fail to reserve metadata space
Tip revision: f4881bc
File Mode Size
Documentation
arch
block
crypto
drivers
firmware
fs
include
init
ipc
kernel
lib
mm
net
samples
scripts
security
sound
tools
usr
virt
.gitignore -rw-r--r-- 1.1 KB
.mailmap -rw-r--r-- 4.4 KB
COPYING -rw-r--r-- 18.3 KB
CREDITS -rw-r--r-- 92.8 KB
Kbuild -rw-r--r-- 2.5 KB
Kconfig -rw-r--r-- 252 bytes
MAINTAINERS -rw-r--r-- 234.0 KB
Makefile -rw-r--r-- 46.9 KB
README -rw-r--r-- 18.3 KB
REPORTING-BUGS -rw-r--r-- 3.3 KB

README

back to top