All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] arm64: dts: allwinner: a64: pinmux cleanups
@ 2018-08-28 10:01 ` Chen-Yu Tsai
  0 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-08-28 10:01 UTC (permalink / raw)
  To: Rob Herring, Mark Rutland, Maxime Ripard
  Cc: Chen-Yu Tsai, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-sunxi-/JYPxA39Uh5TLH3MbocFFw

Hi,

This series does some cleanup of the Allwinner A64 pinmux groups.

The first addresses a limitation on the A64 where we have the eMMC's
DS in always muxed in. The DS pin is shared with SPI0's MISO, thereby
preventing SPI0 from being used. In this patch we split out the DS
pin into a separate group for boards that actually utilize it to
select on their own.

The other two patches just rename pinmux group node names and labels
from <func>_pins_<[a-z]> to <func>_<pingroup/pin names>_pins. The latter
is the style we adopted later on, and is easier to know which pins they
correspond to, i.e. easier to review.

Please have a look.

While I want to do some more cleanup, I realized that the label and/or
node names might be used by distro (Armbian comes to mind) or personal
device tree overlay files. Do we need to have these remain fixed? Do
we or can we provide a fallback? (Is that even possible?)

Regards
ChenYu

Chen-Yu Tsai (3):
  arm64: dts: allwinner: a64: Split out data strobe pin from mmc2 pinmux
  arm64: dts: allwinner: a64: Rename uart0_pins_a label to uart0_pb_pins
  arm64: dts: allwinner: a64: Rename r_i2c_pins_a label to
    r_i2c_pl89_pins

 .../boot/dts/allwinner/sun50i-a64-amarula-relic.dts |  2 +-
 .../boot/dts/allwinner/sun50i-a64-bananapi-m64.dts  |  4 ++--
 .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts    |  2 +-
 .../boot/dts/allwinner/sun50i-a64-olinuxino.dts     |  2 +-
 .../boot/dts/allwinner/sun50i-a64-orangepi-win.dts  |  2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts |  2 +-
 .../boot/dts/allwinner/sun50i-a64-pinebook.dts      |  6 +++---
 .../dts/allwinner/sun50i-a64-sopine-baseboard.dts   |  2 +-
 .../arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts |  2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi       | 13 ++++++++++---
 10 files changed, 22 insertions(+), 15 deletions(-)

-- 
2.18.0

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 0/3] arm64: dts: allwinner: a64: pinmux cleanups
@ 2018-08-28 10:01 ` Chen-Yu Tsai
  0 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-08-28 10:01 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

This series does some cleanup of the Allwinner A64 pinmux groups.

The first addresses a limitation on the A64 where we have the eMMC's
DS in always muxed in. The DS pin is shared with SPI0's MISO, thereby
preventing SPI0 from being used. In this patch we split out the DS
pin into a separate group for boards that actually utilize it to
select on their own.

The other two patches just rename pinmux group node names and labels
from <func>_pins_<[a-z]> to <func>_<pingroup/pin names>_pins. The latter
is the style we adopted later on, and is easier to know which pins they
correspond to, i.e. easier to review.

Please have a look.

While I want to do some more cleanup, I realized that the label and/or
node names might be used by distro (Armbian comes to mind) or personal
device tree overlay files. Do we need to have these remain fixed? Do
we or can we provide a fallback? (Is that even possible?)

Regards
ChenYu

