All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] ARM: defconfig: add unified config for RPi3 and RPi4
@ 2019-11-06 14:41 matthias.bgg at kernel.org
  2019-11-06 18:06 ` Heinrich Schuchardt
  0 siblings, 1 reply; 3+ messages in thread
From: matthias.bgg at kernel.org @ 2019-11-06 14:41 UTC (permalink / raw)
  To: u-boot

From: Matthias Brugger <mbrugger@suse.com>

Provide a defconfig which allows us to boot Raspberrry Pi 4
and Raspberry Pi 3 Model B/B+
Instead of using the embedded DTB as done in RPi3 we use the
devicetree provided by the firmware.

Signed-off-by: Matthias Brugger <mbrugger@suse.com>

---
This patch is based on the series to enable one binary for
RPi3 and RPi4:
https://patchwork.ozlabs.org/project/uboot/list/?series=140696

 arch/arm/mach-bcm283x/Kconfig |  7 ++++++
 configs/rpi_arm64_defconfig   | 45 +++++++++++++++++++++++++++++++++++
 2 files changed, 52 insertions(+)
 create mode 100644 configs/rpi_arm64_defconfig

diff --git a/arch/arm/mach-bcm283x/Kconfig b/arch/arm/mach-bcm283x/Kconfig
index e8e0ff0eb4..00419bf254 100644
--- a/arch/arm/mach-bcm283x/Kconfig
+++ b/arch/arm/mach-bcm283x/Kconfig
@@ -188,6 +188,13 @@ config TARGET_RPI_4
 	  This option creates a build targeting the ARMv8/AArch64 ISA.
 	select BCM2711_64B
 
+config TARGET_RPI_ARM64
+	bool "Raspberry Pi one binary 64-bit build"
+	help
+	  Support for all armv8 based Raspberry Pi variants, such as
+	  the RPi 4 model B, in AArch64 (64-bit) mode.
+	select ARM64
+
 endchoice
 
 config SYS_BOARD
diff --git a/configs/rpi_arm64_defconfig b/configs/rpi_arm64_defconfig
new file mode 100644
index 0000000000..f4e113f58c
--- /dev/null
+++ b/configs/rpi_arm64_defconfig
@@ -0,0 +1,45 @@
+CONFIG_ARM=y
+CONFIG_ARM64=y
+CONFIG_TARGET_RPI_ARM64=y
+CONFIG_ARCH_BCM283X=y
+CONFIG_SYS_TEXT_BASE=0x00080000
+CONFIG_SYS_MALLOC_F_LEN=0x2000
+CONFIG_DISTRO_DEFAULTS=y
+CONFIG_NR_DRAM_BANKS=2
+CONFIG_OF_BOARD_SETUP=y
+CONFIG_USE_PREBOOT=y
+CONFIG_PREBOOT="usb start"
+CONFIG_MISC_INIT_R=y
+# CONFIG_DISPLAY_CPUINFO is not set
+# CONFIG_DISPLAY_BOARDINFO is not set
+CONFIG_SYS_PROMPT="U-Boot> "
+# CONFIG_CMD_FLASH is not set
+CONFIG_CMD_GPIO=y
+CONFIG_CMD_MMC=y
+CONFIG_CMD_USB=y
+CONFIG_CMD_FS_UUID=y
+CONFIG_OF_BOARD=y
+CONFIG_ENV_FAT_INTERFACE="mmc"
+CONFIG_ENV_FAT_DEVICE_AND_PART="0:1"
+CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
+CONFIG_DM_KEYBOARD=y
+CONFIG_DM_MMC=y
+CONFIG_MMC_SDHCI=y
+CONFIG_MMC_SDHCI_BCM2835=y
+CONFIG_PHYLIB=y
+CONFIG_DM_ETH=y
+CONFIG_PINCTRL=y
+# CONFIG_PINCTRL_GENERIC is not set
+# CONFIG_REQUIRE_SERIAL_CONSOLE is not set
+CONFIG_USB=y
+CONFIG_DM_USB=y
+CONFIG_USB_DWC2=y
+CONFIG_USB_KEYBOARD=y
+CONFIG_USB_HOST_ETHER=y
+CONFIG_USB_ETHER_LAN78XX=y
+CONFIG_USB_ETHER_SMSC95XX=y
+CONFIG_DM_VIDEO=y
+CONFIG_SYS_WHITE_ON_BLACK=y
+CONFIG_CONSOLE_SCROLL_LINES=10
+CONFIG_PHYS_TO_BUS=y
+CONFIG_OF_LIBFDT_OVERLAY=y
-- 
2.23.0

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [U-Boot] [PATCH] ARM: defconfig: add unified config for RPi3 and RPi4
  2019-11-06 14:41 [U-Boot] [PATCH] ARM: defconfig: add unified config for RPi3 and RPi4 matthias.bgg at kernel.org
@ 2019-11-06 18:06 ` Heinrich Schuchardt
  2019-11-06 19:40   ` Matthias Brugger
  0 siblings, 1 reply; 3+ messages in thread
From: Heinrich Schuchardt @ 2019-11-06 18:06 UTC (permalink / raw)
  To: u-boot

On 11/6/19 3:41 PM, matthias.bgg at kernel.org wrote:
> From: Matthias Brugger <mbrugger@suse.com>
>
> Provide a defconfig which allows us to boot Raspberrry Pi 4
> and Raspberry Pi 3 Model B/B+
> Instead of using the embedded DTB as done in RPi3 we use the
> devicetree provided by the firmware.

How different are the DTBs provided by different firmware releases?

Could we run into problems because some elder or newer firmware releases
are not supported by U-Boot? - This prospect is what makes your patch a
bit scary to me.

Which different firmware releases did you test against?

Do you plan to keep the existing defconfigs and dtbs?

Best regards

Heinrich

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [U-Boot] [PATCH] ARM: defconfig: add unified config for RPi3 and RPi4
  2019-11-06 18:06 ` Heinrich Schuchardt
