]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
ARM: dts: bcm283x: Fix PWM pin assignment
authorStefan Wahren <stefan.wahren@i2se.com>
Sat, 21 Apr 2018 11:28:34 +0000 (13:28 +0200)
committerEric Anholt <eric@anholt.net>
Mon, 23 Apr 2018 20:00:36 +0000 (13:00 -0700)
All RPi 1 and 2 boards used the PWM (audio out) on pin 40 and 45.
So it was easy to define them in bcm2835-rpi.dtsi. Starting with RPi 3
this wont work anymore, because it uses pin 40 and 41. Furthermore the
Zero variants doesn't have audio out.

This patch fixes this pin conflict by moving the PWM node to the board-level.

Change summary:
RPi 3 B:      PWM1 45 -> 41
Zero, Zero W: PWM disabled
all other:    no functional change

Reported-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Eric Anholt <eric@anholt.net>
arch/arm/boot/dts/bcm2835-rpi-a-plus.dts
arch/arm/boot/dts/bcm2835-rpi-a.dts
arch/arm/boot/dts/bcm2835-rpi-b-plus.dts
arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts
arch/arm/boot/dts/bcm2835-rpi-b.dts
arch/arm/boot/dts/bcm2835-rpi.dtsi
arch/arm/boot/dts/bcm2836-rpi-2-b.dts
arch/arm/boot/dts/bcm2837-rpi-3-b.dts

index aa1fc7babfea7b200333a713fd35bfb6a6bcd157..2cd9c5e4f892865f3e52ec351ae9161064f30696 100644 (file)
@@ -101,6 +101,12 @@ &hdmi {
        hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
 };
 
+&pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
+       status = "okay";
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_gpio14>;
index 425f6b0a5ef8a95af3daa0adfc651ac891dca3b4..067d1f07a2d36c1653e47b2b3d64d77a0c81b813 100644 (file)
@@ -96,6 +96,12 @@ &hdmi {
        hpd-gpios = <&gpio 46 GPIO_ACTIVE_HIGH>;
 };
 
+&pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
+       status = "okay";
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_gpio14>;
index effa195e789589991dc68172fa04c39d121683e2..cfbdaacbaeba815cd5d1ce2a7bea50861558774a 100644 (file)
@@ -103,6 +103,12 @@ &hdmi {
        hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
 };
 
+&pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
+       status = "okay";
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_gpio14>;
index 772ec3b482316bafcc350e676097dcfdd2797b76..5641d162dfdb0c106eed6f7f4dc4f7c120930970 100644 (file)
@@ -96,6 +96,12 @@ &hdmi {
        hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
 };
 
+&pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
+       status = "okay";
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_gpio14>;
index 434483d6fc14634659e1291f387daa8f18340336..31ff602e2cd3644a5524443dbc817023852c01a9 100644 (file)
@@ -91,6 +91,12 @@ &hdmi {
        hpd-gpios = <&gpio 46 GPIO_ACTIVE_HIGH>;
 };
 
+&pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
+       status = "okay";
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_gpio14>;
index 6c3cfaa77f3ddcefa435127aa328b637cb5ec837..cb2d6d78a7fbf5d9a1ef3f70563fcb94f2ce8bef 100644 (file)
@@ -83,12 +83,6 @@ &sdhost {
        bus-width = <4>;
 };
 
-&pwm {
-       pinctrl-names = "default";
-       pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
-       status = "okay";
-};
-
 &usb {
        power-domains = <&power RPI_POWER_DOMAIN_USB>;
 };
index 5c339adabdf0152ec5c020b5880df2cc93afbac9..2fef70a099535dfceb746b64384ec5b41ff0c1ab 100644 (file)
@@ -41,6 +41,12 @@ &hdmi {
        hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
 };
 
+&pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio45>;
+       status = "okay";
+};
+
 &uart0 {
        pinctrl-names = "default";
        pinctrl-0 = <&uart0_gpio14>;
index 0b31d995a066cbfb0a4aa86fd1e31022d2f769ef..cc39b6f8d6a5877ff4149ca5aa9e80f45dd6163c 100644 (file)
@@ -42,6 +42,12 @@ expgpio: gpio {
        };
 };
 
+&pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio41>;
+       status = "okay";
+};
+
 /* uart0 communicates with the BT module */
 &uart0 {
        pinctrl-names = "default";