Chen-Yu Tsai (3):
  arm64: dts: allwinner: a64: Split out data strobe pin from mmc2 pinmux
  arm64: dts: allwinner: a64: Rename uart0_pins_a label to uart0_pb_pins
  arm64: dts: allwinner: a64: Rename r_i2c_pins_a label to
    r_i2c_pl89_pins

 .../boot/dts/allwinner/sun50i-a64-amarula-relic.dts |  2 +-
 .../boot/dts/allwinner/sun50i-a64-bananapi-m64.dts  |  4 ++--
 .../boot/dts/allwinner/sun50i-a64-nanopi-a64.dts    |  2 +-
 .../boot/dts/allwinner/sun50i-a64-olinuxino.dts     |  2 +-
 .../boot/dts/allwinner/sun50i-a64-orangepi-win.dts  |  2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts |  2 +-
 .../boot/dts/allwinner/sun50i-a64-pinebook.dts      |  6 +++---
 .../dts/allwinner/sun50i-a64-sopine-baseboard.dts   |  2 +-
 .../arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts |  2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi       | 13 ++++++++++---
 10 files changed, 22 insertions(+), 15 deletions(-)

-- 
2.18.0

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 1/3] arm64: dts: allwinner: a64: Split out data strobe pin from mmc2 pinmux
  2018-08-28 10:01 ` Chen-Yu Tsai
@ 2018-08-28 10:01     ` Chen-Yu Tsai
  -1 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-08-28 10:01 UTC (permalink / raw)
  To: Rob Herring, Mark Rutland, Maxime Ripard
  Cc: Chen-Yu Tsai, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-sunxi-/JYPxA39Uh5TLH3MbocFFw

The eMMC 5.0 standard introduced the data strobe (DS) pin. This pin is
not used for pre-5.0 data modes, nor is it found on pre-5.0 eMMC chips.
On the A64, this pin is muxed with spi0's MISO pin. If the DS pin is
included in the mmc2 pinmux by default, this wil prevent the usage
of both mmc2 and spi0 together.

Instead, split out the DS pin to a separate pinmux that only gets used
by boards that actually have it wired up. Currently supported ones
include the Bananapi M64 and Pine64 Pinebook. These are fixed up.

Fixes: a3e8f4926248 ("arm64: allwinner: a64: Add MMC pinctrl nodes")
Fixes: b8bcf0e1b212 ("arm64: allwinner: add BananaPi-M64 support")
Fixes: df35fbcfa398 ("arm64: dts: allwinner: add support for Pinebook")
Signed-off-by: Chen-Yu Tsai <wens-jdAy2FN1RRM@public.gmane.org>
---
 .../arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts    | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi            | 9 ++++++++-
 3 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
index 094cfed13df9..e643e453ec68 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
@@ -151,7 +151,7 @@
 
 &mmc2 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&mmc2_pins>;
+	pinctrl-0 = <&mmc2_pins>, <&mmc2_ds_pin>;
 	vmmc-supply = <&reg_dcdc1>;
 	bus-width = <8>;
 	non-removable;
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
index 4b8fe453bacd..73f14d7f915a 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
@@ -103,7 +103,7 @@
 
 &mmc2 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&mmc2_pins>;
+	pinctrl-0 = <&mmc2_pins>, <&mmc2_ds_pin>;
 	vmmc-supply = <&reg_dcdc1>;
 	vqmmc-supply = <&reg_eldo1>;
 	bus-width = <8>;
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
index b73f9287c3f0..364b7a499f7c 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
@@ -413,7 +413,7 @@
 			};
 
 			mmc2_pins: mmc2-pins {
-				pins = "PC1", "PC5", "PC6", "PC8", "PC9",
+				pins = "PC5", "PC6", "PC8", "PC9",
 				       "PC10","PC11", "PC12", "PC13",
 				       "PC14", "PC15", "PC16";
 				function = "mmc2";
@@ -421,6 +421,13 @@
 				bias-pull-up;
 			};
 
