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=-8.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable 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 C929AC63697 for ; Sat, 14 Nov 2020 12:15:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 93F1B2224F for ; Sat, 14 Nov 2020 12:15:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726802AbgKNMPY (ORCPT ); Sat, 14 Nov 2020 07:15:24 -0500 Received: from mail.kernel.org ([198.145.29.99]:33672 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726756AbgKNMPY (ORCPT ); Sat, 14 Nov 2020 07:15:24 -0500 Received: from gaia (unknown [2.26.170.190]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4D4BE221EB; Sat, 14 Nov 2020 12:15:20 +0000 (UTC) Date: Sat, 14 Nov 2020 12:15:17 +0000 From: Catalin Marinas To: Mike Rapoport Cc: Andrew Morton , Alexey Dobriyan , Geert Uytterhoeven , Greg Ungerer , John Paul Adrian Glaubitz , Jonathan Corbet , Matt Turner , Meelis Roos , Michael Schmitz , Mike Rapoport , Russell King , Tony Luck , Vineet Gupta , Will Deacon , linux-alpha@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-ia64@vger.kernel.org, linux-kernel@vger.kernel.org, linux-m68k@lists.linux-m68k.org, linux-mm@kvack.org, linux-snps-arc@lists.infradead.org Subject: Re: [PATCH v2 09/13] arm, arm64: move free_unused_memmap() to generic mm Message-ID: <20201114121516.GA2837@gaia> References: <20201101170454.9567-1-rppt@kernel.org> <20201101170454.9567-10-rppt@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201101170454.9567-10-rppt@kernel.org> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On Sun, Nov 01, 2020 at 07:04:50PM +0200, Mike Rapoport wrote: > From: Mike Rapoport > > ARM and ARM64 free unused parts of the memory map just before the > initialization of the page allocator. To allow holes in the memory map both > architectures overload pfn_valid() and define HAVE_ARCH_PFN_VALID. > > Allowing holes in the memory map for FLATMEM may be useful for small > machines, such as ARC and m68k and will enable those architectures to cease > using DISCONTIGMEM and still support more than one memory bank. > > Move the functions that free unused memory map to generic mm and enable > them in case HAVE_ARCH_PFN_VALID=y. > > Signed-off-by: Mike Rapoport For arm64: Acked-by: Catalin Marinas