Skip to contentSkip to conversation

Pinctrl muxing for the Crystalfontz boards

PATCH New Maxime Ripard 2 participants 5 messages Nov 3, 2012 – Nov 5, 2012

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover Pinctrl muxing for the Crystalfontz boards

Hi all,

This patch serie add the hogpins to explicitly mux the GPIOs used across the device tree as such for the two Crystalfontz boards, and make the gpio-led driver use pinctrl.

This serie goes on top of the i2c-mux-gpios patches I sent on this list.

Maxime

Maxime Ripard (2):
ARM: dts: cfa10036: Use pinctrl for power led
ARM: dts: mxs: Add hog pins to Crystalfontz boards

 arch/arm/boot/dts/imx28-cfa10036.dts |   27 +++++++++++++++++++++++++++
 arch/arm/boot/dts/imx28-cfa10049.dts |   16 ++++++++++++++++
 2 files changed, 43 insertions(+)
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH 1/2 ARM: dts: cfa10036: Use pinctrl for power led

The leds-gpio driver recently got pinctrl support, so setup the power led gpio muxing through pinctrl.

This avoids the warning:
leds-gpio leds.X: pins are not configured from the driver

---
 arch/arm/boot/dts/imx28-cfa10036.dts |   14 ++++++++++++++
 1 file changed, 14 insertions(+)
arch/arm/boot/dts/imx28-cfa10036.dts +14 -0
index 816cae9..8760b87 100644
@@ -22,6 +22,18 @@
 
 	apb at 80000000 {
 		apbh at 80000000 {
+			pinctrl at 80018000 {
+				led_pins_cfa10036: leds-10036 at 0 {
+					reg = <0>;
+					fsl,pinmux-ids = <
+						0x3043 /* MX28_PAD_AUART1_RX__GPIO_3_4 */
+					>;
+					fsl,drive-strength = <0>;
+					fsl,voltage = <1>;
+					fsl,pull-up = <0>;
+				};
+			};
+
 			ssp0: ssp at 80010000 {
 				compatible = "fsl,imx28-mmc";
 				pinctrl-names = "default";
@@ -62,6 +74,8 @@
 
 	leds {
 		compatible = "gpio-leds";
+		pinctrl-names = "default";
+		pinctrl-0 = <&led_pins_cfa10036>;
 
 		power {
 			gpios = <&gpio3 4 1>;
Signature · 1 line
1.7.9.5
#2 lore raw

PATCH 2/2 ARM: dts: mxs: Add hog pins to Crystalfontz boards

In reply to Maxime Ripard

Use a hog_pins pinctrl group to force the muxing of GPIOs used on the Crystalfonz CFA10036 and CFA10049 boards.

---
 arch/arm/boot/dts/imx28-cfa10036.dts |   13 +++++++++++++
 arch/arm/boot/dts/imx28-cfa10049.dts |   16 ++++++++++++++++
 2 files changed, 29 insertions(+)
arch/arm/boot/dts/imx28-cfa10036.dts +13 -0
index 8760b87..1594694 100644
@@ -23,6 +23,19 @@
 	apb at 80000000 {
 		apbh at 80000000 {
 			pinctrl at 80018000 {
+				pinctrl-names = "default";
+				pinctrl-0 = <&hog_pins_cfa10036>;
+
+				hog_pins_cfa10036: hog-10036 at 0 {
+					reg = <0>;
+					fsl,pinmux-ids = <
+						0x2073 /* MX28_PAD_SSP0_D7__GPIO_2_7 */
+					>;
+					fsl,drive-strength = <0>;
+					fsl,voltage = <1>;
+					fsl,pull-up = <0>;
+				};
+
 				led_pins_cfa10036: leds-10036 at 0 {
 					reg = <0>;
 					fsl,pinmux-ids = <
arch/arm/boot/dts/imx28-cfa10049.dts +16 -0
index 6c4c071..bdc80a4 100644
@@ -22,6 +22,22 @@
 	apb at 80000000 {
 		apbh at 80000000 {
 			pinctrl@80018000 {
+				pinctrl-names = "default", "default";
+				pinctrl-1 = <&hog_pins_cfa10049>;
+
+				hog_pins_cfa10049: hog-10049 at 0 {
+					reg = <0>;
+					fsl,pinmux-ids = <
+						0x0073 /* MX28_PAD_GPMI_D7__GPIO_0_7 */
+						0x1163 /* MX28_PAD_LCD_D22__GPIO_1_22 */
+						0x1173 /* MX28_PAD_LCD_D22__GPIO_1_23 */
+						0x2153 /* MX28_PAD_SSP2_D5__GPIO_2_21 */
+					>;
+					fsl,drive-strength = <0>;
+					fsl,voltage = <1>;
+					fsl,pull-up = <0>;
+				};
+
 				spi3_pins_cfa10049: spi3-cfa10049 at 0 {
 					reg = <0>;
 					fsl,pinmux-ids = <
Signature · 1 line
1.7.9.5
#3 lore raw

cover Pinctrl muxing for the Crystalfontz boards

In reply to Maxime Ripard
Quoted 8 lines · Maxime Ripard

Hi all,

This patch serie add the hogpins to explicitly mux the GPIOs used across the device tree as such for the two Crystalfontz boards, and make the gpio-led driver use pinctrl.

This serie goes on top of the i2c-mux-gpios patches I sent on this list.

I do not see that dependency at all, so just applied both patches.

Shawn

Quoted 14 lines

Maxime

Maxime Ripard (2):
ARM: dts: cfa10036: Use pinctrl for power led
ARM: dts: mxs: Add hog pins to Crystalfontz boards

 arch/arm/boot/dts/imx28-cfa10036.dts |   27 +++++++++++++++++++++++++++
 arch/arm/boot/dts/imx28-cfa10049.dts |   16 ++++++++++++++++
 2 files changed, 43 insertions(+)
Signature · 1 line
1.7.9.5
#4 lore raw

cover Pinctrl muxing for the Crystalfontz boards

Le 05/11/2012 04:20, Shawn Guo a ?crit :

Quoted 11 lines · Maxime Ripard
Quoted 8 lines

Hi all,

This patch serie add the hogpins to explicitly mux the GPIOs used across the device tree as such for the two Crystalfontz boards, and make the gpio-led driver use pinctrl.

This serie goes on top of the i2c-mux-gpios patches I sent on this list.

I do not see that dependency at all, so just applied both patches.

Well, some of the pins muxed are for the muxer, thus the dependency, but, after all, it will just work.

Thanks,
Maxime

Signature · 4 lines
Maxime Ripard, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com