]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
xarray: remove redundant __GFP_NOWARN
authorQianfeng Rong <rongqianfeng@vivo.com>
Mon, 4 Aug 2025 13:00:17 +0000 (21:00 +0800)
committerAndrew Morton <akpm@linux-foundation.org>
Fri, 12 Sep 2025 00:24:40 +0000 (17:24 -0700)
Commit 16f5dfbc851b ("gfp: include __GFP_NOWARN in GFP_NOWAIT") made
GFP_NOWAIT implicitly include __GFP_NOWARN.

Therefore, explicit __GFP_NOWARN combined with GFP_NOWAIT (e.g.,
`GFP_NOWAIT | __GFP_NOWARN`) is now redundant.  Let's clean up these
redundant flags across subsystems.

No functional changes.

Link: https://lkml.kernel.org/r/20250804130018.484321-1-rongqianfeng@vivo.com
Signed-off-by: Qianfeng Rong <rongqianfeng@vivo.com>
Cc: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
lib/xarray.c

index ae3d80f4b4ee3804ef1bed668bacf69a57167986..9a8b4916540cf1d059f70db5a52eec015d72a791 100644 (file)
@@ -370,7 +370,7 @@ static void *xas_alloc(struct xa_state *xas, unsigned int shift)
        if (node) {
                xas->xa_alloc = NULL;
        } else {
-               gfp_t gfp = GFP_NOWAIT | __GFP_NOWARN;
+               gfp_t gfp = GFP_NOWAIT;
 
                if (xas->xa->xa_flags & XA_FLAGS_ACCOUNT)
                        gfp |= __GFP_ACCOUNT;