Add support Raspberry-Pi Ziro W
Subsystems (4)
PATCH 1/1 Add support Raspberry-Pi Ziro W
--- arch/arm/dts/bcm2835-rpi-zero-w.dts | 44 ++++++++++++++++++++++++++++++++++ arch/arm/dts/bcm283x-rpi-usb-host.dtsi | 3 +++ arch/arm/mach-bcm283x/Kconfig | 16 +++++++++++++ board/raspberrypi/rpi/rpi.c | 5 ++++ configs/rpi_0_w_defconfig | 28 ++++++++++++++++++++++ include/configs/rpi.h | 2 +- 6 files changed, 97 insertions(+), 1 deletion(-) create mode 100644 arch/arm/dts/bcm2835-rpi-zero-w.dts create mode 100644 arch/arm/dts/bcm283x-rpi-usb-host.dtsi create mode 100644 configs/rpi_0_w_defconfig
arch/arm/dts/bcm2835-rpi-zero-w.dts new file +44 -0
@@ -0,0 +1,44 @@ +/* + * Copyright (C) 2016 Stefan Wahren <[email protected]> + * + * The code contained herein is licensed under the GNU General Public + * License. You may obtain a copy of the GNU General Public License + * Version 2 or later at the following locations: + * + * http://www.opensource.org/licenses/gpl-license.html + * http://www.gnu.org/copyleft/gpl.html + */ + +/dts-v1/; +#include "bcm2835.dtsi" +#include "bcm2835-rpi.dtsi" +#include "bcm283x-rpi-usb-host.dtsi" + +/ { + compatible = "raspberrypi,model-zero-w", "brcm,bcm2835"; + model = "Raspberry Pi Zero W"; + + leds { + act { + gpios = <&gpio 47 0>; + }; + }; +}; + +&gpio { + pinctrl-0 = <&gpioout &alt0 &i2s_alt0 &alt3>; + + /* I2S interface */ + i2s_alt0: i2s_alt0 { + brcm,pins = <18 19 20 21>; + brcm,function = <BCM2835_FSEL_ALT0>; + }; +}; + +&uart1 { + status = "okay"; +}; + +&hdmi { + hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>; +};
arch/arm/dts/bcm283x-rpi-usb-host.dtsi new file +3 -0
@@ -0,0 +1,3 @@ +&usb { + dr_mode = "host"; +};
arch/arm/mach-bcm283x/Kconfig +16 -0
@@ -44,6 +44,22 @@ config TARGET_RPI This option creates a build targetting the ARM1176 ISA. select BCM2835 +config TARGET_RPI_0_W + bool "Raspberry Pi Ziro W" + help + Support for all ARM1176-/BCM2835-based Raspberry Pi variants, such as + the RPi Zero model W. + + This option assumes the VideoCore firmware is configured to use the + mini UART (rather than PL011) for the serial console. This is the + default on the RPi Zero W. To enable the UART console, the following + non-default option must be present in config.txt: enable_uart=1. + This is required for U-Boot to operate correctly, even if you only + care about the HDMI/usbkbd console. + + This option creates a build targetting the ARMv7/AArch32 ISA. + select BCM2835 + config TARGET_RPI_2 bool "Raspberry Pi 2" help
board/raspberrypi/rpi/rpi.c +5 -0
@@ -105,6 +105,11 @@ static const struct rpi_model rpi_models_new_scheme[] = {DTB_DIR "bcm2835-rpi-zero.dtb" , false, }, + [0xC] = { +"Zero W" , +DTB_DIR "bcm2835-rpi-zero-w.dtb" , + false, + }, }; static const struct rpi_model rpi_models_old_scheme[] = {
configs/rpi_0_w_defconfig new file +28 -0
@@ -0,0 +1,28 @@ +CONFIG_ARM=y +CONFIG_ARCH_BCM283X=y +CONFIG_TARGET_RPI_0_W=y +CONFIG_DEFAULT_DEVICE_TREE="bcm2835-rpi-zero-w" +CONFIG_DISTRO_DEFAULTS=y +CONFIG_OF_BOARD_SETUP=y +# CONFIG_DISPLAY_CPUINFO is not set +# CONFIG_DISPLAY_BOARDINFO is not set +CONFIG_SYS_PROMPT="U-Boot> " +# CONFIG_CMD_IMLS is not set +# CONFIG_CMD_FLASH is not set +CONFIG_CMD_MMC=y +CONFIG_CMD_USB=y +# CONFIG_CMD_FPGA is not set +CONFIG_CMD_GPIO=y +CONFIG_DM_MMC=y +CONFIG_MMC_SDHCI=y +CONFIG_MMC_SDHCI_BCM2835=y +CONFIG_DM_ETH=y +CONFIG_USB=y +CONFIG_DM_USB=y +CONFIG_USB_STORAGE=y +CONFIG_USB_KEYBOARD=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
include/configs/rpi.h +1 -1
@@ -80,7 +80,7 @@#endif /* Console UART */ -#ifdef CONFIG_BCM2837 +#if defined (CONFIG_BCM2837 ) || defined(CONFIG_TARGET_RPI_0_W )#define CONFIG_BCM283X_MU_SERIAL #else #define CONFIG_PL01X_SERIAL
Signature · 1 line
2.7.4
PATCH 1/1 Add support Raspberry-Pi Ziro W
Quoted 1 line · Dmitry Korunov
Signed-off-by Dmitry Korunov <[email protected]>
How about a summary of the board?
CPU
Memory
Storage
USB
Wi-fi
Ethernet
etc.
Quoted 18 lines
--- arch/arm/dts/bcm2835-rpi-zero-w.dts | 44 ++++++++++++++++++++++++++++++++++ arch/arm/dts/bcm283x-rpi-usb-host.dtsi | 3 +++ arch/arm/mach-bcm283x/Kconfig | 16 +++++++++++++ board/raspberrypi/rpi/rpi.c | 5 ++++ configs/rpi_0_w_defconfig | 28 ++++++++++++++++++++++ include/configs/rpi.h | 2 +- 6 files changed, 97 insertions(+), 1 deletion(-) create mode 100644 arch/arm/dts/bcm2835-rpi-zero-w.dts create mode 100644 arch/arm/dts/bcm283x-rpi-usb-host.dtsi create mode 100644 configs/rpi_0_w_defconfigarch/arm/dts/bcm2835-rpi-zero-w.dts new file +0
-0
arch/arm/dts/bcm2835-rpi-zero-w.dts line 2
Quoted 2 lines
arch/arm/dts/bcm2835-rpi-zero-w.dts new file +2
-0@@ -0,0 +1,44 @@ +/* + * Copyright (C) 2016 Stefan Wahren <[email protected]>
Is this still correct?
arch/arm/mach-bcm283x/Kconfig config TARGET_RPI · line 48
Quoted 8 lines
arch/arm/mach-bcm283x/Kconfig +2
-0@@ -44,6 +44,22 @@ config TARGET_RPI This option creates a build targetting the ARM1176 ISA. select BCM2835 +config TARGET_RPI_0_W + bool "Raspberry Pi Ziro W"
Surplus space before W.
arch/arm/mach-bcm283x/Kconfig config TARGET_RPI · line 51
Quoted 3 lines
arch/arm/mach-bcm283x/Kconfig +3
-0+ help + Support for all ARM1176-/BCM2835-based Raspberry Pi variants, such as + the RPi Zero model W.
So which is it? "Ziro W" or "Zero W"? Your commit message summary says "Ziro W" but your patch is mostly about the "Zero W".
Quoted 19 lines
arch/arm/mach-bcm283x/Kconfig +11
-0+ + This option assumes the VideoCore firmware is configured to use the + mini UART (rather than PL011) for the serial console. This is the + default on the RPi Zero W. To enable the UART console, the following + non-default option must be present in config.txt: enable_uart=1. + This is required for U-Boot to operate correctly, even if you only + care about the HDMI/usbkbd console. + + This option creates a build targetting the ARMv7/AArch32 ISA. + select BCM2835 + config TARGET_RPI_2 bool "Raspberry Pi 2" helpinclude/configs/rpi.h +0
-0
include/configs/rpi.h line 83
Quoted 5 lines
include/configs/rpi.h +1
-1@@ -80,7 +80,7 @@#endif /* Console UART */ -#ifdef CONFIG_BCM2837 +#if defined (CONFIG_BCM2837 ) || defined(CONFIG_TARGET_RPI_0_W )
Another surplus space.
Signature · 1 line
Rask Ingemann Lambertsen
PATCH v2 1/1 add support for Raspberry Pi Zero W
In reply to Dmitry KorunovThe Raspberry Pi Zero W extends the Pi Zero family and it's also based on a BCM2835 SoC. Like the Pi Zero, it has 512MB RAM, Mini HDMI and USB On-The-Go ports. Both Pi's hasn't got Ethernet, but Pi Zero W has built in wireless LAN 802.11 b/g/n.
---
Changes for v2:
- removed surplus spaces
- added the board description
arch/arm/dts/bcm2835-rpi-zero-w.dts | 33 +++++++++++++++++++++++++++++++++ arch/arm/dts/bcm283x-rpi-usb-host.dtsi | 3 +++ arch/arm/mach-bcm283x/Kconfig | 16 ++++++++++++++++ board/raspberrypi/rpi/rpi.c | 5 +++++ configs/rpi_0_w_defconfig | 28 ++++++++++++++++++++++++++++ include/configs/rpi.h | 2 +- 6 files changed, 86 insertions(+), 1 deletion(-) create mode 100644 arch/arm/dts/bcm2835-rpi-zero-w.dts create mode 100644 arch/arm/dts/bcm283x-rpi-usb-host.dtsi create mode 100644 configs/rpi_0_w_defconfig
arch/arm/dts/bcm2835-rpi-zero-w.dts new file +33 -0
@@ -0,0 +1,33 @@ +/dts-v1/; +#include "bcm2835.dtsi" +#include "bcm2835-rpi.dtsi" +#include "bcm283x-rpi-usb-host.dtsi" + +/ { + compatible = "raspberrypi,model-zero-w", "brcm,bcm2835"; + model = "Raspberry Pi Zero W"; + + leds { + act { + gpios = <&gpio 47 0>; + }; + }; +}; + +&gpio { + pinctrl-0 = <&gpioout &alt0 &i2s_alt0 &alt3>; + + /* I2S interface */ + i2s_alt0: i2s_alt0 { + brcm,pins = <18 19 20 21>; + brcm,function = <BCM2835_FSEL_ALT0>; + }; +}; + +&uart1 { + status = "okay"; +}; + +&hdmi { + hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>; +};
arch/arm/dts/bcm283x-rpi-usb-host.dtsi new file +3 -0
@@ -0,0 +1,3 @@ +&usb { + dr_mode = "host"; +};
arch/arm/mach-bcm283x/Kconfig +16 -0
@@ -44,6 +44,22 @@ config TARGET_RPI This option creates a build targetting the ARM1176 ISA. select BCM2835 +config TARGET_RPI_0_W + bool "Raspberry Pi Zero W" + help + Support for all ARM1176-/BCM2835-based Raspberry Pi variants, such as + the RPi Zero model W. + + This option assumes the VideoCore firmware is configured to use the + mini UART (rather than PL011) for the serial console. This is the + default on the RPi Zero W. To enable the UART console, the following + non-default option must be present in config.txt: enable_uart=1. + This is required for U-Boot to operate correctly, even if you only + care about the HDMI/usbkbd console. + + This option creates a build targetting the ARMv7/AArch32 ISA. + select BCM2835 + config TARGET_RPI_2 bool "Raspberry Pi 2" help
board/raspberrypi/rpi/rpi.c +5 -0
@@ -105,6 +105,11 @@ static const struct rpi_model rpi_models_new_scheme[] = {DTB_DIR "bcm2835-rpi-zero.dtb" , false, }, + [0xC] = { +"Zero W" , +DTB_DIR "bcm2835-rpi-zero-w.dtb" , + false, + }, }; static const struct rpi_model rpi_models_old_scheme[] = {
configs/rpi_0_w_defconfig new file +28 -0
@@ -0,0 +1,28 @@ +CONFIG_ARM=y +CONFIG_ARCH_BCM283X=y +CONFIG_TARGET_RPI_0_W=y +CONFIG_DEFAULT_DEVICE_TREE="bcm2835-rpi-zero-w" +CONFIG_DISTRO_DEFAULTS=y +CONFIG_OF_BOARD_SETUP=y +# CONFIG_DISPLAY_CPUINFO is not set +# CONFIG_DISPLAY_BOARDINFO is not set +CONFIG_SYS_PROMPT="U-Boot> " +# CONFIG_CMD_IMLS is not set +# CONFIG_CMD_FLASH is not set +CONFIG_CMD_MMC=y +CONFIG_CMD_USB=y +# CONFIG_CMD_FPGA is not set +CONFIG_CMD_GPIO=y +CONFIG_DM_MMC=y +CONFIG_MMC_SDHCI=y +CONFIG_MMC_SDHCI_BCM2835=y +CONFIG_DM_ETH=y +CONFIG_USB=y +CONFIG_DM_USB=y +CONFIG_USB_STORAGE=y +CONFIG_USB_KEYBOARD=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
include/configs/rpi.h +1 -1
@@ -79,7 +79,7 @@#endif /* Console UART */ -#ifdef CONFIG_BCM2837 +#if defined (CONFIG_BCM2837 ) || defined(CONFIG_TARGET_RPI_0_W )#define CONFIG_BCM283X_MU_SERIAL #else #define CONFIG_PL01X_SERIAL
Signature · 1 line
2.7.4
PATCH v2 1/1 add support for Raspberry Pi Zero W
Quoted 6 lines · Dmitry Korunov
The Raspberry Pi Zero W extends the Pi Zero family and it's also based on a BCM2835 SoC. Like the Pi Zero, it has 512MB RAM, Mini HDMI and USB On-The-Go ports. Both Pi's hasn't got Ethernet, but Pi Zero W has built in wireless LAN 802.11 b/g/n.
Signed-off-by Dmitry Korunov <[email protected]>
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20170802/7c587f81/attachment.sig>
PATCH v2 1/1 add support for Raspberry Pi Zero W
In reply to Dmitry KorunovAm 01.08.2017 um 16:47 schrieb Dmitry Korunov:
Quoted 20 lines
The Raspberry Pi Zero W extends the Pi Zero family and it's also based on a BCM2835 SoC. Like the Pi Zero, it has 512MB RAM, Mini HDMI and USB On-The-Go ports. Both Pi's hasn't got Ethernet, but Pi Zero W has built in wireless LAN 802.11 b/g/n.
Signed-off-by Dmitry Korunov <[email protected]>---
Changes for v2:
- removed surplus spaces
- added the board descriptionarch/arm/dts/bcm2835-rpi-zero-w.dts | 33 +++++++++++++++++++++++++++++++++ arch/arm/dts/bcm283x-rpi-usb-host.dtsi | 3 +++ arch/arm/mach-bcm283x/Kconfig | 16 ++++++++++++++++ board/raspberrypi/rpi/rpi.c | 5 +++++ configs/rpi_0_w_defconfig | 28 ++++++++++++++++++++++++++++ include/configs/rpi.h | 2 +- 6 files changed, 86 insertions(+), 1 deletion(-) create mode 100644 arch/arm/dts/bcm2835-rpi-zero-w.dts
Quoted 1 line
create mode 100644 arch/arm/dts/bcm283x-rpi-usb-host.dtsi
This file is already present in the meantime (but applies with --3way).
Quoted 16 lines
create mode 100644 configs/rpi_0_w_defconfigarch/arm/dts/bcm2835-rpi-zero-w.dts new file +8
-0@@ -0,0 +1,33 @@ +/dts-v1/; +#include "bcm2835.dtsi" +#include "bcm2835-rpi.dtsi" +#include "bcm283x-rpi-usb-host.dtsi" + +/ { + compatible = "raspberrypi,model-zero-w", "brcm,bcm2835"; + model = "Raspberry Pi Zero W";
arch/arm/dts/bcm2835-rpi-zero-w.dts line 18
Quoted 10 lines
arch/arm/dts/bcm2835-rpi-zero-w.dts new file +10
-0+ + leds { + act { + gpios = <&gpio 47 0>; + }; + }; +}; + +&gpio { + pinctrl-0 = <&gpioout &alt0 &i2s_alt0 &alt3>;
DTC arch/arm/dts/bcm2835-rpi-zero-w.dtbarch/arm/dts/bcm2835-rpi-zero-w.dtb: ERROR (phandle_references):
Reference to non-existent node or label "alt3"
ERROR: Input tree has errors, aborting (use -f to force output)
If I comment out alt3, it builds and boots okay. How to fix properly?
arch/arm/dts/bcm2835-rpi-zero-w.dts line 27
Quoted 9 lines
arch/arm/dts/bcm2835-rpi-zero-w.dts new file +9
-0+ + /* I2S interface */ + i2s_alt0: i2s_alt0 { + brcm,pins = <18 19 20 21>; + brcm,function = <BCM2835_FSEL_ALT0>; + }; +}; + +&uart1 {
The v4.14 .dts file does not have this and does not seem to work. Does this need to go into a -uboot.dtsi file instead or do more files need a refresh?
Regards,
Andreas
Quoted 6 lines
arch/arm/dts/bcm2835-rpi-zero-w.dts new file +6
-0+ status = "okay"; +}; + +&hdmi { + hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>; +};
[snip]
Signature · 3 lines
SUSE Linux GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB 21284 (AG Nürnberg)
PATCH v3 1/1 add support for Raspberry Pi Zero W
In reply to Dmitry Korunov---
Changes for v2:
- removed surplus spaces
- added the board description
Changes for v3:
- excluded already merged *.dtsi files
- updated device tree file to appropriate master branch
arch/arm/dts/bcm2835-rpi-zero-w.dts | 26 ++++++++++++++++++++++++++ arch/arm/mach-bcm283x/Kconfig | 16 ++++++++++++++++ board/raspberrypi/rpi/rpi.c | 5 +++++ configs/rpi_0_w_defconfig | 28 ++++++++++++++++++++++++++++ include/configs/rpi.h | 2 +- 5 files changed, 76 insertions(+), 1 deletion(-) create mode 100644 arch/arm/dts/bcm2835-rpi-zero-w.dts create mode 100644 configs/rpi_0_w_defconfig
arch/arm/dts/bcm2835-rpi-zero-w.dts new file +26 -0
@@ -0,0 +1,26 @@ +/dts-v1/; +#include "bcm2835.dtsi" +#include "bcm2835-rpi.dtsi" +#include "bcm283x-rpi-smsc9512.dtsi" +#include "bcm283x-rpi-usb-host.dtsi" + +/ { + compatible = "raspberrypi,model-zero-w", "brcm,bcm2835"; + model = "Raspberry Pi Zero W"; + + leds { + act { + gpios = <&gpio 47 0>; + }; + }; +}; + +&uart1 { + pinctrl-names = "default"; + pinctrl-0 = <&uart1_gpio14>; + status = "okay"; +}; + +&hdmi { + hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>; +};
arch/arm/mach-bcm283x/Kconfig +16 -0
@@ -44,6 +44,22 @@ config TARGET_RPI This option creates a build targetting the ARM1176 ISA. select BCM2835 +config TARGET_RPI_0_W + bool "Raspberry Pi Zero W" + help + Support for all ARM1176-/BCM2835-based Raspberry Pi variants, such as + the RPi Zero model W. + + This option assumes the VideoCore firmware is configured to use the + mini UART (rather than PL011) for the serial console. This is the + default on the RPi Zero W. To enable the UART console, the following + non-default option must be present in config.txt: enable_uart=1. + This is required for U-Boot to operate correctly, even if you only + care about the HDMI/usbkbd console. + + This option creates a build targetting the ARMv7/AArch32 ISA. + select BCM2835 + config TARGET_RPI_2 bool "Raspberry Pi 2" help
board/raspberrypi/rpi/rpi.c +5 -0
@@ -105,6 +105,11 @@ static const struct rpi_model rpi_models_new_scheme[] = {DTB_DIR "bcm2835-rpi-zero.dtb" , false, }, + [0xC] = { +"Zero W" , +DTB_DIR "bcm2835-rpi-zero-w.dtb" , + false, + }, }; static const struct rpi_model rpi_models_old_scheme[] = {
configs/rpi_0_w_defconfig new file +28 -0
@@ -0,0 +1,28 @@ +CONFIG_ARM=y +CONFIG_ARCH_BCM283X=y +CONFIG_TARGET_RPI_0_W=y +CONFIG_DEFAULT_DEVICE_TREE="bcm2835-rpi-zero-w" +CONFIG_DISTRO_DEFAULTS=y +CONFIG_OF_BOARD_SETUP=y +# CONFIG_DISPLAY_CPUINFO is not set +# CONFIG_DISPLAY_BOARDINFO is not set +CONFIG_SYS_PROMPT="U-Boot> " +# CONFIG_CMD_IMLS is not set +# CONFIG_CMD_FLASH is not set +CONFIG_CMD_MMC=y +CONFIG_CMD_USB=y +# CONFIG_CMD_FPGA is not set +CONFIG_CMD_GPIO=y +CONFIG_DM_MMC=y +CONFIG_MMC_SDHCI=y +CONFIG_MMC_SDHCI_BCM2835=y +CONFIG_DM_ETH=y +CONFIG_USB=y +CONFIG_DM_USB=y +CONFIG_USB_STORAGE=y +CONFIG_USB_KEYBOARD=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
include/configs/rpi.h +1 -1
@@ -76,7 +76,7 @@#endif /* Console UART */ -#ifdef CONFIG_BCM2837 +#if defined (CONFIG_BCM2837 ) || defined(CONFIG_TARGET_RPI_0_W )#define CONFIG_BCM283X_MU_SERIAL #else #define CONFIG_PL01X_SERIAL
Signature · 1 line
2.7.4
PATCH v3 1/1 add support for Raspberry Pi Zero W
Quoted 1 line · Dmitry Korunov
Signed-off-by Dmitry Korunov <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: not available URL: <http://lists.denx.de/pipermail/u-boot/attachments/20171204/fb5306c5/attachment.sig>
PATCH v3 1/1 add support for Raspberry Pi Zero W
Great, thanks!
On Dec 4, 2017 10:36 PM, "Tom Rini" <[email protected]> wrote:
Quoted 1 line · Dmitry Korunov
Signed-off-by Dmitry Korunov <[email protected]>
Applied to u-boot/master, thanks!
--
Tom