From: Dave Chinner Date: Tue, 20 Jul 2010 07:54:12 +0000 (+1000) Subject: xfs: use GFP_NOFS for page cache allocation X-Git-Tag: v2.6.36-rc1~589^2~13 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=aea1b9532143218f8599ecedbbd6bfbf812385e1;p=users%2Fjedix%2Flinux-maple.git xfs: use GFP_NOFS for page cache allocation Avoid a lockdep warning by preventing page cache allocation from recursing back into the filesystem during memory reclaim. Signed-off-by: Dave Chinner Reviewed-by: Christoph Hellwig Reviewed-by: Alex Elder Signed-off-by: Dave Chinner --- diff --git a/fs/xfs/linux-2.6/xfs_aops.c b/fs/xfs/linux-2.6/xfs_aops.c index 225ec0fa65b67..8abbf0532ea12 100644 --- a/fs/xfs/linux-2.6/xfs_aops.c +++ b/fs/xfs/linux-2.6/xfs_aops.c @@ -1493,8 +1493,8 @@ xfs_vm_write_begin( void **fsdata) { *pagep = NULL; - return block_write_begin(file, mapping, pos, len, flags, pagep, fsdata, - xfs_get_blocks); + return block_write_begin(file, mapping, pos, len, flags | AOP_FLAG_NOFS, + pagep, fsdata, xfs_get_blocks); } STATIC sector_t