Received: by 2002:a05:6a10:87d6:0:0:0:0 with SMTP id g22csp989033pxr; Mon, 11 Apr 2022 12:06:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzo0azTN5xCRbwkGBDlFPQ5flb1vs8sdz/+FbAG5qPBT8u5+/BeODKHPqdfPpo2gSTMTNmz X-Received: by 2002:a17:90b:4a92:b0:1c7:5aa4:2a74 with SMTP id lp18-20020a17090b4a9200b001c75aa42a74mr662472pjb.239.1649703980757; Mon, 11 Apr 2022 12:06:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649703980; cv=none; d=google.com; s=arc-20160816; b=u7A6MxxSiXDFNwwsVew4uFK/mjAJwbH4UK+jJXSy0JTnfXfTA6wd/hc0piwXSMCwVW reyaDpQuqZBWqMm/mArtaRa9wHj7J9dQr1AVtXTE6jbFZmhPP/Ieq4SMSNY3xjLcWQXX 9mREi5XfMsYLptpib8Q4Sfd31wKv2HjIMlX2/QOos9qJCTBk59E7YcIYf6nvtGxELLNt +oYhHLC8i0DQ3Shm4F+RP6+4tJ071KwyXHI+dYc7IQMhSgluxVy5nfoJcJO4fZLMzS56 Hn1x2JnWRlm4j/S5BB5O6dzKQ5b5CZs1/o9lHH7csB1kQfsaLH/BZUfQJ1SzXWCAgm/A P4Ew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=cSXw+XVYOoX2G7IopQ/sIWz/YQYFoZXQ3ZmEBf6FWSM=; b=D3DShRH8nGXKjJE8hV3INVHSVwR47hfAjmhCRw2GOFPMA+wPhRWW82G56Y4MobQFPz zt4d2YjcN6K/Vt/jUarrh+9VJkwd0R91Mlx4IoARBYTb8uGxjtWJu+eac6MOuhXSfT6A AVnABZOUmZNTkzSONFkEkQjZBm7gfI7blZPFpClML0GOWXc1lkAo8xWkW92j6C4FoMGd idMHm6HOb/dl+vXhx0OA4/3tmvDyQmX+eUxu7u1RGCyo/gTi0sGbU7lcVcUr6+HHMS0W brGLkG+LbWXc+2hxRs1ZHkTpHMu63ICMcNrabo8iRhK4p3Zy7tAhTXc6A48lq2lrboqy vLTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=HpxHKRU2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id j64-20020a638043000000b0039cb1232e71si562299pgd.403.2022.04.11.12.06.05; Mon, 11 Apr 2022 12:06:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=HpxHKRU2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234347AbiDJHoa (ORCPT + 99 others); Sun, 10 Apr 2022 03:44:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34002 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231268AbiDJHo3 (ORCPT ); Sun, 10 Apr 2022 03:44:29 -0400 Received: from mail-pl1-x62d.google.com (mail-pl1-x62d.google.com [IPv6:2607:f8b0:4864:20::62d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E8A762F0 for ; Sun, 10 Apr 2022 00:42:18 -0700 (PDT) Received: by mail-pl1-x62d.google.com with SMTP id y6so11436106plg.2 for ; Sun, 10 Apr 2022 00:42:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=cSXw+XVYOoX2G7IopQ/sIWz/YQYFoZXQ3ZmEBf6FWSM=; b=HpxHKRU2aoHfoFqFL83nSo0hUqwoFOEviIl5QHGVndY2acZcZC1lvJiuQkznBuSY6y R2c1aZV7JW3jZB4kmcRDqXiJGkYhHb2wTFvltgURNixUpkLQ6wF701ibEmM118PD+w6i EEcMjqFqkGLTRDqEL3X7eATLmFbiy9rZE0UK2IslN50mYTzAcz2eyjcVn6L6GQqub96N VIg4wL+2KLzlMFJNLhTl6tVsoICvejpW8/QeA88BpqNLPbq5x6epmOITXgwUS4r2DlNx 3c2byneqiiiDt+MYO7p6twH9+3Ghz2TN4EvwTDWh3JQX4QFhfYtqVvOWJGLgcbLcJ+Qi wzNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=cSXw+XVYOoX2G7IopQ/sIWz/YQYFoZXQ3ZmEBf6FWSM=; b=BtzhrTB1QBKsP0G4BX0PZlBy8EXtH82Kp+ngOTlBnof4l3hxxmuS6sGjl5te2/WV9W 0q953QA2CGCjEZLN/9S2AC8vzLqfA4vQxbQe3gRvx+txyFyoSlE0z56UyKRX9hzfH74A 03FGmGQfYlEa5V0LRw5Oz6k8wLHnD9aWDxssZAWYRj/Izk793yBL69uAec8GBrJLhX0h jCjskfyqxfZAu8vzCKv+RyFO5JD+44DtGbPzw/pClH1e2hh8Sur/3jn+uHE5rGjEFd5C McvmC05UAJlZsonb57KvNVMPSU3+nHyceJEx5vK4wLlzvvlnC8xoHUoc4MSBmCtSSZvU n6GQ== X-Gm-Message-State: AOAM533Taevp9KqWNdb8Bw4JyuIVn9YBBPQYsCsRhFHQzhWoB/xI4CxO ElZmInRF15FzWsWVfFEIeroRW3B1tOE= X-Received: by 2002:a17:902:a710:b0:156:5650:f94a with SMTP id w16-20020a170902a71000b001565650f94amr26471202plq.86.1649576538467; Sun, 10 Apr 2022 00:42:18 -0700 (PDT) Received: from hyeyoo ([114.29.24.243]) by smtp.gmail.com with ESMTPSA id z10-20020a17090a8b8a00b001ca7bafba51sm15750166pjn.0.2022.04.10.00.42.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Apr 2022 00:42:17 -0700 (PDT) Date: Sun, 10 Apr 2022 16:42:08 +0900 From: Hyeonggon Yoo <42.hyeyoo@gmail.com> To: Jiyoup Kim Cc: Christoph Lameter , Pekka Enberg , David Rientjes , Joonsoo Kim , Andrew Morton , Vlastimil Babka , Ohhoon Kwon , JaeSang Yoo , Wonhyuk Yang , Donghyeok Kim , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm/slub: remove duplicate flag in allocate_slab() Message-ID: References: <20220409150538.1264-1-lakroforce@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220409150538.1264-1-lakroforce@gmail.com> X-Spam-Status: No, score=-0.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HK_RANDOM_ENVFROM, HK_RANDOM_FROM,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Apr 10, 2022 at 12:05:37AM +0900, Jiyoup Kim wrote: > In allocate_slab(), __GFP_NOFAIL flag is removed twice when trying > higher-order allocation. Remove it. > > Signed-off-by: Jiyoup Kim > --- > mm/slub.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/mm/slub.c b/mm/slub.c > index 74d92aa4a3a2..a0e605ab3036 100644 > --- a/mm/slub.c > +++ b/mm/slub.c > @@ -1939,7 +1939,7 @@ static struct slab *allocate_slab(struct kmem_cache *s, gfp_t flags, int node) > */ > alloc_gfp = (flags | __GFP_NOWARN | __GFP_NORETRY) & ~__GFP_NOFAIL; > if ((alloc_gfp & __GFP_DIRECT_RECLAIM) && oo_order(oo) > oo_order(s->min)) > - alloc_gfp = (alloc_gfp | __GFP_NOMEMALLOC) & ~(__GFP_RECLAIM|__GFP_NOFAIL); > + alloc_gfp = (alloc_gfp | __GFP_NOMEMALLOC) & ~__GFP_RECLAIM; > > slab = alloc_slab_page(alloc_gfp, node, oo); > if (unlikely(!slab)) { Looks good to me. Reviewed-by: Hyeonggon Yoo <42.hyeyoo@gmail.com> Thanks! > -- > 2.25.1 > > -- Thanks, Hyeonggon