+			mmc2_ds_pin: mmc2-ds-pin {
+				pins = "PC1";
+				function = "mmc2";
+				drive-strength = <30>;
+				bias-pull-up;
+			};
+
 			pwm_pin: pwm_pin {
 				pins = "PD22";
 				function = "pwm";
-- 
2.18.0

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 1/3] arm64: dts: allwinner: a64: Split out data strobe pin from mmc2 pinmux
@ 2018-08-28 10:01     ` Chen-Yu Tsai
  0 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-08-28 10:01 UTC (permalink / raw)
  To: linux-arm-kernel

The eMMC 5.0 standard introduced the data strobe (DS) pin. This pin is
not used for pre-5.0 data modes, nor is it found on pre-5.0 eMMC chips.
On the A64, this pin is muxed with spi0's MISO pin. If the DS pin is
included in the mmc2 pinmux by default, this wil prevent the usage
of both mmc2 and spi0 together.

Instead, split out the DS pin to a separate pinmux that only gets used
by boards that actually have it wired up. Currently supported ones
include the Bananapi M64 and Pine64 Pinebook. These are fixed up.

Fixes: a3e8f4926248 ("arm64: allwinner: a64: Add MMC pinctrl nodes")
Fixes: b8bcf0e1b212 ("arm64: allwinner: add BananaPi-M64 support")
Fixes: df35fbcfa398 ("arm64: dts: allwinner: add support for Pinebook")
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 .../arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts    | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi            | 9 ++++++++-
 3 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
index 094cfed13df9..e643e453ec68 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
@@ -151,7 +151,7 @@
 
 &mmc2 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&mmc2_pins>;
+	pinctrl-0 = <&mmc2_pins>, <&mmc2_ds_pin>;
 	vmmc-supply = <&reg_dcdc1>;
 	bus-width = <8>;
 	non-removable;
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
index 4b8fe453bacd..73f14d7f915a 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
@@ -103,7 +103,7 @@
 
 &mmc2 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&mmc2_pins>;
+	pinctrl-0 = <&mmc2_pins>, <&mmc2_ds_pin>;
 	vmmc-supply = <&reg_dcdc1>;
 	vqmmc-supply = <&reg_eldo1>;
 	bus-width = <8>;
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
index b73f9287c3f0..364b7a499f7c 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
@@ -413,7 +413,7 @@
 			};
 
 			mmc2_pins: mmc2-pins {
-				pins = "PC1", "PC5", "PC6", "PC8", "PC9",
+				pins = "PC5", "PC6", "PC8", "PC9",
 				       "PC10","PC11", "PC12", "PC13",
 				       "PC14", "PC15", "PC16";
 				function = "mmc2";
@@ -421,6 +421,13 @@
 				bias-pull-up;
 			};
 
+			mmc2_ds_pin: mmc2-ds-pin {
+				pins = "PC1";
+				function = "mmc2";
+				drive-strength = <30>;
+				bias-pull-up;
+			};
+
 			pwm_pin: pwm_pin {
 				pins = "PD22";
 				function = "pwm";
-- 
2.18.0

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 2/3] arm64: dts: allwinner: a64: Rename uart0_pins_a label to uart0_pb_pins
  2018-08-28 10:01 ` Chen-Yu Tsai
