8617377
From patchwork Sun Jan 29 18:40:59 2017
8617377
Content-Type: text/plain; charset="utf-8"
8617377
MIME-Version: 1.0
8617377
Content-Transfer-Encoding: 7bit
8617377
Subject: [v2] ARM: bcm2835: dts: fix uart0 pinctrl node names
8617377
From: Baruch Siach <baruch@tkos.co.il>
8617377
X-Patchwork-Id: 9544261
8617377
Message-Id: <f37d02c769d0e2b6db2529cafb86b5fdd1e09a94.1485715259.git.baruch@tkos.co.il>
8617377
To: Stephen Warren <swarren@wwwdotorg.org>, Lee Jones <lee@kernel.org>,
8617377
 Eric Anholt <eric@anholt.net>
8617377
Cc: Baruch Siach <baruch@tkos.co.il>, linux-rpi-kernel@lists.infradead.org, 
8617377
 linux-arm-kernel@lists.infradead.org
8617377
Date: Sun, 29 Jan 2017 20:40:59 +0200
8617377
8617377
Downstream kernel uses pins 32, 33 as UART0 (PL011) Rx/Tx to communicate with
8617377
the Bluetooth chip. So ALT3 of these pins is most likely not CTS/RTS. Change
8617377
the node name to reflect that. This matches section 6.2 "Alternative Function
8617377
Assignments" in the BCM2835 ARM Peripherals document.
8617377
8617377
With this change in place, adding
8617377
8617377
  &uart0 {
8617377
	 pinctrl-names = "default";
8617377
	 pinctrl-0 = <&uart0_gpio32 &gpclk2_gpio43>;
8617377
	 status = "okay";
8617377
  };
8617377
8617377
to bcm2837-rpi-3-b.dts does the right thing on my Raspberry Pi 3.
8617377
8617377
Pins 30, 31 are CTS/RTS of UART0 in alternate function 3. Rename uart0_gpio30
8617377
as well.
8617377
8617377
While at it, fix a little typo in a nearby comment.
8617377
8617377
Fixes: 21ff843931b ("ARM: dts: bcm283x: Define standard pinctrl groups in the gpio node.")
8617377
Acked-by: Stefan Wahren <stefan.wahren@i2se.com>
8617377
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
8617377
Reviewed-by: Eric Anholt <eric@anholt.net>
8617377
---
8617377
v2:
8617377
   * Reference the ARM Peripherals document
8617377
   * Fix subject typo (Stefan)
8617377
   * Rename also uart0_gpio30 (Stefan)
8617377
   * Add comment typo fix (Stefan)
8617377
   * Add Stefan's ack
8617377
---
8617377
 arch/arm/boot/dts/bcm283x.dtsi | 6 +++---
8617377
 1 file changed, 3 insertions(+), 3 deletions(-)
8617377
8617377
diff --git a/arch/arm/boot/dts/bcm283x.dtsi b/arch/arm/boot/dts/bcm283x.dtsi
8617377
index 9a44da190897..bc8ad417c8a3 100644
8617377
--- a/arch/arm/boot/dts/bcm283x.dtsi
8617377
+++ b/arch/arm/boot/dts/bcm283x.dtsi
8617377
@@ -292,17 +292,17 @@
8617377
 			/* Separate from the uart0_gpio14 group
8617377
 			 * because it conflicts with spi1_gpio16, and
8617377
 			 * people often run uart0 on the two pins
8617377
-			 * without flow contrl.
8617377
+			 * without flow control.
8617377
 			 */
8617377
 			uart0_ctsrts_gpio16: uart0_ctsrts_gpio16 {
8617377
 				brcm,pins = <16 17>;
8617377
 				brcm,function = <BCM2835_FSEL_ALT3>;
8617377
 			};
