diff --git a/root/target/linux/bcm27xx/patches-5.4/950-0785-ARM-dts-Add-bcm2711-rpi-cm4.dts.patch b/root/target/linux/bcm27xx/patches-5.4/950-0785-ARM-dts-Add-bcm2711-rpi-cm4.dts.patch index 57053c9c..81aaea09 100755 --- a/root/target/linux/bcm27xx/patches-5.4/950-0785-ARM-dts-Add-bcm2711-rpi-cm4.dts.patch +++ b/root/target/linux/bcm27xx/patches-5.4/950-0785-ARM-dts-Add-bcm2711-rpi-cm4.dts.patch @@ -8,9 +8,9 @@ Add initial DTS file for Compute Module 4. Signed-off-by: Phil Elwell --- arch/arm/boot/dts/Makefile | 3 +- - arch/arm/boot/dts/bcm2711-rpi-cm4.dts | 486 ++++++++++++++++++++++++++ + arch/arm/boot/dts/bcm2711-rpi-cm4.dts | 586 ++++++++++++++++++++++++++ arch/arm/boot/dts/overlays/README | 6 + - 3 files changed, 492 insertions(+), 1 deletion(-) + 3 files changed, 594 insertions(+), 1 deletion(-) create mode 100644 arch/arm/boot/dts/bcm2711-rpi-cm4.dts --- a/arch/arm/boot/dts/Makefile @@ -27,7 +27,7 @@ Signed-off-by: Phil Elwell alpine-db.dtb --- /dev/null +++ b/arch/arm/boot/dts/bcm2711-rpi-cm4.dts -@@ -0,0 +1,486 @@ +@@ -0,0 +1,536 @@ +// SPDX-License-Identifier: GPL-2.0 +/dts-v1/; +#include "bcm2711.dtsi" @@ -49,9 +49,7 @@ Signed-off-by: Phil Elwell + }; + + aliases { -+ emmc2bus = &emmc2bus; + ethernet0 = &genet; -+ pcie0 = &pcie0; + }; + + leds { @@ -62,8 +60,6 @@ Signed-off-by: Phil Elwell + pwr { + label = "PWR"; + gpios = <&expgpio 2 GPIO_ACTIVE_LOW>; -+ default-state = "keep"; -+ linux,default-trigger = "default-on"; + }; + }; + @@ -177,11 +173,50 @@ Signed-off-by: Phil Elwell + interrupts = ; +}; + ++&vc4 { ++ status = "okay"; ++}; ++ ++&pixelvalve0 { ++ status = "okay"; ++}; ++ ++&pixelvalve1 { ++ status = "okay"; ++}; ++ ++&pixelvalve2 { ++ status = "okay"; ++}; ++ ++&pixelvalve3 { ++ status = "okay"; ++}; ++ ++&pixelvalve4 { ++ status = "okay"; ++}; ++ ++&hdmi0 { ++ status = "okay"; ++}; ++ ++&ddc0 { ++ status = "okay"; ++}; ++ ++&hdmi1 { ++ status = "okay"; ++}; ++ ++&ddc1 { ++ status = "okay"; ++}; ++ +// ============================================= +// Downstream rpi- changes + +#include "bcm270x.dtsi" -+#include "bcm271x-rpi-bt.dtsi" + +/ { + soc { @@ -191,13 +226,14 @@ Signed-off-by: Phil Elwell +}; + +#include "bcm2711-rpi.dtsi" -+#include "bcm283x-rpi-csi0-2lane.dtsi" -+#include "bcm283x-rpi-csi1-4lane.dtsi" ++#include "bcm283x-rpi-csi1-2lane.dtsi" +#include "bcm283x-rpi-i2c0mux_0_44.dtsi" + ++/delete-node/ &emmc2; ++ +/ { + chosen { -+ bootargs = "coherent_pool=1M 8250.nr_uarts=1 snd_bcm2835.enable_compat_alsa=0 snd_bcm2835.enable_hdmi=1"; ++ bootargs = "coherent_pool=1M 8250.nr_uarts=1 snd_bcm2835.enable_compat_alsa=0 snd_bcm2835.enable_hdmi=1 snd_bcm2835.enable_headphones=1"; + }; + + aliases { @@ -211,16 +247,34 @@ Signed-off-by: Phil Elwell + i2c4 = &i2c4; + i2c5 = &i2c5; + i2c6 = &i2c6; ++ /delete-property/ ethernet; + /delete-property/ intc; ++ pcie0 = &pcie0; ++ emmc2bus = &emmc2bus; ++ }; ++ ++ emmc2bus: emmc2bus { ++ compatible = "simple-bus"; ++ #address-cells = <2>; ++ #size-cells = <1>; ++ ++ ranges = <0x0 0x7e000000 0x0 0xfe000000 0x01800000>; ++ dma-ranges = <0x0 0xc0000000 0x0 0x00000000 0x40000000>; ++ ++ emmc2: emmc2@7e340000 { ++ compatible = "brcm,bcm2711-emmc2"; ++ status = "okay"; ++ interrupts = ; ++ clocks = <&clocks BCM2711_CLOCK_EMMC2>; ++ reg = <0x0 0x7e340000 0x100>; ++ vqmmc-supply = <&sd_io_1v8_reg>; ++ broken-cd; ++ }; + }; + + /delete-node/ wifi-pwrseq; +}; + -+&pcie0 { -+ brcm,enable-l1ss; -+}; -+ +&mmcnr { + pinctrl-names = "default"; + pinctrl-0 = <&sdio_pins>; @@ -231,6 +285,8 @@ Signed-off-by: Phil Elwell +&uart0 { + pinctrl-0 = <&uart0_pins &bt_pins>; + status = "okay"; ++ ++ /delete-node/ bluetooth; +}; + +&uart1 { @@ -244,12 +300,12 @@ Signed-off-by: Phil Elwell + }; + + spi3_pins: spi3_pins { -+ brcm,pins = <1 2>; ++ #brcm,pins = <1 2 3>; + brcm,function = ; + }; + + spi4_pins: spi4_pins { -+ brcm,pins = <5 7>; ++ #brcm,pins = <5 6 7>; + brcm,function = ; + }; + @@ -265,7 +321,7 @@ Signed-off-by: Phil Elwell + }; + + i2c4_pins: i2c4 { -+ brcm,pins = <8>; ++ #brcm,pins = <8 9>; + brcm,function = ; + brcm,pull = ; + }; @@ -308,7 +364,7 @@ Signed-off-by: Phil Elwell + }; + + uart4_pins: uart4_pins { -+ brcm,pins = <8>; ++ #brcm,pins = <8 9>; + brcm,function = ; + brcm,pull = <0 2>; + }; @@ -318,10 +374,6 @@ Signed-off-by: Phil Elwell + clock-frequency = <100000>; +}; + -+&firmwarekms { -+ compatible = "raspberrypi,rpi-firmware-kms-2711"; -+}; -+ +// ============================================= +// Board specific stuff here + @@ -333,10 +385,10 @@ Signed-off-by: Phil Elwell + regulator-max-microvolt = <3300000>; + regulator-boot-on; + enable-active-high; ++ #gpio = <&expgpio 6 GPIO_ACTIVE_HIGH>; + }; +}; + -+ +&sdhost { + status = "disabled"; +}; @@ -352,8 +404,8 @@ Signed-off-by: Phil Elwell + +&gpio { + audio_pins: audio_pins { -+ brcm,pins = <>; -+ brcm,function = <>; ++ brcm,pins = <40 41>; ++ brcm,function = <4>; + }; +}; + @@ -453,7 +505,6 @@ Signed-off-by: Phil Elwell +&audio { + pinctrl-names = "default"; + pinctrl-0 = <&audio_pins>; -+ brcm,disable-headphones = <1>; +}; + +&vc4 { @@ -509,7 +560,6 @@ Signed-off-by: Phil Elwell + eth_led0 = <&phy1>,"led-modes:0"; + eth_led1 = <&phy1>,"led-modes:4"; + -+ sd_poll_once = <&emmc2>, "non-removable?"; + spi_dma4 = <&spi0>, "dmas:0=", <&dma40>, + <&spi0>, "dmas:8=", <&dma40>; + };