@ 2018-08-28 10:01     ` Chen-Yu Tsai
  -1 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-08-28 10:01 UTC (permalink / raw)
  To: Rob Herring, Mark Rutland, Maxime Ripard
  Cc: Chen-Yu Tsai, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-sunxi-/JYPxA39Uh5TLH3MbocFFw

The pinmux name and label for a specific function should denote which
pingroup it is on, or if there is only one option for the function, have
not enumerating prefix/suffix at all.

The "uart0_pins_a" label is renamed to "uart0_pb_pins" to fit our
current style. The node name "uart0" is also changed to "uart0-pb-pins"
to match.

Signed-off-by: Chen-Yu Tsai <wens-jdAy2FN1RRM@public.gmane.org>
---
 arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts    | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts     | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts       | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts        | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts     | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts           | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts         | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts          | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi                 | 2 +-
 10 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts
index eac4793c8502..6cb2b7f0c817 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts
@@ -203,7 +203,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
index e643e453ec68..846c350decb4 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
@@ -302,7 +302,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
index 0ee915d8eb24..a0ac1390270e 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
@@ -252,7 +252,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
index a1c2f06ed474..657f58def54c 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
@@ -274,7 +274,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts
index c879aa8d8d1b..dc9a8d77f693 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts
@@ -299,7 +299,7 @@
 /* On debug connector */
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts
index 1b9b92e541d2..d3d5282b0ba8 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts
@@ -241,7 +241,7 @@
 /* On Exp and Euler connectors */
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
index 73f14d7f915a..25683a7ac64f 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
@@ -269,7 +269,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts
index c21f2331add6..beaa092976d7 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts
@@ -140,7 +140,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts
index 81f8e0098699..c455b24dd079 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts
@@ -260,7 +260,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
index 364b7a499f7c..e3eda63230a6 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
@@ -463,7 +463,7 @@
 				function = "spi1";
 			};
 
-			uart0_pins_a: uart0 {
+			uart0_pb_pins: uart0-pb-pins {
 				pins = "PB8", "PB9";
 				function = "uart0";
 			};
-- 
2.18.0

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 2/3] arm64: dts: allwinner: a64: Rename uart0_pins_a label to uart0_pb_pins
@ 2018-08-28 10:01     ` Chen-Yu Tsai
  0 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-08-28 10:01 UTC (permalink / raw)
  To: linux-arm-kernel

The pinmux name and label for a specific function should denote which
pingroup it is on, or if there is only one option for the function, have
not enumerating prefix/suffix at all.

The "uart0_pins_a" label is renamed to "uart0_pb_pins" to fit our
current style. The node name "uart0" is also changed to "uart0-pb-pins"
to match.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts    | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts     | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts       | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts        | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts     | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts           | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts         | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts          | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi                 | 2 +-
 10 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts
index eac4793c8502..6cb2b7f0c817 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-amarula-relic.dts
@@ -203,7 +203,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
index e643e453ec68..846c350decb4 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts
@@ -302,7 +302,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
index 0ee915d8eb24..a0ac1390270e 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts
@@ -252,7 +252,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
index a1c2f06ed474..657f58def54c 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-olinuxino.dts
@@ -274,7 +274,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts
index c879aa8d8d1b..dc9a8d77f693 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts
@@ -299,7 +299,7 @@
 /* On debug connector */
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts
index 1b9b92e541d2..d3d5282b0ba8 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts
@@ -241,7 +241,7 @@
 /* On Exp and Euler connectors */
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
index 73f14d7f915a..25683a7ac64f 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
@@ -269,7 +269,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts
index c21f2331add6..beaa092976d7 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-sopine-baseboard.dts
@@ -140,7 +140,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts
index 81f8e0098699..c455b24dd079 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-teres-i.dts
@@ -260,7 +260,7 @@
 
 &uart0 {
 	pinctrl-names = "default";
-	pinctrl-0 = <&uart0_pins_a>;
+	pinctrl-0 = <&uart0_pb_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
index 364b7a499f7c..e3eda63230a6 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
@@ -463,7 +463,7 @@
 				function = "spi1";
 			};
 
-			uart0_pins_a: uart0 {
+			uart0_pb_pins: uart0-pb-pins {
 				pins = "PB8", "PB9";
 				function = "uart0";
 			};
-- 
2.18.0

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 3/3] arm64: dts: allwinner: a64: Rename r_i2c_pins_a label to r_i2c_pl89_pins
  2018-08-28 10:01 ` Chen-Yu Tsai
@ 2018-08-28 10:01     ` Chen-Yu Tsai
  -1 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-08-28 10:01 UTC (permalink / raw)
  To: Rob Herring, Mark Rutland, Maxime Ripard
  Cc: Chen-Yu Tsai, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-sunxi-/JYPxA39Uh5TLH3MbocFFw

