From: Michal Hocko Date: Thu, 11 May 2017 19:01:09 +0000 (-0500) Subject: xfs: abstract PF_FSTRANS to PF_MEMALLOC_NOFS X-Git-Tag: v4.12.0-rc1~32 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b455713b0602fb20578da018d7498b7facf88d75;p=thirdparty%2Fxfsprogs-dev.git xfs: abstract PF_FSTRANS to PF_MEMALLOC_NOFS Source kernel commit: 9070733b4efac4bf17f299a81b01c15e206f9ff5 xfs has defined PF_FSTRANS to declare a scope GFP_NOFS semantic quite some time ago. We would like to make this concept more generic and use it for other filesystems as well. Let's start by giving the flag a more generic name PF_MEMALLOC_NOFS which is in line with an exiting PF_MEMALLOC_NOIO already used for the same purpose for GFP_NOIO contexts. Replace all PF_FSTRANS usage from the xfs code in the first step before we introduce a full API for it as xfs uses the flag directly anyway. This patch doesn't introduce any functional change. Link: http://lkml.kernel.org/r/20170306131408.9828-4-mhocko@kernel.org Signed-off-by: Michal Hocko Reviewed-by: Darrick J. Wong Reviewed-by: Brian Foster Acked-by: Vlastimil Babka Cc: Dave Chinner Cc: Theodore Ts'o Cc: Chris Mason Cc: David Sterba Cc: Jan Kara Cc: Nikolay Borisov Cc: Peter Zijlstra Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Eric Sandeen --- diff --git a/libxfs/xfs_btree.c b/libxfs/xfs_btree.c index 7df320d9c..a9e1fa805 100644 --- a/libxfs/xfs_btree.c +++ b/libxfs/xfs_btree.c @@ -2883,7 +2883,7 @@ xfs_btree_split_worker( struct xfs_btree_split_args *args = container_of(work, struct xfs_btree_split_args, work); unsigned long pflags; - unsigned long new_pflags = PF_FSTRANS; + unsigned long new_pflags = PF_MEMALLOC_NOFS; /* * we are in a transaction context here, but may also be doing work