summaryrefslogtreecommitdiffstats
path: root/fs/afs
diff options
context:
space:
mode:
authorMarc Dionne2019-04-13 09:37:37 +0200
committerGreg Kroah-Hartman2019-05-16 19:41:21 +0200
commit58be7c109cea9ea619dde5ac504ef9e001a4c2c0 (patch)
tree8e4611cd69ed3209f73c634a28850ac27bda20d9 /fs/afs
parentqede: fix write to free'd pointer error and double free of ptp (diff)
downloadkernel-qcow2-linux-58be7c109cea9ea619dde5ac504ef9e001a4c2c0.tar.gz
kernel-qcow2-linux-58be7c109cea9ea619dde5ac504ef9e001a4c2c0.tar.xz
kernel-qcow2-linux-58be7c109cea9ea619dde5ac504ef9e001a4c2c0.zip
afs: Unlock pages for __pagevec_release()
[ Upstream commit 21bd68f196ca91fc0f3d9bd1b32f6e530e8c1c88 ] __pagevec_release() complains loudly if any page in the vector is still locked. The pages need to be locked for generic_error_remove_page(), but that function doesn't actually unlock them. Unlock the pages afterwards. Signed-off-by: Marc Dionne <marc.dionne@auristor.com> Signed-off-by: David Howells <dhowells@redhat.com> Tested-by: Jonathan Billings <jsbillin@umich.edu> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'fs/afs')
-rw-r--r--fs/afs/write.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/afs/write.c b/fs/afs/write.c
index 19c04caf3c01..e00461a6de9a 100644
--- a/fs/afs/write.c
+++ b/fs/afs/write.c
@@ -253,6 +253,7 @@ static void afs_kill_pages(struct address_space *mapping,
first = page->index + 1;
lock_page(page);
generic_error_remove_page(mapping, page);
+ unlock_page(page);
}
__pagevec_release(&pv);