From: Catalin Marinas <catalin.marinas@arm.com>
To: Marc Zyngier <maz@kernel.org>
Cc: Will Deacon <will@kernel.org>,
linux-arm-kernel@lists.infradead.org,
"Justin M . Forbes" <jforbes@fedoraproject.org>,
Mike Rapoport <rppt@kernel.org>,
Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH] arm64: Make the ARCH_FORCE_MAX_ORDER config input prompt unconditional
Date: Thu, 18 May 2023 17:04:26 +0100 [thread overview]
Message-ID: <ZGZMivgULQZiF5zn@arm.com> (raw)
In-Reply-To: <86edndljkj.wl-maz@kernel.org>
On Thu, May 18, 2023 at 04:56:28PM +0100, Marc Zyngier wrote:
> On Wed, 03 May 2023 13:33:42 +0100,
> Catalin Marinas <catalin.marinas@arm.com> wrote:
> > diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig
> > index b1201d25a8a4..1867aba83ba3 100644
> > --- a/arch/arm64/Kconfig
> > +++ b/arch/arm64/Kconfig
> > @@ -1516,7 +1516,7 @@ config XEN
> > # 16K | 27 | 14 | 13 | 11 |
> > # 64K | 29 | 16 | 13 | 13 |
> > config ARCH_FORCE_MAX_ORDER
> > - int "Order of maximal physically contiguous allocations" if EXPERT && (ARM64_4K_PAGES || ARM64_16K_PAGES)
> > + int "Order of maximal physically contiguous allocations"
> > default "13" if ARM64_64K_PAGES
> > default "11" if ARM64_16K_PAGES
> > default "10"
>
> This patch (and the previous one) has the unfortunate side effect of
> completely breaking a change of page size (from 4k to 16k, for
> example):
>
> <quote>
> maz@valley-girl:~/hot-poop/arm-platforms$ make defconfig
> *** Default configuration is based on 'defconfig'
> #
> # configuration written to .config
> #
> maz@valley-girl:~/hot-poop/arm-platforms$ egrep 'PAGE_SHIFT|MAX_ORDER' .config
> CONFIG_ARM64_PAGE_SHIFT=12
> CONFIG_ARCH_FORCE_MAX_ORDER=10
> maz@valley-girl:~/hot-poop/arm-platforms$ make menuconfig
> configuration written to .config
>
> *** End of the configuration.
> *** Execute 'make' to start the build or try 'make help'.
>
> maz@valley-girl:~/hot-poop/arm-platforms$ egrep 'PAGE_SHIFT|MAX_ORDER' .config
> CONFIG_ARM64_PAGE_SHIFT=14
> CONFIG_ARCH_FORCE_MAX_ORDER=10
> </quote>
>
> The build then fails in ways that aren't obvious (BUILD_BUG in the THP
> code). It would much better if the result of the configuration tool
> would produce something that can actually build.
Thanks Marc for reporting this. The main culprit is the removal of the
ranges, so MAX_ORDER stays at 10 when changing the page size, but only
with EXPERT enabled. With this patch, it just generalises the problem
even without EXPERT.
So we either re-introduce the ranges or we drop the menuconfig entry
completely, regardless of EXPERT. I'm inclined to go with the latter,
just don't allow people to redefine this (still unclear to me if we need
a higher default with 4K pages).
--
Catalin
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2023-05-18 16:04 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-03 12:33 [PATCH] arm64: Make the ARCH_FORCE_MAX_ORDER config input prompt unconditional Catalin Marinas
2023-05-03 14:58 ` Mike Rapoport
2023-05-03 15:35 ` Justin Forbes
2023-05-03 15:41 ` Ard Biesheuvel
2023-05-05 22:00 ` Mike Rapoport
2023-05-05 22:08 ` Ard Biesheuvel
2023-05-05 22:47 ` Mike Rapoport
2023-05-05 22:51 ` Ard Biesheuvel
2023-05-05 23:23 ` Mike Rapoport
2023-05-16 15:14 ` Will Deacon
2023-05-18 15:56 ` Marc Zyngier
2023-05-18 16:04 ` Catalin Marinas [this message]
2023-05-19 10:35 ` Will Deacon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ZGZMivgULQZiF5zn@arm.com \
--to=catalin.marinas@arm.com \
--cc=akpm@linux-foundation.org \
--cc=jforbes@fedoraproject.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=maz@kernel.org \
--cc=rppt@kernel.org \
--cc=will@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).