b03622d
From patchwork Sat Apr 21 11:28:34 2018
b03622d
Content-Type: text/plain; charset="utf-8"
b03622d
MIME-Version: 1.0
b03622d
Content-Transfer-Encoding: 7bit
b03622d
Subject: [V2,1/9] ARM: dts: bcm283x: Fix PWM pin assignment
b03622d
From: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
X-Patchwork-Id: 10354085
b03622d
Message-Id: <1524310122-9439-2-git-send-email-stefan.wahren@i2se.com>
b03622d
To: Rob Herring <robh+dt@kernel.org>, Mark Rutland <mark.rutland@arm.com>,
b03622d
 Eric Anholt <eric@anholt.net>, Catalin Marinas <catalin.marinas@arm.com>, 
b03622d
 Will Deacon <will.deacon@arm.com>
b03622d
Cc: Stefan Wahren <stefan.wahren@i2se.com>, devicetree@vger.kernel.org,
b03622d
 Florian Fainelli <f.fainelli@gmail.com>, Arnd Bergmann <arnd@arndb.de>,
b03622d
 Scott Branden <sbranden@broadcom.com>, Ray Jui <rjui@broadcom.com>,
b03622d
 Phil Elwell <phil@raspberrypi.org>, Alexander Graf <agraf@suse.de>,
b03622d
 bcm-kernel-feedback-list@broadcom.com,
b03622d
 linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org
b03622d
Date: Sat, 21 Apr 2018 13:28:34 +0200
b03622d
b03622d
All RPi 1 and 2 boards used the PWM (audio out) on pin 40 and 45.
b03622d
So it was easy to define them in bcm2835-rpi.dtsi. Starting with RPi 3
b03622d
this wont work anymore, because it uses pin 40 and 41. Furthermore the
b03622d
Zero variants doesn't have audio out.
b03622d
b03622d
This patch fixes this pin conflict by moving the PWM node to the board-level.
b03622d
b03622d
Change summary:
b03622d
RPi 3 B:      PWM1 45 -> 41
b03622d
Zero, Zero W: PWM disabled
b03622d
all other:    no functional change
b03622d
b03622d
Reported-by: Baruch Siach <baruch@tkos.co.il>
b03622d
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
Reviewed-by: Eric Anholt <eric@anholt.net>
b03622d
---
b03622d
 arch/arm/boot/dts/bcm2835-rpi-a-plus.dts | 6 ++++++
b03622d
 arch/arm/boot/dts/bcm2835-rpi-a.dts      | 6 ++++++
b03622d
 arch/arm/boot/dts/bcm2835-rpi-b-plus.dts | 6 ++++++
b03622d
 arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts | 6 ++++++
b03622d
 arch/arm/boot/dts/bcm2835-rpi-b.dts      | 6 ++++++
b03622d
 arch/arm/boot/dts/bcm2835-rpi.dtsi       | 6 ------
b03622d
 arch/arm/boot/dts/bcm2836-rpi-2-b.dts    | 6 ++++++
b03622d
 arch/arm/boot/dts/bcm2837-rpi-3-b.dts    | 6 ++++++
b03622d
 8 files changed, 42 insertions(+), 6 deletions(-)
b03622d
b03622d
diff --git a/arch/arm/boot/dts/bcm2835-rpi-a-plus.dts b/arch/arm/boot/dts/bcm2835-rpi-a-plus.dts
b03622d
index aa1fc7b..2cd9c5e 100644
b03622d
--- a/arch/arm/boot/dts/bcm2835-rpi-a-plus.dts
b03622d
+++ b/arch/arm/boot/dts/bcm2835-rpi-a-plus.dts
b03622d
@@ -101,6 +101,12 @@
b03622d
 	hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
b03622d
 };
b03622d
 
b03622d
+&pwm {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
b03622d
+	status = "okay";
b03622d
+};
b03622d
+
b03622d
 &uart0 {
b03622d
 	pinctrl-names = "default";
b03622d
 	pinctrl-0 = <&uart0_gpio14>;
b03622d
diff --git a/arch/arm/boot/dts/bcm2835-rpi-a.dts b/arch/arm/boot/dts/bcm2835-rpi-a.dts
b03622d
index 425f6b0..067d1f0 100644
b03622d
--- a/arch/arm/boot/dts/bcm2835-rpi-a.dts
b03622d
+++ b/arch/arm/boot/dts/bcm2835-rpi-a.dts
b03622d
@@ -96,6 +96,12 @@
b03622d
 	hpd-gpios = <&gpio 46 GPIO_ACTIVE_HIGH>;
b03622d
 };
