From 220a97343ec28f604f8598158522ad3c82bc2e02 Mon Sep 17 00:00:00 2001 From: Joe Buehler Date: Mon, 18 Oct 2004 07:09:52 +0000 Subject: [PATCH] STABLE12-linux-pagelaunder-avoid-deadlock-20041012 FIXES 15239 mmap'd files can deadlock on linux; fix by not letting kernel free pages out of our space predictively (cherry picked from commit 33809f6c7382ab07d018809922a2a2b06e798b63) --- src/afs/LINUX/osi_vnodeops.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/afs/LINUX/osi_vnodeops.c b/src/afs/LINUX/osi_vnodeops.c index 2f2f0cfd0..18e58505a 100644 --- a/src/afs/LINUX/osi_vnodeops.c +++ b/src/afs/LINUX/osi_vnodeops.c @@ -1332,6 +1332,12 @@ int afs_linux_writepage(struct page *pp) unsigned offset = PAGE_CACHE_SIZE; long status; +#ifdef PageLaunder + if (PageLaunder(pp)) { + return(fail_writepage(pp)); + } +#endif + inode = (struct inode *) mapping->host; end_index = inode->i_size >> PAGE_CACHE_SHIFT; -- 2.39.5