The pinmux name and label for a specific function should denote which
pingroup it is on, or if there is only one option for the function, have
not enumerating prefix/suffix at all.

The "r_i2c_pins_a" label is renamed to "r_i2c_pl89_pins" to fit our
current style. The node name "i2c" is also changed to "r-i2c-pl89-pins"
to match. The reason for the peculiar name is that the other option for
muxing R_I2C is on the PL0/PL1 pins, so the name has to mention the pin
numbers in addition to the pingroup.

Signed-off-by: Chen-Yu Tsai <wens-jdAy2FN1RRM@public.gmane.org>
---
 arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi         | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
index 25683a7ac64f..77fac84797e9 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
@@ -142,7 +142,7 @@
 &r_i2c {
 	clock-frequency = <100000>;
 	pinctrl-names = "default";
-	pinctrl-0 = <&r_i2c_pins_a>;
+	pinctrl-0 = <&r_i2c_pl89_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
index e3eda63230a6..e4cfa8778623 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
@@ -770,7 +770,7 @@
 			interrupt-controller;
 			#interrupt-cells = <3>;
 
-			r_i2c_pins_a: i2c-a {
+			r_i2c_pl89_pins: r-i2c-pl89-pins {
 				pins = "PL8", "PL9";
 				function = "s_i2c";
 			};
-- 
2.18.0

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 3/3] arm64: dts: allwinner: a64: Rename r_i2c_pins_a label to r_i2c_pl89_pins
@ 2018-08-28 10:01     ` Chen-Yu Tsai
  0 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-08-28 10:01 UTC (permalink / raw)
  To: linux-arm-kernel

The pinmux name and label for a specific function should denote which
pingroup it is on, or if there is only one option for the function, have
not enumerating prefix/suffix at all.

The "r_i2c_pins_a" label is renamed to "r_i2c_pl89_pins" to fit our
current style. The node name "i2c" is also changed to "r-i2c-pl89-pins"
to match. The reason for the peculiar name is that the other option for
muxing R_I2C is on the PL0/PL1 pins, so the name has to mention the pin
numbers in addition to the pingroup.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts | 2 +-
 arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi         | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
index 25683a7ac64f..77fac84797e9 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
@@ -142,7 +142,7 @@
 &r_i2c {
 	clock-frequency = <100000>;
 	pinctrl-names = "default";
-	pinctrl-0 = <&r_i2c_pins_a>;
+	pinctrl-0 = <&r_i2c_pl89_pins>;
 	status = "okay";
 };
 
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
index e3eda63230a6..e4cfa8778623 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
@@ -770,7 +770,7 @@
 			interrupt-controller;
 			#interrupt-cells = <3>;
 
-			r_i2c_pins_a: i2c-a {
+			r_i2c_pl89_pins: r-i2c-pl89-pins {
 				pins = "PL8", "PL9";
 				function = "s_i2c";
 			};
-- 
2.18.0

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [PATCH 0/3] arm64: dts: allwinner: a64: pinmux cleanups
  2018-08-28 10:01 ` Chen-Yu Tsai
@ 2018-08-28 15:11     ` Maxime Ripard
  -1 siblings, 0 replies; 12+ messages in thread
From: Maxime Ripard @ 2018-08-28 15:11 UTC (permalink / raw)
  To: Chen-Yu Tsai
  Cc: Rob Herring, Mark Rutland,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-sunxi-/JYPxA39Uh5TLH3MbocFFw

[-- Attachment #1: Type: text/plain, Size: 1413 bytes --]

On Tue, Aug 28, 2018 at 06:01:29PM +0800, Chen-Yu Tsai wrote:
> Hi,
> 
> This series does some cleanup of the Allwinner A64 pinmux groups.
> 
> The first addresses a limitation on the A64 where we have the eMMC's
> DS in always muxed in. The DS pin is shared with SPI0's MISO, thereby
> preventing SPI0 from being used. In this patch we split out the DS
> pin into a separate group for boards that actually utilize it to
> select on their own.
> 
> The other two patches just rename pinmux group node names and labels
> from <func>_pins_<[a-z]> to <func>_<pingroup/pin names>_pins. The latter
> is the style we adopted later on, and is easier to know which pins they
> correspond to, i.e. easier to review.
> 
> Please have a look.

Acked-by: Maxime Ripard <maxime.ripard-LDxbnhwyfcJBDgjK7y7TUQ@public.gmane.org>

> While I want to do some more cleanup, I realized that the label and/or
> node names might be used by distro (Armbian comes to mind) or personal
> device tree overlay files. Do we need to have these remain fixed? Do
> we or can we provide a fallback? (Is that even possible?)

I wouldn't worry too much about this. We broke it a number of times
already, and we probably will in the future for other stuff, I'm not
sure we have to provide any guarantee there, as long as the old,
compiled, dt still works.

Maxime

-- 
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 0/3] arm64: dts: allwinner: a64: pinmux cleanups
@ 2018-08-28 15:11     ` Maxime Ripard
  0 siblings, 0 replies; 12+ messages in thread
From: Maxime Ripard @ 2018-08-28 15:11 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Aug 28, 2018 at 06:01:29PM +0800, Chen-Yu Tsai wrote:
> Hi,
> 
> This series does some cleanup of the Allwinner A64 pinmux groups.
> 
> The first addresses a limitation on the A64 where we have the eMMC's
> DS in always muxed in. The DS pin is shared with SPI0's MISO, thereby
> preventing SPI0 from being used. In this patch we split out the DS
> pin into a separate group for boards that actually utilize it to
> select on their own.
> 
> The other two patches just rename pinmux group node names and labels
> from <func>_pins_<[a-z]> to <func>_<pingroup/pin names>_pins. The latter
> is the style we adopted later on, and is easier to know which pins they
> correspond to, i.e. easier to review.
> 
> Please have a look.

Acked-by: Maxime Ripard <maxime.ripard@bootlin.com>

> While I want to do some more cleanup, I realized that the label and/or
> node names might be used by distro (Armbian comes to mind) or personal
> device tree overlay files. Do we need to have these remain fixed? Do
> we or can we provide a fallback? (Is that even possible?)

I wouldn't worry too much about this. We broke it a number of times
already, and we probably will in the future for other stuff, I'm not
sure we have to provide any guarantee there, as long as the old,
compiled, dt still works.

Maxime

-- 
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20180828/cca1a80d/attachment.sig>

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 0/3] arm64: dts: allwinner: a64: pinmux cleanups
  2018-08-28 15:11     ` Maxime Ripard
@ 2018-09-03  3:00       ` Chen-Yu Tsai
  -1 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-09-03  3:00 UTC (permalink / raw)
  To: Maxime Ripard
  Cc: Rob Herring, Mark Rutland, linux-arm-kernel, devicetree, linux-sunxi

