1 From 5216bb8a1257a8216362affe4757a96a36b60b32 Mon Sep 17 00:00:00 2001
2 From: Phil Elwell <phil@raspberrypi.org>
3 Date: Tue, 11 Jun 2019 18:08:05 +0100
4 Subject: [PATCH 664/806] arm: dts: First draft of upstream Pi4 DTS
6 I've attempted to follow the upstream conventions in the DT commits,
7 but this is just presented here initially as a talking point.
9 Signed-off-by: Phil Elwell <phil@raspberrypi.org>
11 arch/arm/boot/dts/Makefile | 1 +
12 arch/arm/boot/dts/bcm2838-rpi-4-b.dts | 118 ++++++++++++++++++++++++++
13 arch/arm/boot/dts/bcm2838-rpi.dtsi | 25 ++++++
14 3 files changed, 144 insertions(+)
15 create mode 100644 arch/arm/boot/dts/bcm2838-rpi-4-b.dts
16 create mode 100644 arch/arm/boot/dts/bcm2838-rpi.dtsi
18 --- a/arch/arm/boot/dts/Makefile
19 +++ b/arch/arm/boot/dts/Makefile
20 @@ -94,6 +94,7 @@ dtb-$(CONFIG_ARCH_BCM2835) += \
23 bcm2837-rpi-3-b-plus.dtb \
24 + bcm2838-rpi-4-b.dtb \
25 bcm2835-rpi-zero.dtb \
26 bcm2835-rpi-zero-w.dtb
27 dtb-$(CONFIG_ARCH_BCM_5301X) += \
29 +++ b/arch/arm/boot/dts/bcm2838-rpi-4-b.dts
31 +// SPDX-License-Identifier: GPL-2.0
33 +#include "bcm2838.dtsi"
34 +#include "bcm2835-rpi.dtsi"
35 +#include "bcm2838-rpi.dtsi"
38 + compatible = "raspberrypi,4-model-b", "brcm,bcm2838";
39 + model = "Raspberry Pi 4 Model B";
42 + /* 8250 auxiliary UART instead of pl011 */
43 + stdout-path = "serial1:115200n8";
47 + reg = <0 0 0x40000000>;
52 + gpios = <&gpio 42 GPIO_ACTIVE_HIGH>;
57 + gpios = <&expgpio 2 GPIO_ACTIVE_LOW>;
61 + wifi_pwrseq: wifi-pwrseq {
62 + compatible = "mmc-pwrseq-simple";
63 + reset-gpios = <&expgpio 1 GPIO_ACTIVE_LOW>;
66 + sd_io_1v8_reg: sd_io_1v8_reg {
68 + compatible = "regulator-gpio";
69 + vin-supply = <&vdd_5v0_reg>;
70 + regulator-name = "vdd-sd-io";
71 + regulator-min-microvolt = <1800000>;
72 + regulator-max-microvolt = <3300000>;
74 + regulator-always-on;
75 + regulator-settling-time-us = <5000>;
77 + gpios = <&expgpio 4 GPIO_ACTIVE_HIGH>;
78 + states = <1800000 0x1
85 + compatible = "raspberrypi,firmware-gpio";
88 + gpio-line-names = "BT_ON",
101 + pinctrl-names = "default";
102 + pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio41>;
106 +/* SDHCI is used to control the SDIO for wireless */
108 + #address-cells = <1>;
110 + pinctrl-names = "default";
111 + pinctrl-0 = <&emmc_gpio34>;
115 + mmc-pwrseq = <&wifi_pwrseq>;
119 + compatible = "brcm,bcm4329-fmac";
123 +/* EMMC2 is used to drive the SD card */
127 + vqmmc-supply = <&sd_io_1v8_reg>;
130 +/* uart0 communicates with the BT module */
132 + pinctrl-names = "default";
133 + pinctrl-0 = <&uart0_ctsrts_gpio30 &uart0_gpio32 &gpclk2_gpio43>;
137 + compatible = "brcm,bcm43438-bt";
138 + max-speed = <2000000>;
139 + shutdown-gpios = <&expgpio 0 GPIO_ACTIVE_HIGH>;
143 +/* uart1 is mapped to the pin header */
145 + pinctrl-names = "default";
146 + pinctrl-0 = <&uart1_gpio14>;
150 +++ b/arch/arm/boot/dts/bcm2838-rpi.dtsi
152 +// SPDX-License-Identifier: GPL-2.0
156 + /delete-node/ mailbox@7e00b840;
161 + vchiq: mailbox@7e00b840 {
162 + compatible = "brcm,bcm2838-vchiq";
163 + reg = <0 0x7e00b840 0x3c>;
164 + interrupts = <GIC_SPI 34 IRQ_TYPE_LEVEL_HIGH>;
169 + /* The VPU firmware uses DMA channel 11 for VCHIQ */
170 + brcm,dma-channel-mask = <0x1f5>;
174 + /* The VPU firmware DMA channel 11 for VCHIQ */
175 + brcm,dma-channel-mask = <0x7000>;