Skip to contentSkip to conversation

dt: fsl-imx-esdhc.txt: Fix gpio number assignment

PATCH In review Fabio Estevam 3 participants 10 messages Jun 10, 2012 – Jun 11, 2012

Subsystems (6)
lore
Share & tools
lore

Fabio Estevam

author reviewer
#0 lore raw

PATCH 1/4 dt: fsl-imx-esdhc.txt: Fix gpio number assignment

From: Fabio Estevam <[email protected]>

Fix gpio number assignment, so that it can match the number stated in the comment.

Cc:

---
 .../devicetree/bindings/mmc/fsl-imx-esdhc.txt      |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt +2 -2
index c7e404b..fea541e 100644
@@ -29,6 +29,6 @@ esdhc@70008000 {
 	compatible = "fsl,imx51-esdhc";
 	reg = <0x70008000 0x4000>;
 	interrupts = <2>;
-	cd-gpios = <&gpio0 6 0>; /* GPIO1_6 */
-	wp-gpios = <&gpio0 5 0>; /* GPIO1_5 */
+	cd-gpios = <&gpio1 6 0>; /* GPIO1_6 */
+	wp-gpios = <&gpio1 5 0>; /* GPIO1_5 */
 };
Signature · 1 line
1.7.1
author reviewer
#1 lore raw

PATCH 2/4 dt: fsl-mma8450.tx: Add missing 'reg' description

From: Fabio Estevam <[email protected]>

Add missing 'reg' description.

----

 .../devicetree/bindings/input/fsl-mma8450.txt      |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
Documentation/devicetree/bindings/input/fsl-mma8450.txt +1 -0
index a00c94c..0b96e57 100644
@@ -2,6 +2,7 @@
 
 Required properties:
 - compatible : "fsl,mma8450".
+- reg: the I2C address of MMA8450
 
 Example:
 
Signature · 1 line
1.7.1
author reviewer
#2 lore raw

PATCH 3/4 dt: fsl-fec.txt: Fix gpio number assignment

In reply to Fabio Estevam

From: Fabio Estevam <[email protected]>

Fix gpio number assignment, so that it can match the number stated in the comment.

---
 Documentation/devicetree/bindings/net/fsl-fec.txt |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
Documentation/devicetree/bindings/net/fsl-fec.txt +1 -1
index 7ab9e1a..4616fc2 100644
@@ -19,6 +19,6 @@ ethernet@83fec000 {
 	reg = <0x83fec000 0x4000>;
 	interrupts = <87>;
 	phy-mode = "mii";
-	phy-reset-gpios = <&gpio1 14 0>; /* GPIO2_14 */
+	phy-reset-gpios = <&gpio2 14 0>; /* GPIO2_14 */
 	local-mac-address = [00 04 9F 01 1B B9];
 };
Signature · 1 line
1.7.1
author reviewer
#3 lore raw

PATCH 4/4 dt: mc13xxx.txt: Fix gpio number assignment

In reply to Fabio Estevam

From: Fabio Estevam <[email protected]>

Fix gpio number assignment, so that it can match the number stated in the comment.

---
 Documentation/devicetree/bindings/mfd/mc13xxx.txt |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
