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=-2.2 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=no 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 68F12C282DD for ; Fri, 10 Jan 2020 17:55:23 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 05D2B2080D for ; Fri, 10 Jan 2020 17:55:22 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=shutemov-name.20150623.gappssmtp.com header.i=@shutemov-name.20150623.gappssmtp.com header.b="aBroZhD7" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 05D2B2080D Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=shutemov.name Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 5C2DB8E0005; Fri, 10 Jan 2020 12:55:22 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 572778E0001; Fri, 10 Jan 2020 12:55:22 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 488728E0005; Fri, 10 Jan 2020 12:55:22 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0047.hostedemail.com [216.40.44.47]) by kanga.kvack.org (Postfix) with ESMTP id 372FD8E0001 for ; Fri, 10 Jan 2020 12:55:22 -0500 (EST) Received: from smtpin23.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with SMTP id E73C9181AC9CB for ; Fri, 10 Jan 2020 17:55:21 +0000 (UTC) X-FDA: 76362476442.23.cow92_8617ac4ff763c X-HE-Tag: cow92_8617ac4ff763c X-Filterd-Recvd-Size: 4521 Received: from mail-lf1-f68.google.com (mail-lf1-f68.google.com [209.85.167.68]) by imf37.hostedemail.com (Postfix) with ESMTP for ; Fri, 10 Jan 2020 17:55:21 +0000 (UTC) Received: by mail-lf1-f68.google.com with SMTP id m30so2115848lfp.8 for ; Fri, 10 Jan 2020 09:55:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=shutemov-name.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=zz+quxNQ9A7Nw9iS38o6f8U+FhTKrAPp7iIrBkPDhng=; b=aBroZhD7Y0T9JZ9Me+bhFExvvN2ek+hxX9sraWp+HU38gxMBkZRHRP4drMgDP5TZym K//IAs2EZ0YnkdMMsZcQ0rguk8FnsxOQUO0u6vwDRNXsvPgmuKzQimYEJyEwuth9HMib R4a8mXioF0Hh1kwl1g0mQCRZnDFz3noAPZZSVuvs7NY7cwS+WftKEoLH6rW1LJcX+4nc oihLd6XtHzkis179G5ZolevpXvOTYgjtcGySrC9NdMcXWxPbx6nymac5HvqJ23fyou7t BvRio8Hu6F1GlPWLXFdtlMemJecHHXEAPcFfL8GZ7avwQq6RPMXjmxSgsT7Wm5yvcXxe EtPQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=zz+quxNQ9A7Nw9iS38o6f8U+FhTKrAPp7iIrBkPDhng=; b=AaIVe6H44tcdLlwunJYEdrLHZDrG8THf6iLRWRuPfWL8B4e+WkSjt6KiQuTtMmQQe5 9pZSf3MjLZAalus+0KvY+4i6AokN4E82+kVTqdJ9oFsty5QHFKZIBo3n5Y8nQ7ZfxQTI Y8r2Ic+R/7Hi0XkAcAIRGii70IikCMnHhcD+WrzvVK1Y1h8xe9Uk0UqWw1AGfCE3YJ4E Elx+HiiW6rTlfn0LzB7dr4WAkr/X0AYZ9p46F19NDEsNEMvrFH5MedVZKccg7meEey5w FHkk0iKBWv1wX87fF3xOuwg90d5CiuOravFO+Rw6Qxe54Kv1TmcqiVjFNCRxuzs7TvvO OiEA== X-Gm-Message-State: APjAAAXo52sVFwxVxxjHIGN/JIQXqiCAnKyvRJnW2/n/omkoRZ76eR9W l/01Z8KSqKFwgyA5z39EJm/rxA== X-Google-Smtp-Source: APXvYqy8FVQJWam23cUJsbg5L2XIhB4e80Fm51ijXV/BqTf4T7GX8aBwJOGS+3R1JLeZ/gpUYCvctw== X-Received: by 2002:a05:6512:244:: with SMTP id b4mr3034448lfo.85.1578678919579; Fri, 10 Jan 2020 09:55:19 -0800 (PST) Received: from box.localdomain ([86.57.175.117]) by smtp.gmail.com with ESMTPSA id i4sm1308379ljg.102.2020.01.10.09.55.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Jan 2020 09:55:18 -0800 (PST) Received: by box.localdomain (Postfix, from userid 1000) id 8C02C1010D6; Fri, 10 Jan 2020 20:55:19 +0300 (+03) Date: Fri, 10 Jan 2020 20:55:19 +0300 From: "Kirill A. Shutemov" To: David Hildenbrand Cc: Michal Hocko , Andrew Morton , Dan Williams , Vlastimil Babka , Mel Gorman , "Jin, Zhi" , linux-mm@kvack.org, linux-kernel@vger.kernel.org, "Kirill A. Shutemov" Subject: Re: [PATCH] mm/page_alloc: Skip non present sections on zone initialization Message-ID: <20200110175519.myahx3tnxajt4eam@box> References: <20191230093828.24613-1-kirill.shutemov@linux.intel.com> <20200108144044.GB30379@dhcp22.suse.cz> <73437651-822f-fcec-3b96-281fb1064cf8@redhat.com> <20200110134547.v6ju5dxazknfjdj3@box> <20200110144717.xufpf4yjkjlngymy@box> <6cf49e65-ee02-7cbd-596f-ebbc057717c2@redhat.com> <20200110145454.mmgmtcy2zsrr63vh@box> <2f075639-c378-4bba-abe1-60d3c2420800@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2f075639-c378-4bba-abe1-60d3c2420800@redhat.com> User-Agent: NeoMutt/20180716 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 Fri, Jan 10, 2020 at 03:56:14PM +0100, David Hildenbrand wrote: > On 10.01.20 15:54, Kirill A. Shutemov wrote: > > On Fri, Jan 10, 2020 at 03:48:39PM +0100, David Hildenbrand wrote: > >>>> + if (!present_section_nr(section_nr)) > >>>> + return section_nr_to_pfn(next_present_section_nr(section_nr)); > >>> > >>> This won't compile. next_present_section_nr() is static to mm/sparse.c. > >> > >> We should then move that to the header IMHO. > > > > It looks like too much for a trivial cleanup. > > > > Cleanup? This is a performance improvement ("fix the issue."). We should > avoid duplicating code where it can be avoided. My original patch is in -mm tree and fixes the issue. The thread is about tiding it up. -- Kirill A. Shutemov