]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
STABLE12-linux-pagelaunder-avoid-deadlock-20041012
authorJoe Buehler <jbuehler@hekimian.com>
Mon, 18 Oct 2004 07:09:52 +0000 (07:09 +0000)
committerDerrick Brashear <shadow@dementia.org>
Mon, 18 Oct 2004 07:09:52 +0000 (07:09 +0000)
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

index 2f2f0cfd060e403e889144878efb009c2170b7d8..18e58505a48aeafb99d1fe601f9ee0eab18033be 100644 (file)
@@ -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;