Documentation/devicetree/bindings/mfd/mc13xxx.txt +2 -2
index 19f6af4..baf0798 100644
@@ -46,8 +46,8 @@ Examples:
 
 ecspi@70010000 { /* ECSPI1 */
 	fsl,spi-num-chipselects = <2>;
-	cs-gpios = <&gpio3 24 0>, /* GPIO4_24 */
-		   <&gpio3 25 0>; /* GPIO4_25 */
+	cs-gpios = <&gpio4 24 0>, /* GPIO4_24 */
+		   <&gpio4 25 0>; /* GPIO4_25 */
 	status = "okay";
 
 	pmic: mc13892@0 {
Signature · 1 line
1.7.1
#4 lore raw
In reply to Fabio Estevam
Quoted 15 lines · Fabio Estevam

From: Fabio Estevam <[email protected]>

Fix gpio number assignment, so that it can match the number stated in the comment.

Cc:

---
 .../devicetree/bindings/mmc/fsl-imx-esdhc.txt      |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt +0 -0
index c7e404b..fea541e 100644

Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt esdhc@70008000 { · line 33

Quoted 7 lines
Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt +2 -2
@@ -29,6 +29,6 @@ esdhc@70008000 {
 	compatible = "fsl,imx51-esdhc";
 	reg = <0x70008000 0x4000>;
 	interrupts = <2>;
-	cd-gpios = <&gpio0 6 0>; /* GPIO1_6 */
-	wp-gpios = <&gpio0 5 0>; /* GPIO1_5 */
+	cd-gpios = <&gpio1 6 0>; /* GPIO1_6 */
+	wp-gpios = <&gpio1 5 0>; /* GPIO1_5 */

Are you sure all these aren't just DT is 0 based and the chip is 1 based numbering?

Rob

Quoted 1 line
Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt +0 -0
 };
author reviewer
#5 lore raw
Quoted 11 lines · Rob Herring
Quoted 10 lines · Fabio Estevam

From: Fabio Estevam <[email protected]>

Fix gpio number assignment, so that it can match the number stated in the comment.

Cc:

---
 .../devicetree/bindings/mmc/fsl-imx-esdhc.txt      |    4 ++--

 1 files changed, 2 insertions(+), 2 deletions(-)
Quoted 15 lines

Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt esdhc@70008000 { · line 33

Quoted 12 lines
Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt +2 -2
index c7e404b..fea541e 100644
@@ -29,6 +29,6 @@ esdhc@70008000 {
       compatible = "fsl,imx51-esdhc";
       reg = <0x70008000 0x4000>;
       interrupts = <2>;
-     cd-gpios = <&gpio0 6 0>; /* GPIO1_6 */
-     wp-gpios = <&gpio0 5 0>; /* GPIO1_5 */
+     cd-gpios = <&gpio1 6 0>; /* GPIO1_6 */
+     wp-gpios = <&gpio1 5 0>; /* GPIO1_5 */

Are you sure all these aren't just DT is 0 based and the chip is 1 based numbering?

We start counting gpio number from 0 in i.mx, so the DT number and the GPIO number should match.

#6 lore raw
Quoted 28 lines · Fabio Estevam
Quoted 11 lines · Rob Herring
Quoted 10 lines · Fabio Estevam

From: Fabio Estevam <[email protected]>

Fix gpio number assignment, so that it can match the number stated in the comment.

Cc:

---
 .../devicetree/bindings/mmc/fsl-imx-esdhc.txt      |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
Quoted 15 lines

Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt esdhc@70008000 { · line 33

Quoted 12 lines
Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt +2 -2
index c7e404b..fea541e 100644
@@ -29,6 +29,6 @@ esdhc@70008000 {
      compatible = "fsl,imx51-esdhc";
      reg = <0x70008000 0x4000>;
      interrupts = <2>;
-     cd-gpios = <&gpio0 6 0>; /* GPIO1_6 */
-     wp-gpios = <&gpio0 5 0>; /* GPIO1_5 */
+     cd-gpios = <&gpio1 6 0>; /* GPIO1_6 */
+     wp-gpios = <&gpio1 5 0>; /* GPIO1_5 */

Are you sure all these aren't just DT is 0 based and the chip is 1 based numbering?

Quoted 2 lines

We start counting gpio number from 0 in i.mx, so the DT number and the GPIO number should match.

I'm talking about bank numbers, not gpio numbers:

/* There's a off-by-one betweem the gpio bank number and the gpiochip */ /* range e.g. GPIO_1_5 is gpio 5 under linux */
#define IMX_GPIO_NR(bank, nr) (((bank) - 1) * 32 + (nr))

Rob

maintainer
#7 lore raw
Quoted 29 lines · Rob Herring
Quoted 28 lines · Fabio Estevam
Quoted 26 lines · Rob Herring
Quoted 15 lines · Fabio Estevam

From: Fabio Estevam <[email protected]>

Fix gpio number assignment, so that it can match the number stated in the comment.

Cc:

---
 .../devicetree/bindings/mmc/fsl-imx-esdhc.txt      |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt +0 -0
index c7e404b..fea541e 100644

Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt esdhc@70008000 { · line 33

Quoted 7 lines
Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt +2 -2
@@ -29,6 +29,6 @@ esdhc@70008000 {
      compatible = "fsl,imx51-esdhc";
      reg = <0x70008000 0x4000>;
      interrupts = <2>;
-     cd-gpios = <&gpio0 6 0>; /* GPIO1_6 */
-     wp-gpios = <&gpio0 5 0>; /* GPIO1_5 */
+     cd-gpios = <&gpio1 6 0>; /* GPIO1_6 */
+     wp-gpios = <&gpio1 5 0>; /* GPIO1_5 */

Are you sure all these aren't just DT is 0 based and the chip is 1 based numbering?

Quoted 8 lines
Quoted 2 lines

We start counting gpio number from 0 in i.mx, so the DT number and the GPIO number should match.

I'm talking about bank numbers, not gpio numbers:

/* There's a off-by-one betweem the gpio bank number and the gpiochip */ /* range e.g. GPIO_1_5 is gpio 5 under linux */
#define IMX_GPIO_NR(bank, nr) (((bank) - 1) * 32 + (nr))

Traditionally I started counting at 0 no matter what the datasheet told. Now we go to match the numbering with the datasheets, which of course can be confusing while transitioning this.
Fabios patch is correct, there is no gpio0 in the devicetree.

Sascha

Signature · 4 lines
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |
author reviewer
#8 lore raw

Hi Sascha,

Quoted 4 lines · Sascha Hauer

Traditionally I started counting at 0 no matter what the datasheet told. Now we go to match the numbering with the datasheets, which of course can be confusing while transitioning this.
Fabios patch is correct, there is no gpio0 in the devicetree.

Who could pick this patch series?

Thanks,

Fabio Estevam

#9 lore raw
In reply to Sascha Hauer
Quoted 35 lines · Sascha Hauer
Quoted 34 lines · Rob Herring
Quoted 28 lines · Fabio Estevam
Quoted 11 lines · Rob Herring
Quoted 10 lines · Fabio Estevam

From: Fabio Estevam <[email protected]>

Fix gpio number assignment, so that it can match the number stated in the comment.

Cc:

---
 .../devicetree/bindings/mmc/fsl-imx-esdhc.txt      |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
Quoted 15 lines

Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt esdhc@70008000 { · line 33

Quoted 12 lines
Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.txt +2 -2
index c7e404b..fea541e 100644
@@ -29,6 +29,6 @@ esdhc@70008000 {
      compatible = "fsl,imx51-esdhc";
      reg = <0x70008000 0x4000>;
      interrupts = <2>;
-     cd-gpios = <&gpio0 6 0>; /* GPIO1_6 */
-     wp-gpios = <&gpio0 5 0>; /* GPIO1_5 */
+     cd-gpios = <&gpio1 6 0>; /* GPIO1_6 */
+     wp-gpios = <&gpio1 5 0>; /* GPIO1_5 */

Are you sure all these aren't just DT is 0 based and the chip is 1 based numbering?

Quoted 2 lines

We start counting gpio number from 0 in i.mx, so the DT number and the GPIO number should match.

I'm talking about bank numbers, not gpio numbers:

Quoted 9 lines
Quoted 3 lines

/* There's a off-by-one betweem the gpio bank number and the gpiochip */ /* range e.g. GPIO_1_5 is gpio 5 under linux */
#define IMX_GPIO_NR(bank, nr) (((bank) - 1) * 32 + (nr))

Traditionally I started counting at 0 no matter what the datasheet told. Now we go to match the numbering with the datasheets, which of course can be confusing while transitioning this.
Fabios patch is correct, there is no gpio0 in the devicetree.

Okay, applied.

Rob