494688
From defa4876ece55751c691d17ffc928d9bfe049585 Mon Sep 17 00:00:00 2001
494688
From: Stefan Wahren <stefan.wahren@i2se.com>
494688
Date: Fri, 16 Mar 2018 22:56:59 +0100
494688
Subject: [PATCH] arm64: dts: broadcom: Add reference to Raspberry Pi 3 B+
a5169d
494688
This adds a reference to the dts file of the Raspberry Pi 3 B+
494688
494688
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
494688
---
494688
 arch/arm64/boot/dts/broadcom/Makefile                 | 3 ++-
494688
 arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b-plus.dts | 2 ++
494688
 2 files changed, 4 insertions(+), 1 deletion(-)
494688
 create mode 100644 arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b-plus.dts
494688
494688
diff --git a/arch/arm64/boot/dts/broadcom/Makefile b/arch/arm64/boot/dts/broadcom/Makefile
494688
index 2a2591ef1fee..1193a9e34bbb 100644
494688
--- a/arch/arm64/boot/dts/broadcom/Makefile
494688
+++ b/arch/arm64/boot/dts/broadcom/Makefile
494688
@@ -1,5 +1,6 @@
494688
 # SPDX-License-Identifier: GPL-2.0
494688
-dtb-$(CONFIG_ARCH_BCM2835) += bcm2837-rpi-3-b.dtb
494688
+dtb-$(CONFIG_ARCH_BCM2835) += bcm2837-rpi-3-b.dtb \
494688
+			      bcm2837-rpi-3-b-plus.dtb
494688
 
494688
 subdir-y	+= northstar2
494688
 subdir-y	+= stingray
494688
diff --git a/arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b-plus.dts b/arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b-plus.dts
494688
new file mode 100644
494688
index 000000000000..46ad2023cccf
494688
--- /dev/null
494688
+++ b/arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b-plus.dts
494688
@@ -0,0 +1,2 @@
494688
+// SPDX-License-Identifier: GPL-2.0
494688
+#include "arm/bcm2837-rpi-3-b-plus.dts"
494688
494688
From c7c06c54087dfadd065abcba0b7f614f7a88d549 Mon Sep 17 00:00:00 2001
494688
From: Phil Elwell <phil@raspberrypi.org>
494688
Date: Fri, 16 Mar 2018 22:42:28 +0100
494688
Subject: [PATCH] ARM: dts: bcm2837: Add Raspberry Pi 3 B+
494688
494688
The Raspberry Pi 3 B+ has the following major differences compared
494688
to the model 3 B:
494688
* Microchip LAN7515 (Gigabit Ethernet)
494688
* Cypress CYW43455 (802.11ac and BT 4.2)
494688
494688
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
494688
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
a5169d
---
494688
 arch/arm/boot/dts/Makefile                 |   1 +
494688
 arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts | 102 +++++++++++++++++++++++++++++
494688
 arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi |  27 ++++++++
494688
 3 files changed, 130 insertions(+)
a5169d
 create mode 100644 arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts
a5169d
 create mode 100644 arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi
a5169d
a5169d
diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
494688
index 3b471e6787ff..dee85f848de9 100644
a5169d
--- a/arch/arm/boot/dts/Makefile
a5169d
+++ b/arch/arm/boot/dts/Makefile
a5169d
@@ -75,6 +75,7 @@ dtb-$(CONFIG_ARCH_BCM2835) += \
a5169d
 	bcm2835-rpi-a-plus.dtb \
a5169d
 	bcm2836-rpi-2-b.dtb \
a5169d
 	bcm2837-rpi-3-b.dtb \
a5169d
+	bcm2837-rpi-3-b-plus.dtb \
a5169d
 	bcm2835-rpi-zero.dtb \
a5169d
 	bcm2835-rpi-zero-w.dtb
a5169d
 dtb-$(CONFIG_ARCH_BCM_5301X) += \