b03622d
 
b03622d
+&pwm {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
b03622d
+	status = "okay";
b03622d
+};
b03622d
+
b03622d
 &uart0 {
b03622d
 	pinctrl-names = "default";
b03622d
 	pinctrl-0 = <&uart0_gpio14>;
b03622d
diff --git a/arch/arm/boot/dts/bcm2835-rpi-b-plus.dts b/arch/arm/boot/dts/bcm2835-rpi-b-plus.dts
b03622d
index effa195..cfbdaac 100644
b03622d
--- a/arch/arm/boot/dts/bcm2835-rpi-b-plus.dts
b03622d
+++ b/arch/arm/boot/dts/bcm2835-rpi-b-plus.dts
b03622d
@@ -103,6 +103,12 @@
b03622d
 	hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
b03622d
 };
b03622d
 
b03622d
+&pwm {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
b03622d
+	status = "okay";
b03622d
+};
b03622d
+
b03622d
 &uart0 {
b03622d
 	pinctrl-names = "default";
b03622d
 	pinctrl-0 = <&uart0_gpio14>;
b03622d
diff --git a/arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts b/arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts
b03622d
index 772ec3b..5641d16 100644
b03622d
--- a/arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts
b03622d
+++ b/arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts
b03622d
@@ -96,6 +96,12 @@
b03622d
 	hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
b03622d
 };
b03622d
 
b03622d
+&pwm {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
b03622d
+	status = "okay";
b03622d
+};
b03622d
+
b03622d
 &uart0 {
b03622d
 	pinctrl-names = "default";
b03622d
 	pinctrl-0 = <&uart0_gpio14>;
b03622d
diff --git a/arch/arm/boot/dts/bcm2835-rpi-b.dts b/arch/arm/boot/dts/bcm2835-rpi-b.dts
b03622d
index 434483d..31ff602 100644
b03622d
--- a/arch/arm/boot/dts/bcm2835-rpi-b.dts
b03622d
+++ b/arch/arm/boot/dts/bcm2835-rpi-b.dts
b03622d
@@ -91,6 +91,12 @@
b03622d
 	hpd-gpios = <&gpio 46 GPIO_ACTIVE_HIGH>;
b03622d
 };
b03622d
 
b03622d
+&pwm {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
b03622d
+	status = "okay";
b03622d
+};
b03622d
+
b03622d
 &uart0 {
b03622d
 	pinctrl-names = "default";
b03622d
 	pinctrl-0 = <&uart0_gpio14>;
b03622d
diff --git a/arch/arm/boot/dts/bcm2835-rpi.dtsi b/arch/arm/boot/dts/bcm2835-rpi.dtsi
b03622d
index 6c3cfaa..cb2d6d7 100644
b03622d
--- a/arch/arm/boot/dts/bcm2835-rpi.dtsi
b03622d
+++ b/arch/arm/boot/dts/bcm2835-rpi.dtsi
b03622d
@@ -83,12 +83,6 @@
b03622d
 	bus-width = <4>;
b03622d
 };
b03622d
 
b03622d
-&pwm {
b03622d
-	pinctrl-names = "default";
b03622d
-	pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
b03622d
-	status = "okay";
b03622d
-};
b03622d
-
b03622d
 &usb {
b03622d
 	power-domains = <&power RPI_POWER_DOMAIN_USB>;
b03622d
 };
b03622d
diff --git a/arch/arm/boot/dts/bcm2836-rpi-2-b.dts b/arch/arm/boot/dts/bcm2836-rpi-2-b.dts
b03622d
index 5c339ad..2fef70a 100644
b03622d
--- a/arch/arm/boot/dts/bcm2836-rpi-2-b.dts
b03622d
+++ b/arch/arm/boot/dts/bcm2836-rpi-2-b.dts
b03622d
@@ -41,6 +41,12 @@
b03622d
 	hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