8617377
-			uart0_gpio30: uart0_gpio30 {
8617377
+			uart0_ctsrts_gpio30: uart0_ctsrts_gpio30 {
8617377
 				brcm,pins = <30 31>;
8617377
 				brcm,function = <BCM2835_FSEL_ALT3>;
8617377
 			};
8617377
-			uart0_ctsrts_gpio32: uart0_ctsrts_gpio32 {
8617377
+			uart0_gpio32: uart0_gpio32 {
8617377
 				brcm,pins = <32 33>;
8617377
 				brcm,function = <BCM2835_FSEL_ALT3>;
8617377
 			};
8617377
From patchwork Sun Jan 29 19:53:10 2017
8617377
Content-Type: text/plain; charset="utf-8"
8617377
MIME-Version: 1.0
8617377
Content-Transfer-Encoding: 7bit
8617377
Subject: [1/2] ARM: bcm2835: dts: fix i2c0 pins
8617377
From: Baruch Siach <baruch@tkos.co.il>
8617377
X-Patchwork-Id: 9544275
8617377
Message-Id: <9290fa9eed6b5ff1c5c96b9dac41eca286b7eef9.1485719591.git.baruch@tkos.co.il>
8617377
To: Stephen Warren <swarren@wwwdotorg.org>, Lee Jones <lee@kernel.org>,
8617377
 Eric Anholt <eric@anholt.net>
8617377
Cc: Baruch Siach <baruch@tkos.co.il>, linux-rpi-kernel@lists.infradead.org, 
8617377
 linux-arm-kernel@lists.infradead.org
8617377
Date: Sun, 29 Jan 2017 21:53:10 +0200
8617377
8617377
According to the BCM2835 ARM Peripherals document i2c0 doesn't map to pins 32,
8617377
34 but to 28, 29.
8617377
8617377
Fixes: 21ff843931b ("ARM: dts: bcm283x: Define standard pinctrl groups in the gpio node.")
8617377
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
8617377
---
8617377
 arch/arm/boot/dts/bcm283x.dtsi | 4 ++--
8617377
 1 file changed, 2 insertions(+), 2 deletions(-)
8617377
8617377
diff --git a/arch/arm/boot/dts/bcm283x.dtsi b/arch/arm/boot/dts/bcm283x.dtsi
8617377
index bc8ad417c8a3..2ae842921250 100644
8617377
--- a/arch/arm/boot/dts/bcm283x.dtsi
8617377
+++ b/arch/arm/boot/dts/bcm283x.dtsi
8617377
@@ -195,8 +195,8 @@
8617377
 				brcm,pins = <0 1>;
8617377
 				brcm,function = <BCM2835_FSEL_ALT0>;
8617377
 			};
8617377
-			i2c0_gpio32: i2c0_gpio32 {
8617377
-				brcm,pins = <32 34>;
8617377
+			i2c0_gpio28: i2c0_gpio28 {
8617377
+				brcm,pins = <28 29>;
8617377
 				brcm,function = <BCM2835_FSEL_ALT0>;
8617377
 			};
8617377
 			i2c0_gpio44: i2c0_gpio44 {
8617377
From patchwork Sun Jan 29 19:53:11 2017
8617377
Content-Type: text/plain; charset="utf-8"
8617377
MIME-Version: 1.0
8617377
Content-Transfer-Encoding: 7bit
8617377
Subject: [2/2] ARM: bcm2835: dts: fix uart0/uart1 pins
8617377
From: Baruch Siach <baruch@tkos.co.il>
8617377
X-Patchwork-Id: 9544277
8617377
Message-Id: <e0f527a24b0048daba88ef36d5324245e003111c.1485719591.git.baruch@tkos.co.il>
8617377
To: Stephen Warren <swarren@wwwdotorg.org>, Lee Jones <lee@kernel.org>,
8617377
 Eric Anholt <eric@anholt.net>
8617377
Cc: Baruch Siach <baruch@tkos.co.il>, linux-rpi-kernel@lists.infradead.org, 
8617377
 linux-arm-kernel@lists.infradead.org
8617377
Date: Sun, 29 Jan 2017 21:53:11 +0200
8617377
8617377
According to the BCM2835 ARM Peripherals document uart1 doesn't map to pins
8617377
36-39, but uart0 does.
8617377
8617377
Also, split into separate Rx/Tx and CST/RTS groups to match other uart nodes.
8617377
8617377
Fixes: 21ff843931b ("ARM: dts: bcm283x: Define standard pinctrl groups in the gpio node.")
8617377
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
8617377
---
8617377
 arch/arm/boot/dts/bcm283x.dtsi | 12 ++++++++----
8617377
 1 file changed, 8 insertions(+), 4 deletions(-)
8617377
8617377
diff --git a/arch/arm/boot/dts/bcm283x.dtsi b/arch/arm/boot/dts/bcm283x.dtsi
8617377
index 2ae842921250..9ee8346b8b19 100644
8617377
--- a/arch/arm/boot/dts/bcm283x.dtsi
8617377
+++ b/arch/arm/boot/dts/bcm283x.dtsi
8617377
@@ -306,6 +306,14 @@
8617377
 				brcm,pins = <32 33>;
8617377
 				brcm,function = <BCM2835_FSEL_ALT3>;
8617377
 			};
8617377
+			uart0_gpio36: uart0_gpio36 {
8617377
+				brcm,pins = <36 37>;
8617377
+				brcm,function = <BCM2835_FSEL_ALT2>;
8617377
+			};
8617377
+			uart0_ctsrts_gpio38: uart0_ctsrts_gpio38 {
8617377
+				brcm,pins = <38 39>;
8617377
+				brcm,function = <BCM2835_FSEL_ALT2>;
8617377
+			};
8617377
 
8617377
 			uart1_gpio14: uart1_gpio14 {
8617377
 				brcm,pins = <14 15>;
8617377
@@ -323,10 +331,6 @@
8617377
 				brcm,pins = <30 31>;
8617377
 				brcm,function = <BCM2835_FSEL_ALT5>;
8617377
 			};
8617377
-			uart1_gpio36: uart1_gpio36 {
8617377
-				brcm,pins = <36 37 38 39>;
8617377
-				brcm,function = <BCM2835_FSEL_ALT2>;
8617377
-			};
8617377
 			uart1_gpio40: uart1_gpio40 {
8617377
 				brcm,pins = <40 41>;
8617377
 				brcm,function = <BCM2835_FSEL_ALT5>;
8617377
From patchwork Mon Jan 30 18:44:39 2017
8617377
Content-Type: text/plain; charset="utf-8"
8617377
MIME-Version: 1.0
8617377
Content-Transfer-Encoding: 7bit
8617377
Subject: ARM: bcm2835: dt: add index to the ethernet alias
8617377
From: Baruch Siach <baruch@tkos.co.il>
8617377
X-Patchwork-Id: 9545945
8617377
Message-Id: <5942321c5d0bfea54eac64ace2b217e8e0b6220d.1485801879.git.baruch@tkos.co.il>
8617377
To: Stephen Warren <swarren@wwwdotorg.org>, Lee Jones <lee@kernel.org>,
8617377
 Eric Anholt <eric@anholt.net>
8617377
Cc: Lubomir Rintel <lkundrak@v3.sk>, Baruch Siach <baruch@tkos.co.il>,
8617377
 linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org
8617377
Date: Mon, 30 Jan 2017 20:44:39 +0200
8617377
8617377
An alias name should have an index number even when it is the only of its type.
8617377
This allows U-Boot to add the local-mac-address property. Otherwise U-Boot
8617377
skips the alias.
8617377
8617377
Cc: Lubomir Rintel <lkundrak@v3.sk>
8617377
Fixes: 6a93792774 ("ARM: bcm2835: dt: Add the ethernet to the device trees")
8617377
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
8617377
Acked-by: Lubomir Rintel <lkundrak@v3.sk>
8617377
---
8617377
 arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi | 2 +-
8617377
 arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi | 2 +-
8617377
 2 files changed, 2 insertions(+), 2 deletions(-)
8617377
8617377
diff --git a/arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi b/arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi
8617377
index 12c981e51134..9a0599f711ff 100644
8617377
--- a/arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi
8617377
+++ b/arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi
8617377
@@ -1,6 +1,6 @@
8617377
 / {
8617377
 	aliases {
8617377
-		ethernet = &ethernet;
8617377
+		ethernet0 = &ethernet;
8617377
 	};
8617377
 };
8617377
 
8617377
diff --git a/arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi b/arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi
8617377
index 3f0a56ebcf1f..dc7ae776db5f 100644
8617377
--- a/arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi
8617377
+++ b/arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi
8617377
@@ -1,6 +1,6 @@
8617377
 / {
8617377
 	aliases {
8617377
-		ethernet = &ethernet;
8617377
+		ethernet0 = &ethernet;
8617377
 	};
8617377
 };
8617377