@ 2019-11-06 19:40   ` Matthias Brugger
  0 siblings, 0 replies; 3+ messages in thread
From: Matthias Brugger @ 2019-11-06 19:40 UTC (permalink / raw)
  To: u-boot



On 06/11/2019 19:06, Heinrich Schuchardt wrote:
> On 11/6/19 3:41 PM, matthias.bgg at kernel.org wrote:
>> From: Matthias Brugger <mbrugger@suse.com>
>>
>> Provide a defconfig which allows us to boot Raspberrry Pi 4
>> and Raspberry Pi 3 Model B/B+
>> Instead of using the embedded DTB as done in RPi3 we use the
>> devicetree provided by the firmware.
> 
> How different are the DTBs provided by different firmware releases?
> 
> Could we run into problems because some elder or newer firmware releases
> are not supported by U-Boot? - This prospect is what makes your patch a
> bit scary to me.
That could happen, but I suppose especially for older releases. Newer releases
tend to change in the direction of upstream.

> 
> Which different firmware releases did you test against?
> 
> Do you plan to keep the existing defconfigs and dtbs?
> 

I didn't do any extensive testing to be honest. We are using the DTB from the
firmware on RPi4 already, and I expect that newer firmwares won't break U-Boot.

My idea is to keep the existing defconfigs. Apart from being a good fallback
option if really something breaks, there might be some distros use U-Boot with
this config files and I don't want to break the setup for them.

Regards,
Matthias

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-11-06 19:40 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-06 14:41 [U-Boot] [PATCH] ARM: defconfig: add unified config for RPi3 and RPi4 matthias.bgg at kernel.org
2019-11-06 18:06 ` Heinrich Schuchardt
2019-11-06 19:40   ` Matthias Brugger

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.