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=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,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 EDA77ECE58F for ; Tue, 15 Oct 2019 10:34:27 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id B640C20854 for ; Tue, 15 Oct 2019 10:34:27 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org B640C20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 594788E0006; Tue, 15 Oct 2019 06:34:27 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 545968E0001; Tue, 15 Oct 2019 06:34:27 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4828E8E0006; Tue, 15 Oct 2019 06:34:27 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0185.hostedemail.com [216.40.44.185]) by kanga.kvack.org (Postfix) with ESMTP id 298328E0001 for ; Tue, 15 Oct 2019 06:34:27 -0400 (EDT) Received: from smtpin19.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with SMTP id C55F818034F4E for ; Tue, 15 Oct 2019 10:34:26 +0000 (UTC) X-FDA: 76045659732.19.straw49_60f048ebe2215 X-HE-Tag: straw49_60f048ebe2215 X-Filterd-Recvd-Size: 3604 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by imf44.hostedemail.com (Postfix) with ESMTP for ; Tue, 15 Oct 2019 10:34:26 +0000 (UTC) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id F2E6428; Tue, 15 Oct 2019 03:34:24 -0700 (PDT) Received: from [10.162.42.142] (p8cg001049571a15.blr.arm.com [10.162.42.142]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 563E33F68E; Tue, 15 Oct 2019 03:34:16 -0700 (PDT) Subject: Re: + mm-hugetlb-make-alloc_gigantic_page-available-for-general-use.patch added to -mm tree To: Michal Hocko Cc: Mike Kravetz , akpm@linux-foundation.org, ard.biesheuvel@linaro.org, broonie@kernel.org, christophe.leroy@c-s.fr, dan.j.williams@intel.com, dave.hansen@intel.com, davem@davemloft.net, gerald.schaefer@de.ibm.com, gregkh@linuxfoundation.org, heiko.carstens@de.ibm.com, jgg@ziepe.ca, jhogan@kernel.org, keescook@chromium.org, kirill@shutemov.name, linux@armlinux.org.uk, mark.rutland@arm.com, mm-commits@vger.kernel.org, mpe@ellerman.id.au, paul.burton@mips.com, paulus@samba.org, penguin-kernel@i-love.sakura.ne.jp, peterz@infradead.org, ralf@linux-mips.org, rppt@linux.vnet.ibm.com, schowdary@nvidia.com, schwidefsky@de.ibm.com, Steven.Price@arm.com, tglx@linutronix.de, vbabka@suse.cz, vgupta@synopsys.com, willy@infradead.org, yamada.masahiro@socionext.com, linux-mm@kvack.org References: <20191011202932.GZoUOoURm%akpm@linux-foundation.org> <20191014121730.GE317@dhcp22.suse.cz> <89f328f0-ca00-a9b0-8df6-808a53bfcdd4@arm.com> <20191014130023.GF317@dhcp22.suse.cz> <87be189d-6fb5-1cfb-4a39-714e75ff866c@arm.com> <20191015103100.GV317@dhcp22.suse.cz> From: Anshuman Khandual Message-ID: <709199af-c2b9-33df-bbaf-3de9cd6bc39e@arm.com> Date: Tue, 15 Oct 2019 16:04:42 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20191015103100.GV317@dhcp22.suse.cz> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit 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 10/15/2019 04:01 PM, Michal Hocko wrote: > On Tue 15-10-19 15:27:46, Anshuman Khandual wrote: >> >> >> On 10/14/2019 10:22 PM, Mike Kravetz wrote: >>> On 10/14/19 6:08 AM, Anshuman Khandual wrote: >>>> On 10/14/2019 06:30 PM, Michal Hocko wrote: >>>>> >>>>> OK, thanks for the clarification. This all means that this patch is not >>>>> the right approach. If you need a more generic alloc_contig_range then >>>>> add it to page_alloc.c and make it completely independent on the hugetlb >>>>> config and the code. Hugetlb allocator can reuse that helper. >>> >>> Should we revisit this previous attempt at such an interface? >>> >>> https://lkml.org/lkml/2018/4/16/1072 >>> >>> This looks like another use case. >>> >> >> The current proposal [v6] does not go far enough to unify all callers >> of alloc_contig_range() looking for contiguous pages of certain size, >> but instead it just tries not to duplicate HugeTLB gigantic allocation >> code in the test case for it's purpose. > > Please go and extract that functionality to a commonly usable helper. > Dependency on hugetlb is just ugly as hell. I did that in V6 and posted some time back. Could you please review that and let me know if anything needs to be improved. - Anshuman