n Tue, Aug 28, 2018 at 11:12 PM Maxime Ripard <maxime.ripard-LDxbnhwyfcJBDgjK7y7TUQ@public.gmane.org> wrote:
>
> On Tue, Aug 28, 2018 at 06:01:29PM +0800, Chen-Yu Tsai wrote:
> > Hi,
> >
> > This series does some cleanup of the Allwinner A64 pinmux groups.
> >
> > The first addresses a limitation on the A64 where we have the eMMC's
> > DS in always muxed in. The DS pin is shared with SPI0's MISO, thereby
> > preventing SPI0 from being used. In this patch we split out the DS
> > pin into a separate group for boards that actually utilize it to
> > select on their own.
> >
> > The other two patches just rename pinmux group node names and labels
> > from <func>_pins_<[a-z]> to <func>_<pingroup/pin names>_pins. The latter
> > is the style we adopted later on, and is easier to know which pins they
> > correspond to, i.e. easier to review.
> >
> > Please have a look.
>
> Acked-by: Maxime Ripard <maxime.ripard-LDxbnhwyfcJBDgjK7y7TUQ@public.gmane.org>

Applied.

> > While I want to do some more cleanup, I realized that the label and/or
> > node names might be used by distro (Armbian comes to mind) or personal
> > device tree overlay files. Do we need to have these remain fixed? Do
> > we or can we provide a fallback? (Is that even possible?)
>
> I wouldn't worry too much about this. We broke it a number of times
> already, and we probably will in the future for other stuff, I'm not
> sure we have to provide any guarantee there, as long as the old,
> compiled, dt still works.