a5169d
diff --git a/arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts b/arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts
a5169d
new file mode 100644
494688
index 000000000000..fb9f6f7e965c
a5169d
--- /dev/null
a5169d
+++ b/arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts
494688
@@ -0,0 +1,102 @@
a5169d
+// SPDX-License-Identifier: GPL-2.0
a5169d
+/dts-v1/;
a5169d
+#include "bcm2837.dtsi"
a5169d
+#include "bcm2835-rpi.dtsi"
a5169d
+#include "bcm283x-rpi-lan7515.dtsi"
a5169d
+#include "bcm283x-rpi-usb-host.dtsi"
a5169d
+
a5169d
+/ {
a5169d
+	compatible = "raspberrypi,3-model-b-plus", "brcm,bcm2837";
a5169d
+	model = "Raspberry Pi 3 Model B+";
a5169d
+
a5169d
+	chosen {
a5169d
+		/* 8250 auxiliary UART instead of pl011 */
a5169d
+		stdout-path = "serial1:115200n8";
a5169d
+	};
a5169d
+
a5169d
+	memory {
a5169d
+		reg = <0 0x40000000>;
a5169d
+	};
a5169d
+
a5169d
+	leds {
a5169d
+		act {
494688
+			gpios = <&gpio 29 0>;
494688
+		};
494688
+
494688
+		pwr {
494688
+			label = "PWR";
494688
+			gpios = <&expgpio 2 GPIO_ACTIVE_LOW>;
a5169d
+		};
a5169d
+	};
494688
+
494688
+	wifi_pwrseq: wifi-pwrseq {
494688
+		compatible = "mmc-pwrseq-simple";
494688
+		reset-gpios = <&expgpio 1 GPIO_ACTIVE_HIGH>;
494688
+	};
494688
+};
494688
+
494688
+&firmware {
494688
+	expgpio: gpio {
494688
+		compatible = "raspberrypi,firmware-gpio";
494688
+		gpio-controller;
494688
+		#gpio-cells = <2>;
494688
+		gpio-line-names = "BT_ON",
494688
+				  "WL_ON",
494688
+				  "STATUS_LED",
494688
+				  "LAN_RUN",
494688
+				  "",
494688
+				  "CAM_GPIO0",
494688
+				  "CAM_GPIO1",
494688
+				  "";
494688
+		status = "okay";
494688
+	};
494688
+};
494688
+
494688
+&hdmi {
494688
+	hpd-gpios = <&gpio 28 GPIO_ACTIVE_LOW>;
a5169d
+};
a5169d
+
a5169d
+/* uart0 communicates with the BT module */
a5169d
+&uart0 {
a5169d
+	pinctrl-names = "default";
a5169d
+	pinctrl-0 = <&uart0_gpio32 &gpclk2_gpio43>;
a5169d
+	status = "okay";
a5169d
+
a5169d
+	bluetooth {
a5169d
+		compatible = "brcm,bcm43438-bt";
a5169d
+		max-speed = <2000000>;
494688
+		shutdown-gpios = <&expgpio 0 GPIO_ACTIVE_HIGH>;
a5169d
+	};
a5169d
+};
a5169d
+
a5169d
+/* uart1 is mapped to the pin header */
a5169d
+&uart1 {
a5169d
+	pinctrl-names = "default";
a5169d
+	pinctrl-0 = <&uart1_gpio14>;
a5169d
+	status = "okay";
a5169d
+};
a5169d
+
a5169d
+/* SDHCI is used to control the SDIO for wireless */
a5169d
+&sdhci {
494688
+	#address-cells = <1>;
494688
+	#size-cells = <0>;
a5169d
+	pinctrl-names = "default";
a5169d
+	pinctrl-0 = <&emmc_gpio34>;
a5169d
+	status = "okay";
a5169d
+	bus-width = <4>;
a5169d
+	non-removable;
494688
+	mmc-pwrseq = <&wifi_pwrseq>;
494688
+
494688
+	brcmf: wifi@1 {
494688
+		reg = <1>;
494688
+		compatible = "brcm,bcm4329-fmac";
494688
+	};
a5169d
+};
a5169d
+
a5169d
+/* SDHOST is used to drive the SD card */
a5169d
+&sdhost {
a5169d
+	pinctrl-names = "default";
a5169d
+	pinctrl-0 = <&sdhost_gpio48>;
a5169d
+	status = "okay";
a5169d
+	bus-width = <4>;
a5169d
+};
a5169d
diff --git a/arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi b/arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi
a5169d
new file mode 100644
494688
index 000000000000..169203c5ce8b
a5169d
--- /dev/null
a5169d
+++ b/arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi
494688
@@ -0,0 +1,27 @@
494688
+// SPDX-License-Identifier: GPL-2.0
a5169d
+/ {
a5169d
+	aliases {
a5169d
+		ethernet0 = &ethernet;
a5169d
+	};
a5169d
+};
a5169d
+
a5169d
+&usb {
a5169d
+	usb1@1 {
a5169d
+		compatible = "usb424,2514";
a5169d
+		reg = <1>;
a5169d
+		#address-cells = <1>;
a5169d
+		#size-cells = <0>;
a5169d
+
a5169d
+		usb1_1@1 {
a5169d
+			compatible = "usb424,2514";
a5169d
+			reg = <1>;
a5169d
+			#address-cells = <1>;
a5169d
+			#size-cells = <0>;
a5169d
+
a5169d
+			ethernet: usbether@1 {
a5169d
+				compatible = "usb424,7800";
a5169d
+				reg = <1>;
a5169d
+			};
a5169d
+		};
a5169d
+	};
a5169d
+};
a5169d