b03622d
 };
b03622d
 
b03622d
+&pwm {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
b03622d
+	status = "okay";
b03622d
+};
b03622d
+
b03622d
 &uart0 {
b03622d
 	pinctrl-names = "default";
b03622d
 	pinctrl-0 = <&uart0_gpio14>;
b03622d
diff --git a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
b03622d
index 0b31d99..cc39b6f 100644
b03622d
--- a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
b03622d
+++ b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
b03622d
@@ -42,6 +42,12 @@
b03622d
 	};
b03622d
 };
b03622d
 
b03622d
+&pwm {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio41>;
b03622d
+	status = "okay";
b03622d
+};
b03622d
+
b03622d
 /* uart0 communicates with the BT module */
b03622d
 &uart0 {
b03622d
 	pinctrl-names = "default";
b03622d
From patchwork Sat Apr 21 11:28:35 2018
b03622d
Content-Type: text/plain; charset="utf-8"
b03622d
MIME-Version: 1.0
b03622d
Content-Transfer-Encoding: 7bit
b03622d
Subject: [V2,2/9] ARM: dts: bcm2837: Add missing GPIOs of Expander
b03622d
From: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
X-Patchwork-Id: 10354079
b03622d
Message-Id: <1524310122-9439-3-git-send-email-stefan.wahren@i2se.com>
b03622d
To: Rob Herring <robh+dt@kernel.org>, Mark Rutland <mark.rutland@arm.com>,
b03622d
 Eric Anholt <eric@anholt.net>, Catalin Marinas <catalin.marinas@arm.com>, 
b03622d
 Will Deacon <will.deacon@arm.com>
b03622d
Cc: Stefan Wahren <stefan.wahren@i2se.com>, devicetree@vger.kernel.org,
b03622d
 Florian Fainelli <f.fainelli@gmail.com>, Arnd Bergmann <arnd@arndb.de>,
b03622d
 Scott Branden <sbranden@broadcom.com>, Ray Jui <rjui@broadcom.com>,
b03622d
 Phil Elwell <phil@raspberrypi.org>, Alexander Graf <agraf@suse.de>,
b03622d
 bcm-kernel-feedback-list@broadcom.com,
b03622d
 linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org
b03622d
Date: Sat, 21 Apr 2018 13:28:35 +0200
b03622d
b03622d
After commit a98d90e7d588 ("gpio: raspberrypi-exp: Driver for RPi3 GPIO
b03622d
expander via mailbox service") we are able to control the rest of the
b03622d
GPIOs of the RPi 3. So add all the missing parts (ACT LED,
b03622d
Wifi & BT control, HDMI detect) to the DT.
b03622d
b03622d
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
Reviewed-by: Eric Anholt <eric@anholt.net>
b03622d
---
b03622d
 arch/arm/boot/dts/bcm2837-rpi-3-b.dts | 20 +++++++++++++++++++-
b03622d
 1 file changed, 19 insertions(+), 1 deletion(-)
b03622d
b03622d
diff --git a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
b03622d
index cc39b6f..c318bcb 100644
b03622d
--- a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
b03622d
+++ b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
b03622d
@@ -20,9 +20,14 @@
b03622d
 
b03622d
 	leds {
b03622d
 		act {
b03622d
-			gpios = <&gpio 47 GPIO_ACTIVE_HIGH>;
b03622d
+			gpios = <&expgpio 2 GPIO_ACTIVE_HIGH>;
b03622d
 		};
b03622d
 	};
b03622d
+
b03622d
+	wifi_pwrseq: wifi-pwrseq {
b03622d
+		compatible = "mmc-pwrseq-simple";
b03622d
+		reset-gpios = <&expgpio 1 GPIO_ACTIVE_HIGH>;
b03622d
+	};
b03622d
 };
b03622d
 
b03622d
 &firmware {
b03622d
@@ -48,6 +53,10 @@
b03622d
 	status = "okay";
b03622d
 };
b03622d
 
b03622d
+&hdmi {
b03622d
+	hpd-gpios = <&expgpio 4 GPIO_ACTIVE_LOW>;
b03622d
+};
b03622d
+
b03622d
 /* uart0 communicates with the BT module */
b03622d
 &uart0 {
b03622d
 	pinctrl-names = "default";
b03622d
@@ -57,6 +66,7 @@
b03622d
 	bluetooth {
b03622d
 		compatible = "brcm,bcm43438-bt";
b03622d
 		max-speed = <2000000>;
b03622d
+		shutdown-gpios = <&expgpio 0 GPIO_ACTIVE_HIGH>;
b03622d
 	};
b03622d
 };
b03622d
 
b03622d
@@ -69,11 +79,19 @@
b03622d
 
b03622d
 /* SDHCI is used to control the SDIO for wireless */
b03622d
 &sdhci {
b03622d
+	#address-cells = <1>;
b03622d
+	#size-cells = <0>;
b03622d
 	pinctrl-names = "default";
b03622d
 	pinctrl-0 = <&emmc_gpio34>;
b03622d
 	status = "okay";
b03622d
 	bus-width = <4>;
b03622d
 	non-removable;
b03622d
+	mmc-pwrseq = <&wifi_pwrseq>;
b03622d
+
b03622d
+	brcmf: wifi@1 {
b03622d
+		reg = <1>;
b03622d
+		compatible = "brcm,bcm4329-fmac";
b03622d
+	};
b03622d
 };
b03622d
 
b03622d
 /* SDHOST is used to drive the SD card */
b03622d
From patchwork Sat Apr 21 11:28:36 2018
b03622d
Content-Type: text/plain; charset="utf-8"
b03622d
MIME-Version: 1.0
b03622d
Content-Transfer-Encoding: 7bit
b03622d
Subject: [V2,3/9] dt-bindings: bcm: Add Raspberry Pi 3 B+
b03622d
From: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
X-Patchwork-Id: 10354081
b03622d
Message-Id: <1524310122-9439-4-git-send-email-stefan.wahren@i2se.com>
b03622d
To: Rob Herring <robh+dt@kernel.org>, Mark Rutland <mark.rutland@arm.com>,
b03622d
 Eric Anholt <eric@anholt.net>, Catalin Marinas <catalin.marinas@arm.com>, 
b03622d
 Will Deacon <will.deacon@arm.com>
b03622d
Cc: Stefan Wahren <stefan.wahren@i2se.com>, devicetree@vger.kernel.org,
b03622d
 Florian Fainelli <f.fainelli@gmail.com>, Arnd Bergmann <arnd@arndb.de>,
b03622d
 Scott Branden <sbranden@broadcom.com>, Ray Jui <rjui@broadcom.com>,
b03622d
 Phil Elwell <phil@raspberrypi.org>, Alexander Graf <agraf@suse.de>,
b03622d
 bcm-kernel-feedback-list@broadcom.com,
b03622d
 linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org
b03622d
Date: Sat, 21 Apr 2018 13:28:36 +0200
b03622d
b03622d
This adds the root properties for the Raspberry Pi 3 B+
b03622d
b03622d
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
Reviewed-by: Eric Anholt <eric@anholt.net>
b03622d
Reviewed-by: Rob Herring <robh@kernel.org>
b03622d
---
b03622d
 Documentation/devicetree/bindings/arm/bcm/brcm,bcm2835.txt | 4 ++++
b03622d
 1 file changed, 4 insertions(+)
b03622d
b03622d
diff --git a/Documentation/devicetree/bindings/arm/bcm/brcm,bcm2835.txt b/Documentation/devicetree/bindings/arm/bcm/brcm,bcm2835.txt
b03622d
index 3e3efa0..1e3e29a 100644
b03622d
--- a/Documentation/devicetree/bindings/arm/bcm/brcm,bcm2835.txt
b03622d
+++ b/Documentation/devicetree/bindings/arm/bcm/brcm,bcm2835.txt
b03622d
@@ -34,6 +34,10 @@ Raspberry Pi 3 Model B
b03622d
 Required root node properties:
b03622d
 compatible = "raspberrypi,3-model-b", "brcm,bcm2837";
b03622d
 
b03622d
+Raspberry Pi 3 Model B+
b03622d
+Required root node properties:
b03622d
+compatible = "raspberrypi,3-model-b-plus", "brcm,bcm2837";
b03622d
+
b03622d
 Raspberry Pi Compute Module
b03622d
 Required root node properties:
b03622d
 compatible = "raspberrypi,compute-module", "brcm,bcm2835";
b03622d
From patchwork Sat Apr 21 11:28:37 2018
b03622d
Content-Type: text/plain; charset="utf-8"
b03622d
MIME-Version: 1.0
b03622d
Content-Transfer-Encoding: 7bit
b03622d
Subject: [V2,4/9] ARM: dts: bcm2837: Add Raspberry Pi 3 B+
b03622d
From: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
X-Patchwork-Id: 10354075
b03622d
Message-Id: <1524310122-9439-5-git-send-email-stefan.wahren@i2se.com>
b03622d
To: Rob Herring <robh+dt@kernel.org>, Mark Rutland <mark.rutland@arm.com>,
b03622d
 Eric Anholt <eric@anholt.net>, Catalin Marinas <catalin.marinas@arm.com>, 
b03622d
 Will Deacon <will.deacon@arm.com>
b03622d
Cc: Stefan Wahren <stefan.wahren@i2se.com>, devicetree@vger.kernel.org,
b03622d
 Florian Fainelli <f.fainelli@gmail.com>, Arnd Bergmann <arnd@arndb.de>,
b03622d
 Scott Branden <sbranden@broadcom.com>, Ray Jui <rjui@broadcom.com>,
b03622d
 Phil Elwell <phil@raspberrypi.org>, Alexander Graf <agraf@suse.de>,
b03622d
 bcm-kernel-feedback-list@broadcom.com,
b03622d
 linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org
b03622d
Date: Sat, 21 Apr 2018 13:28:37 +0200
b03622d
b03622d
The Raspberry Pi 3 B+ has the following major differences compared
b03622d
to the model 3 B:
b03622d
* Microchip LAN7515 (Gigabit Ethernet with integrated USB 2.0 HUB)
b03622d
* Cypress CYW43455 (802.11n/ac and BT 4.2)
b03622d
b03622d
We need to add the USB LAN chip so the bootloader can add the MAC address.
b03622d
This is necessary because there ain't an EEPROM or a valid OTP.
b03622d
b03622d
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
b03622d
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
Reviewed-by: Eric Anholt <eric@anholt.net>
b03622d
---
b03622d
 arch/arm/boot/dts/Makefile                 |   1 +
b03622d
 arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts | 108 +++++++++++++++++++++++++++++
b03622d
 arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi |  27 ++++++++
b03622d
 3 files changed, 136 insertions(+)
b03622d
 create mode 100644 arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts
b03622d
 create mode 100644 arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi
b03622d
b03622d
diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
b03622d
index 7e24249..a300a35 100644
b03622d
--- a/arch/arm/boot/dts/Makefile
b03622d
+++ b/arch/arm/boot/dts/Makefile
b03622d
@@ -75,6 +75,7 @@ dtb-$(CONFIG_ARCH_BCM2835) += \
b03622d
 	bcm2835-rpi-a-plus.dtb \
b03622d
 	bcm2836-rpi-2-b.dtb \
b03622d
 	bcm2837-rpi-3-b.dtb \
b03622d
+	bcm2837-rpi-3-b-plus.dtb \
b03622d
 	bcm2835-rpi-zero.dtb \
b03622d
 	bcm2835-rpi-zero-w.dtb
b03622d
 dtb-$(CONFIG_ARCH_BCM_5301X) += \
b03622d
diff --git a/arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts b/arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts
b03622d
new file mode 100644
b03622d
index 0000000..4adb85e
b03622d
--- /dev/null
b03622d
+++ b/arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts
b03622d
@@ -0,0 +1,108 @@
b03622d
+// SPDX-License-Identifier: GPL-2.0
b03622d
+/dts-v1/;
b03622d
+#include "bcm2837.dtsi"
b03622d
+#include "bcm2835-rpi.dtsi"
b03622d
+#include "bcm283x-rpi-lan7515.dtsi"
b03622d
+#include "bcm283x-rpi-usb-host.dtsi"
b03622d
+
b03622d
+/ {
b03622d
+	compatible = "raspberrypi,3-model-b-plus", "brcm,bcm2837";
b03622d
+	model = "Raspberry Pi 3 Model B+";
b03622d
+
b03622d
+	chosen {
b03622d
+		/* 8250 auxiliary UART instead of pl011 */
b03622d
+		stdout-path = "serial1:115200n8";
b03622d
+	};
b03622d
+
b03622d
+	memory {
b03622d
+		reg = <0 0x40000000>;
b03622d
+	};
b03622d
+
b03622d
+	leds {
b03622d
+		act {
b03622d
+			gpios = <&gpio 29 GPIO_ACTIVE_HIGH>;
b03622d
+		};
b03622d
+
b03622d
+		pwr {
b03622d
+			label = "PWR";
b03622d
+			gpios = <&expgpio 2 GPIO_ACTIVE_LOW>;
b03622d
+		};
b03622d
+	};
b03622d
+
b03622d
+	wifi_pwrseq: wifi-pwrseq {
b03622d
+		compatible = "mmc-pwrseq-simple";
b03622d
+		reset-gpios = <&expgpio 1 GPIO_ACTIVE_HIGH>;
b03622d
+	};
b03622d
+};
b03622d
+
b03622d
+&firmware {
b03622d
+	expgpio: gpio {
b03622d
+		compatible = "raspberrypi,firmware-gpio";
b03622d
+		gpio-controller;
b03622d
+		#gpio-cells = <2>;
b03622d
+		gpio-line-names = "BT_ON",
b03622d
+				  "WL_ON",
b03622d
+				  "STATUS_LED",
b03622d
+				  "LAN_RUN",
b03622d
+				  "",
b03622d
+				  "CAM_GPIO0",
b03622d
+				  "CAM_GPIO1",
b03622d
+				  "";
b03622d
+		status = "okay";
b03622d
+	};
b03622d
+};
b03622d
+
b03622d
+&hdmi {
b03622d
+	hpd-gpios = <&gpio 28 GPIO_ACTIVE_LOW>;
b03622d
+};
b03622d
+
b03622d
+&pwm {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio41>;
b03622d
+	status = "okay";
b03622d
+};
b03622d
+
b03622d
+/* SDHCI is used to control the SDIO for wireless */
b03622d
+&sdhci {
b03622d
+	#address-cells = <1>;
b03622d
+	#size-cells = <0>;
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&emmc_gpio34>;
b03622d
+	status = "okay";
b03622d
+	bus-width = <4>;
b03622d
+	non-removable;
b03622d
+	mmc-pwrseq = <&wifi_pwrseq>;
b03622d
+
b03622d
+	brcmf: wifi@1 {
b03622d
+		reg = <1>;
b03622d
+		compatible = "brcm,bcm4329-fmac";
b03622d
+	};
b03622d
+};
b03622d
+
b03622d
+/* SDHOST is used to drive the SD card */
b03622d
+&sdhost {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&sdhost_gpio48>;
b03622d
+	status = "okay";
b03622d
+	bus-width = <4>;
b03622d
+};
b03622d
+
b03622d
+/* uart0 communicates with the BT module */
b03622d
+&uart0 {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&uart0_ctsrts_gpio30 &uart0_gpio32 &gpclk2_gpio43>;
b03622d
+	status = "okay";
b03622d
+
b03622d
+	bluetooth {
b03622d
+		compatible = "brcm,bcm43438-bt";
b03622d
+		max-speed = <2000000>;
b03622d
+		shutdown-gpios = <&expgpio 0 GPIO_ACTIVE_HIGH>;
b03622d
+	};
b03622d
+};
b03622d
+
b03622d
+/* uart1 is mapped to the pin header */
b03622d
+&uart1 {
b03622d
+	pinctrl-names = "default";
b03622d
+	pinctrl-0 = <&uart1_gpio14>;
b03622d
+	status = "okay";
b03622d
+};
b03622d
diff --git a/arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi b/arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi
b03622d
new file mode 100644
b03622d
index 0000000..9403da0
b03622d
--- /dev/null
b03622d
+++ b/arch/arm/boot/dts/bcm283x-rpi-lan7515.dtsi
b03622d
@@ -0,0 +1,27 @@
b03622d
+// SPDX-License-Identifier: GPL-2.0
b03622d
+/ {
b03622d
+	aliases {
b03622d
+		ethernet0 = &ethernet;
b03622d
+	};
b03622d
+};
b03622d
+
b03622d
+&usb {
b03622d
+	usb-port@1 {
b03622d
+		compatible = "usb424,2514";
b03622d
+		reg = <1>;
b03622d
+		#address-cells = <1>;
b03622d
+		#size-cells = <0>;
b03622d
+
b03622d
+		usb-port@1 {
b03622d
+			compatible = "usb424,2514";
b03622d
+			reg = <1>;
b03622d
+			#address-cells = <1>;
b03622d
+			#size-cells = <0>;
b03622d
+
b03622d
+			ethernet: ethernet@1 {
b03622d
+				compatible = "usb424,7800";
b03622d
+				reg = <1>;
b03622d
+			};
b03622d
+		};
b03622d
+	};
b03622d
+};
b03622d
From patchwork Sat Apr 21 11:28:42 2018
b03622d
Content-Type: text/plain; charset="utf-8"
b03622d
MIME-Version: 1.0
b03622d
Content-Transfer-Encoding: 7bit
b03622d
Subject: [V2,9/9] arm64: dts: broadcom: Add reference to Raspberry Pi 3 B+
b03622d
From: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
X-Patchwork-Id: 10354077
b03622d
Message-Id: <1524310122-9439-10-git-send-email-stefan.wahren@i2se.com>
b03622d
To: Rob Herring <robh+dt@kernel.org>, Mark Rutland <mark.rutland@arm.com>,
b03622d
 Eric Anholt <eric@anholt.net>, Catalin Marinas <catalin.marinas@arm.com>, 
b03622d
 Will Deacon <will.deacon@arm.com>
b03622d
Cc: Stefan Wahren <stefan.wahren@i2se.com>, devicetree@vger.kernel.org,
b03622d
 Florian Fainelli <f.fainelli@gmail.com>, Arnd Bergmann <arnd@arndb.de>,
b03622d
 Scott Branden <sbranden@broadcom.com>, Ray Jui <rjui@broadcom.com>,
b03622d
 Phil Elwell <phil@raspberrypi.org>, Alexander Graf <agraf@suse.de>,
b03622d
 bcm-kernel-feedback-list@broadcom.com,
b03622d
 linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org
b03622d
Date: Sat, 21 Apr 2018 13:28:42 +0200
b03622d
b03622d
This adds a reference to the dts of the Raspberry Pi 3 B+
b03622d
in arm, so don't need to maintain the content in arm64.
b03622d
b03622d
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
b03622d
Reviewed-by: Eric Anholt <eric@anholt.net>
b03622d
---
b03622d
 arch/arm64/boot/dts/broadcom/Makefile                 | 3 ++-
b03622d
 arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b-plus.dts | 2 ++
b03622d
 2 files changed, 4 insertions(+), 1 deletion(-)
b03622d
 create mode 100644 arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b-plus.dts
b03622d
b03622d
diff --git a/arch/arm64/boot/dts/broadcom/Makefile b/arch/arm64/boot/dts/broadcom/Makefile
b03622d
index 2a2591e..1193a9e 100644
b03622d
--- a/arch/arm64/boot/dts/broadcom/Makefile
b03622d
+++ b/arch/arm64/boot/dts/broadcom/Makefile
b03622d
@@ -1,5 +1,6 @@
b03622d
 # SPDX-License-Identifier: GPL-2.0
b03622d
-dtb-$(CONFIG_ARCH_BCM2835) += bcm2837-rpi-3-b.dtb
b03622d
+dtb-$(CONFIG_ARCH_BCM2835) += bcm2837-rpi-3-b.dtb \
b03622d
+			      bcm2837-rpi-3-b-plus.dtb
b03622d
 
b03622d
 subdir-y	+= northstar2
b03622d
 subdir-y	+= stingray
b03622d
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
b03622d
new file mode 100644
b03622d
index 0000000..46ad202
b03622d
--- /dev/null
b03622d
+++ b/arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b-plus.dts
b03622d
@@ -0,0 +1,2 @@
b03622d
+// SPDX-License-Identifier: GPL-2.0
b03622d
+#include "arm/bcm2837-rpi-3-b-plus.dts"