OK :)

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 0/3] arm64: dts: allwinner: a64: pinmux cleanups
@ 2018-09-03  3:00       ` Chen-Yu Tsai
  0 siblings, 0 replies; 12+ messages in thread
From: Chen-Yu Tsai @ 2018-09-03  3:00 UTC (permalink / raw)
  To: linux-arm-kernel

n Tue, Aug 28, 2018 at 11:12 PM Maxime Ripard <maxime.ripard@bootlin.com> wrote:
>
> On Tue, Aug 28, 2018 at 06:01:29PM +0800, Chen-Yu Tsai wrote:
> > Hi,
> >
> > This series does some cleanup of the Allwinner A64 pinmux groups.
> >
> > The first addresses a limitation on the A64 where we have the eMMC's
> > DS in always muxed in. The DS pin is shared with SPI0's MISO, thereby
> > preventing SPI0 from being used. In this patch we split out the DS
> > pin into a separate group for boards that actually utilize it to
> > select on their own.
> >
> > The other two patches just rename pinmux group node names and labels
> > from <func>_pins_<[a-z]> to <func>_<pingroup/pin names>_pins. The latter
> > is the style we adopted later on, and is easier to know which pins they
> > correspond to, i.e. easier to review.
> >
> > Please have a look.
>
> Acked-by: Maxime Ripard <maxime.ripard@bootlin.com>

Applied.

> > While I want to do some more cleanup, I realized that the label and/or
> > node names might be used by distro (Armbian comes to mind) or personal
> > device tree overlay files. Do we need to have these remain fixed? Do
> > we or can we provide a fallback? (Is that even possible?)
>
> I wouldn't worry too much about this. We broke it a number of times
> already, and we probably will in the future for other stuff, I'm not
> sure we have to provide any guarantee there, as long as the old,
> compiled, dt still works.

OK :)

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2018-09-03  3:00 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-28 10:01 [PATCH 0/3] arm64: dts: allwinner: a64: pinmux cleanups Chen-Yu Tsai
2018-08-28 10:01 ` Chen-Yu Tsai
     [not found] ` <20180828100132.12975-1-wens-jdAy2FN1RRM@public.gmane.org>
2018-08-28 10:01   ` [PATCH 1/3] arm64: dts: allwinner: a64: Split out data strobe pin from mmc2 pinmux Chen-Yu Tsai
2018-08-28 10:01     ` Chen-Yu Tsai
2018-08-28 10:01   ` [PATCH 2/3] arm64: dts: allwinner: a64: Rename uart0_pins_a label to uart0_pb_pins Chen-Yu Tsai
2018-08-28 10:01     ` Chen-Yu Tsai
2018-08-28 10:01   ` [PATCH 3/3] arm64: dts: allwinner: a64: Rename r_i2c_pins_a label to r_i2c_pl89_pins Chen-Yu Tsai
2018-08-28 10:01     ` Chen-Yu Tsai
2018-08-28 15:11   ` [PATCH 0/3] arm64: dts: allwinner: a64: pinmux cleanups Maxime Ripard
2018-08-28 15:11     ` Maxime Ripard
2018-09-03  3:00     ` Chen-Yu Tsai
2018-09-03  3:00       ` Chen-Yu Tsai

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.