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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0C665C6FD1D for ; Tue, 4 Apr 2023 07:22:23 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 6EE746B0071; Tue, 4 Apr 2023 03:22:23 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 69EE56B0074; Tue, 4 Apr 2023 03:22:23 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 53FDA6B0075; Tue, 4 Apr 2023 03:22:23 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id 3D8FB6B0071 for ; Tue, 4 Apr 2023 03:22:23 -0400 (EDT) Received: from smtpin22.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id F244A12032B for ; Tue, 4 Apr 2023 07:22:22 +0000 (UTC) X-FDA: 80642865324.22.70EAB10 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by imf04.hostedemail.com (Postfix) with ESMTP id 2DDB940002 for ; Tue, 4 Apr 2023 07:22:20 +0000 (UTC) Authentication-Results: imf04.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=CqHblzUj; spf=pass (imf04.hostedemail.com: domain of rppt@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=rppt@kernel.org; dmarc=pass (policy=none) header.from=kernel.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1680592941; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=ewOX4lclUYZ6lU0+Qx4rjcEuUU3cAUQFrNE+8G/H9FY=; b=N+KnnMErq1L3XeIFv5D5aruhemRPs/mU+PCYBolUMVkfmm2W+X5KlJFWhgJw0ysbMbvxhn L61bQkM0VsssIg95sDbnArrENvx1HlVi5xom2QIFrxHujg3rII11qMu8SyBqajDkzh5560 7J3XNXDJFTY9f5lj04GkN2G3GwyynvU= ARC-Authentication-Results: i=1; imf04.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=CqHblzUj; spf=pass (imf04.hostedemail.com: domain of rppt@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=rppt@kernel.org; dmarc=pass (policy=none) header.from=kernel.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1680592941; a=rsa-sha256; cv=none; b=AM/tRlGGOoaVaVKdNrA3y7Il77FuUEYHEOz3r5wz+99jUkaIU5T92JsY1OSuiSe9JCWhNL SNMELUa1rMsW/aioccYF8r5HxZLGl4tHbISbauSMP9gJZCXz3HI/Iww6lc70KtH9/aKh0B DIGfnkUhULiJ4GDxR5CD9u7hsFXYcsY= Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 187FE61248; Tue, 4 Apr 2023 07:22:20 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 18439C433D2; Tue, 4 Apr 2023 07:22:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1680592939; bh=zNbuc2c7Q9IWg5uy9hdmHULoUQBr2Hs/BAYhilZF5F4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=CqHblzUj1z5GNNRhlVv5PjhJZbkNnPlRJpd8BNP9SFM3LozxkSRnpQ6pJHq1734IE nD0HzFbv58nu6J/EDvb0/r/dPnGTG4/RX9IFH1dtOkbIUrpX4gBAxv+iMBA5DHcRED emlRqtXMUO+8S4B3gXHGAfaZat5oK//B6B2YKi3S5Gq0z1OVXNwTRQKMwaAeo6YUWs fVidc4rMbc4aUoxxzgWhlqdgki6r0Y6O3oX30JhcakMQVSnJAF09H5rT22qPoqcLsD 1rUCPCKRgr6yla1vp2aXejTBBX5r0wagFlZzYRUY3h9pSLxjoBb/Ad/MMOzP9CoNyA E21K1u28YAOpQ== Date: Tue, 4 Apr 2023 10:22:00 +0300 From: Mike Rapoport To: Justin Forbes Cc: Andrew Morton , Arnd Bergmann , Catalin Marinas , Christophe Leroy , "David S. Miller" , Dinh Nguyen , Geert Uytterhoeven , Guo Ren , John Paul Adrian Glaubitz , "Kirill A. Shutemov" , Max Filippov , Michael Ellerman , Rich Felker , Russell King , Will Deacon , Yoshinori Sato , Zi Yan , linux-arm-kernel@lists.infradead.org, linux-csky@vger.kernel.org, linux-ia64@vger.kernel.org, linux-kernel@vger.kernel.org, linux-m68k@lists.linux-m68k.org, linux-mm@kvack.org, linux-sh@vger.kernel.org, linux-xtensa@linux-xtensa.org, linuxppc-dev@lists.ozlabs.org, sparclinux@vger.kernel.org Subject: Re: [PATCH v3 02/14] arm64: drop ranges in definition of ARCH_FORCE_MAX_ORDER Message-ID: References: <20230325060828.2662773-1-rppt@kernel.org> <20230325060828.2662773-3-rppt@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Rspamd-Queue-Id: 2DDB940002 X-Stat-Signature: k8oxgxt4na458wmxafa7oj55hpa8fc3h X-Rspam-User: X-Rspamd-Server: rspam08 X-HE-Tag: 1680592940-275166 X-HE-Meta: U2FsdGVkX1+WPn07eHP+RtCq6fWRF4+ICNkS56fwkJpSz6ceoWuuzBCW5WQPMO4pSuvtARPZ9dsLJUucIavjX6BtlkJYeszehLY8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OvI6nkNC6B7+pAytsSIxP+2X7vsGyTiDLdkLe7arl5pKzVWVUG6bCgUzIMyPkvfsBmQ9CDZfi4LDDp3fy3pjn4LGkzKCZJJ7DB3cAk4ZXn5xToM5FtPwPKILxntqyZmTbXubfnA2hbiF1u96yqw3pfjI6zjl4H3wKVAE04uoiXlWscSFl+LJXEihuyjZVlQdF1EhLDjptQnht0b3YPe6IxO/RXYItIP8l8ZvGSFj48xG2+PVVb3WTp0kMqNi+k6jAGqZ114VaPGgh/dupIjiS+xvoNosEZr5bgbD/31U8pyulGoall6HYk0wQAy1Sv3HMgZp8JQIA== 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 Wed, Mar 29, 2023 at 10:55:37AM -0500, Justin Forbes wrote: > On Sat, Mar 25, 2023 at 1:09 AM Mike Rapoport wrote: > > > > From: "Mike Rapoport (IBM)" > > > > It is not a good idea to change fundamental parameters of core memory > > management. Having predefined ranges suggests that the values within > > those ranges are sensible, but one has to *really* understand > > implications of changing MAX_ORDER before actually amending it and > > ranges don't help here. > > > > Drop ranges in definition of ARCH_FORCE_MAX_ORDER and make its prompt > > visible only if EXPERT=y > > I do not like suddenly hiding this behind EXPERT for a couple of > reasons. Most importantly, it will silently change the config for > users building with an old kernel config. If a user has for instance > "13" set and building with 4K pages, as is the current configuration > for Fedora and RHEL aarch64 builds, an oldconfig build will now set it > to 10 with no indication that it is doing so. And while I think that > 10 is a fine default for many aarch64 users, there are valid reasons > for choosing other values. Putting this behind expert makes it much > less obvious that this is an option. That's the idea of EXPERT, no? This option was intended to allow allocation of huge pages for architectures that had PMD_ORDER > MAX_ORDER and not to allow user to select size of maximal physically contiguous allocation. Changes to MAX_ORDER fundamentally change the behaviour of core mm and unless users *really* know what they are doing there is no reason to choose non-default values so hiding this option behind EXPERT seems totally appropriate to me. > Justin > > > Acked-by: Kirill A. Shutemov > > Reviewed-by: Zi Yan > > Signed-off-by: Mike Rapoport (IBM) > > --- > > arch/arm64/Kconfig | 4 +--- > > 1 file changed, 1 insertion(+), 3 deletions(-) > > > > diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig > > index e60baf7859d1..7324032af859 100644 > > --- a/arch/arm64/Kconfig > > +++ b/arch/arm64/Kconfig > > @@ -1487,11 +1487,9 @@ config XEN > > # 16K | 27 | 14 | 13 | 11 | > > # 64K | 29 | 16 | 13 | 13 | > > config ARCH_FORCE_MAX_ORDER > > - int "Maximum zone order" if ARM64_4K_PAGES || ARM64_16K_PAGES > > + int "Maximum zone order" if EXPERT && (ARM64_4K_PAGES || ARM64_16K_PAGES) > > default "13" if ARM64_64K_PAGES > > - range 11 13 if ARM64_16K_PAGES > > default "11" if ARM64_16K_PAGES > > - range 10 15 if ARM64_4K_PAGES > > default "10" > > help > > The kernel memory allocator divides physically contiguous memory > > -- > > 2.35.1 > > > > -- Sincerely yours, Mike.