From: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
To: Florian Fainelli <f.fainelli@gmail.com>,
Stefan Wahren <wahrenst@gmx.net>
Cc: mbrugger@suse.com, Russell King <linux@armlinux.org.uk>,
linux-kernel@vger.kernel.org,
bcm-kernel-feedback-list@broadcom.com,
linux-rpi-kernel@lists.infradead.org, hch@lst.de,
linux-arm-kernel@lists.infradead.org
Subject: Re: [RFC] ARM: add bcm2711_defconfig
Date: Wed, 08 Jan 2020 14:53:22 +0100 [thread overview]
Message-ID: <5a9d1f01a8b7c8f42ef0819a40d364e7e1c07f2f.camel@suse.de> (raw)
In-Reply-To: <5db5ed47-adab-8d31-c3f7-4d7f63258e22@gmail.com>
[-- Attachment #1.1: Type: text/plain, Size: 3788 bytes --]
On Tue, 2020-01-07 at 10:28 -0800, Florian Fainelli wrote:
> On 1/7/20 10:11 AM, Nicolas Saenz Julienne wrote:
> > On Tue, 2020-01-07 at 19:06 +0100, Stefan Wahren wrote:
> > > Hi Nicolas,
> > >
> > > Am 07.01.20 um 18:24 schrieb Nicolas Saenz Julienne:
> > > > The Raspberry Pi 4 depends on LPAE in order to use its PCIe port, which
> > > > is essential, as it ultimately provides USB2/3 connectivity. As this
> > > > setup doesn't fit any generic purpose configuration this adds
> > > > bcm2711_defconfig which is based on the current Raspberry Pi foundation
> > > > config file[1] with as little changes as possible
> > >
> > > i really dislike the Foundation config file, because it contains so many
> > > unnecessary features. Bisecting with such a kernel config is horrible.
> > >
> > > How about finding a compromise between bcm2835_defconfig and
> > > multi_v7_defconfig + LPAE?
> >
> > If there is a consensus this is the right approach (creating a new config
> > file), I'll be happy to try that out.
> >
> > Now that I think of it, maybe we shouldn't add bcm2711_thermal into
> > multi_v7_defconfig.
>
> It there a mechanism that can be used such that bcm2711_defconfig would
> be simply a fragment that enables CONFIG_ARM_LPAE=y (and other relevant
> 2711 only options) and that you could easily run/test with, something like:
>
> ARCH=arm make bcm2835_defconfig+bcm2711_defconfig
>
> or something along those lines?
Well I found out about: 'scripts/kconfig/merge_config.sh' which more or less
does that. I think we could use it to build bcm2711_defconfig based off
bcm2835_defconfig. Or even better, create a multi_v7_lpae_defconfig. See:
Author: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Date: Wed Jan 8 14:30:56 2020 +0100
ARM: Add multi_v7_lpae_defconfig
The only missing configuration option preventing us from using
multi_v7_defconfig with the RPi4 is ARM_LPAE. It's needed as the PCIe
controller found on the SoC depends on 64bit addressing, yet can't be
included as not all v7 boards support LPAE.
Introduce multi_v7_lpae_defconfig, built off multi_v7_defconfig, which will
avoid us having to duplicate and maintain multiple similar configurations.
Note that merge_into_defconfig was taken from arch/powerpc/Makefile.
Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 16d41efea7f2..bf6379c718ee 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -359,6 +359,20 @@ archclean:
# My testing targets (bypasses dependencies)
bp:; $(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) $(boot)/bootpImage
+# Used to create 'merged defconfigs'
+# To use it $(call) it with the first argument as the base defconfig
+# and the second argument as a space separated list of .config files to merge,
+# without the .config suffix.
+define merge_into_defconfig
+ $(Q)$(CONFIG_SHELL) $(srctree)/scripts/kconfig/merge_config.sh \
+ -m -O $(objtree) $(srctree)/arch/$(ARCH)/configs/$(1) \
+ $(foreach
config,$(2),$(srctree)/arch/$(ARCH)/configs/$(config).config)
+ +$(Q)$(MAKE) -f $(srctree)/Makefile olddefconfig
+endef
+
+PHONY += multi_v7_lpae_defconfig
+multi_v7_lpae_defconfig:
+ $(call merge_into_defconfig,multi_v7_defconfig,lpae)
define archhelp
echo '* zImage - Compressed kernel image (arch/$(ARCH)/boot/zImage)'
diff --git a/arch/arm/configs/lpae.config b/arch/arm/configs/lpae.config
new file mode 100644
index 000000000000..19bab134e014
--- /dev/null
+++ b/arch/arm/configs/lpae.config
@@ -0,0 +1 @@
+CONFIG_ARM_LPAE=y
Any thoughts? Is this a little bit too much?
Regards,
Nicolas
[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
[-- Attachment #2: Type: text/plain, Size: 176 bytes --]
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
prev parent reply other threads:[~2020-01-08 13:53 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-07 17:24 [RFC] ARM: add bcm2711_defconfig Nicolas Saenz Julienne
2020-01-07 18:06 ` Stefan Wahren
2020-01-07 18:11 ` Nicolas Saenz Julienne
2020-01-07 18:28 ` Florian Fainelli
2020-01-08 13:53 ` Nicolas Saenz Julienne [this message]
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=5a9d1f01a8b7c8f42ef0819a40d364e7e1c07f2f.camel@suse.de \
--to=nsaenzjulienne@suse.de \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=f.fainelli@gmail.com \
--cc=hch@lst.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rpi-kernel@lists.infradead.org \
--cc=linux@armlinux.org.uk \
--cc=mbrugger@suse.com \
--cc=wahrenst@gmx.net \
/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