summaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_sync.c
diff options
context:
space:
mode:
authorJosef Bacik <josef@redhat.com>2012-06-08 15:16:12 -0400
committerChris Mason <chris.mason@oracle.com>2012-06-14 21:30:53 -0400
commit8180ef8894fa402443205cff1e23417e8d3434df (patch)
treef3bb1836d96049cb8da52666805fe5b8b4915eed /fs/xfs/xfs_sync.c
parent9c5085c147989d48dfe74194b48affc23f376650 (diff)
downloadlinux-8180ef8894fa402443205cff1e23417e8d3434df.tar.gz
linux-8180ef8894fa402443205cff1e23417e8d3434df.tar.bz2
linux-8180ef8894fa402443205cff1e23417e8d3434df.zip
Btrfs: keep inode pinned when compressing writes
A user reported lots of problems using compression on the new code and it turns out part of the problem was that igrab() was failing when we added a new ordered extent. This is because when writing out an inode under compression we immediately return without actually doing anything to the pages, and then in another thread at some point down the line actually do the ordered dance. The problem is between the point that we start writeback and we actually add the ordered extent we could be trying to reclaim the inode, which makes igrab() return NULL. So we need to do an igrab() when we create the async extent and then drop it when we are done with it. This makes sure we stay pinned in memory until the ordered extent can get a reference on it and we are good to go. With this patch we no longer panic in btrfs_finish_ordered_io(). Thanks, Signed-off-by: Josef Bacik <josef@redhat.com>
Diffstat (limited to 'fs/xfs/xfs_sync.c')
0 files changed, 0 insertions, 0 deletions