From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4F4C1C4361B for ; Tue, 15 Dec 2020 08:27:52 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id B9D4222273 for ; Tue, 15 Dec 2020 08:27:51 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org B9D4222273 Authentication-Results: mail.kernel.org; dmarc=fail (p=quarantine dis=none) header.from=suse.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 147CB6B0036; Tue, 15 Dec 2020 03:27:51 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 0F8846B005D; Tue, 15 Dec 2020 03:27:51 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id F28526B0068; Tue, 15 Dec 2020 03:27:50 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0045.hostedemail.com [216.40.44.45]) by kanga.kvack.org (Postfix) with ESMTP id D68996B0036 for ; Tue, 15 Dec 2020 03:27:50 -0500 (EST) Received: from smtpin10.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id A62BE1EF3 for ; Tue, 15 Dec 2020 08:27:50 +0000 (UTC) X-FDA: 77594838300.10.boot82_580a9f027422 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin10.hostedemail.com (Postfix) with ESMTP id 87E6E16A4B7 for ; Tue, 15 Dec 2020 08:27:50 +0000 (UTC) X-HE-Tag: boot82_580a9f027422 X-Filterd-Recvd-Size: 3810 Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by imf04.hostedemail.com (Postfix) with ESMTP for ; Tue, 15 Dec 2020 08:27:49 +0000 (UTC) X-Virus-Scanned: by amavisd-new at test-mx.suse.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1608020869; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=BcRdGe+BwGu/P3zGHntuQl4s/cuwIdbN+JJKDivcwsQ=; b=ohfCrHHgr2quArA8JO/yaH5tWvtHs2Q3srZkxnSQgMo48bWJHDBsV4sl+7x0dsQVvSJncz NcfvPc7q0OMQKQOqgg8+bHPdyfXQgmhA5NpGAJ+TYiEV+xceNyQrEJI7eJv5nKmyokN2PH 0y+JLdG0ud3+p17jlhJ9WWGTPpdTag0= Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id CA69AAC7F; Tue, 15 Dec 2020 08:27:48 +0000 (UTC) Date: Tue, 15 Dec 2020 09:27:48 +0100 From: Michal Hocko To: Pavel Tatashin Cc: LKML , linux-mm , Andrew Morton , Vlastimil Babka , David Hildenbrand , Oscar Salvador , Dan Williams , Sasha Levin , Tyler Hicks , Joonsoo Kim , mike.kravetz@oracle.com, Steven Rostedt , Ingo Molnar , Jason Gunthorpe , Peter Zijlstra , Mel Gorman , Matthew Wilcox , David Rientjes , John Hubbard , Linux Doc Mailing List Subject: Re: [PATCH v3 4/6] mm: honor PF_MEMALLOC_PIN for all movable pages Message-ID: <20201215082748.GL32193@dhcp22.suse.cz> References: <20201211202140.396852-1-pasha.tatashin@soleen.com> <20201211202140.396852-5-pasha.tatashin@soleen.com> <20201214141715.GF32193@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Tue 15-12-20 00:24:30, Pavel Tatashin wrote: > On Mon, Dec 14, 2020 at 9:17 AM Michal Hocko wrote: > > > > On Fri 11-12-20 15:21:38, Pavel Tatashin wrote: > > [...] > > > diff --git a/mm/page_alloc.c b/mm/page_alloc.c > > > index c2dea9ad0e98..4d8e7f801c66 100644 > > > --- a/mm/page_alloc.c > > > +++ b/mm/page_alloc.c > > > @@ -3802,16 +3802,12 @@ alloc_flags_nofragment(struct zone *zone, gfp_t gfp_mask) > > > return alloc_flags; > > > } > > > > > > -static inline unsigned int current_alloc_flags(gfp_t gfp_mask, > > > - unsigned int alloc_flags) > > > +static inline unsigned int cma_alloc_flags(gfp_t gfp_mask, > > > + unsigned int alloc_flags) > > > > Do you have any strong reason to rename? Even though the current > > Yes :) > > > implementation only does something for cma I do not think this is all > > that important. The naming nicely fits with current_gfp_context so I > > would stick with it. > > I am renaming because current->flags is removed from this function, > therefore keeping the name > becomes misleading. This function only addresses cma flag check > without looking at the thread local state now. Fair enough. I still dislike cma being called out explicitly because that is slightly misleading as well. gpf_to_alloc_flags would be more explicit I believe. But I do not want to bikeshed this to death. -- Michal Hocko SUSE Labs