linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
@ 2014-01-03 11:55 Fabio Estevam
  2014-01-03 12:07 ` Shawn Guo
  0 siblings, 1 reply; 13+ messages in thread
From: Fabio Estevam @ 2014-01-03 11:55 UTC (permalink / raw)
  To: linux-arm-kernel

From: Fabio Estevam <fabio.estevam@freescale.com>

Since commit 7a399e3a2e (fec: Do not assume that PHY reset is active low), we no
longer assume that the PHY reset is active low.

Now we need to retrieve this information from the device tree instead.

Passing '0' as the phy-reset-gpios means 'active high' according to the 
definition from include/dt-bindings/gpio/gpio.h:

#define GPIO_ACTIVE_HIGH 0
#define GPIO_ACTIVE_LOW 1

, so in order to keep things working as before we need to explicitly pass
GPIO_ACTIVE_LOW as the flag.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
---
Olof,

This is needed for 3.13 as 7a399e3a2e (fec: Do not assume that PHY reset is 
active low) has already reached mainline.

This patch was generated against linus' tree.

 arch/arm/boot/dts/imx27-phytec-phycore-som.dts | 2 +-
 arch/arm/boot/dts/imx27.dtsi                   | 1 +
 arch/arm/boot/dts/imx28-apf28.dts              | 2 +-
 arch/arm/boot/dts/imx28-apf28dev.dts           | 2 +-
 arch/arm/boot/dts/imx28-cfa10037.dts           | 2 +-
 arch/arm/boot/dts/imx28-cfa10049.dts           | 2 +-
 arch/arm/boot/dts/imx28-cfa10057.dts           | 2 +-
 arch/arm/boot/dts/imx28-cfa10058.dts           | 2 +-
 arch/arm/boot/dts/imx28-evk.dts                | 2 +-
 arch/arm/boot/dts/imx28-m28cu3.dts             | 2 +-
 arch/arm/boot/dts/imx28.dtsi                   | 1 +
 arch/arm/boot/dts/imx51-apf51.dts              | 2 +-
 arch/arm/boot/dts/imx51.dtsi                   | 1 +
 arch/arm/boot/dts/imx53-evk.dts                | 2 +-
 arch/arm/boot/dts/imx53-mba53.dts              | 2 +-
 arch/arm/boot/dts/imx53-qsb.dts                | 2 +-
 arch/arm/boot/dts/imx53-smd.dts                | 2 +-
 arch/arm/boot/dts/imx53.dtsi                   | 1 +
 arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi     | 2 +-
 arch/arm/boot/dts/imx6q-sabrelite.dts          | 2 +-
 arch/arm/boot/dts/imx6qdl-sabresd.dtsi         | 2 +-
 arch/arm/boot/dts/imx6qdl-wandboard.dtsi       | 2 +-
 arch/arm/boot/dts/imx6qdl.dtsi                 | 1 +
 23 files changed, 23 insertions(+), 18 deletions(-)

diff --git a/arch/arm/boot/dts/imx27-phytec-phycore-som.dts b/arch/arm/boot/dts/imx27-phytec-phycore-som.dts
index 4ec402c..49b5e67 100644
--- a/arch/arm/boot/dts/imx27-phytec-phycore-som.dts
+++ b/arch/arm/boot/dts/imx27-phytec-phycore-som.dts
@@ -134,7 +134,7 @@
 };
 
 &fec {
-	phy-reset-gpios = <&gpio3 30 0>;
+	phy-reset-gpios = <&gpio3 30 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx27.dtsi b/arch/arm/boot/dts/imx27.dtsi
index 826231e..5708e42 100644
--- a/arch/arm/boot/dts/imx27.dtsi
+++ b/arch/arm/boot/dts/imx27.dtsi
@@ -9,6 +9,7 @@
  * http://www.gnu.org/copyleft/gpl.html
  */
 
+#include <dt-bindings/gpio/gpio.h>
 #include "skeleton.dtsi"
 
 / {
diff --git a/arch/arm/boot/dts/imx28-apf28.dts b/arch/arm/boot/dts/imx28-apf28.dts
index 7198fe3..070e59c 100644
--- a/arch/arm/boot/dts/imx28-apf28.dts
+++ b/arch/arm/boot/dts/imx28-apf28.dts
@@ -78,7 +78,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
-			phy-reset-gpios = <&gpio4 13 0>;
+			phy-reset-gpios = <&gpio4 13 GPIO_ACTIVE_LOW>;
 			status = "okay";
 		};
 	};
diff --git a/arch/arm/boot/dts/imx28-apf28dev.dts b/arch/arm/boot/dts/imx28-apf28dev.dts
index e2efd8d..f47a30a 100644
--- a/arch/arm/boot/dts/imx28-apf28dev.dts
+++ b/arch/arm/boot/dts/imx28-apf28dev.dts
@@ -143,7 +143,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac1_pins_a>;
-			phy-reset-gpios = <&gpio0 23 0>;
+			phy-reset-gpios = <&gpio0 23 GPIO_ACTIVE_LOW>;
 			status = "okay";
 		};
 	};
diff --git a/arch/arm/boot/dts/imx28-cfa10037.dts b/arch/arm/boot/dts/imx28-cfa10037.dts
index f93e9a7..b2bbd21 100644
--- a/arch/arm/boot/dts/imx28-cfa10037.dts
+++ b/arch/arm/boot/dts/imx28-cfa10037.dts
@@ -64,7 +64,7 @@
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a
 				&mac0_pins_cfa10037>;
-			phy-reset-gpios = <&gpio2 21 0>;
+			phy-reset-gpios = <&gpio2 21 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-cfa10049.dts b/arch/arm/boot/dts/imx28-cfa10049.dts
index 7087b4b..f57b245 100644
--- a/arch/arm/boot/dts/imx28-cfa10049.dts
+++ b/arch/arm/boot/dts/imx28-cfa10049.dts
@@ -300,7 +300,7 @@
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a
 				&mac0_pins_cfa10049>;
-			phy-reset-gpios = <&gpio2 21 0>;
+			phy-reset-gpios = <&gpio2 21 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-cfa10057.dts b/arch/arm/boot/dts/imx28-cfa10057.dts
index 3c13128..fb6c6e7 100644
--- a/arch/arm/boot/dts/imx28-cfa10057.dts
+++ b/arch/arm/boot/dts/imx28-cfa10057.dts
@@ -159,7 +159,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
-			phy-reset-gpios = <&gpio2 21 0>;
+			phy-reset-gpios = <&gpio2 21 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-cfa10058.dts b/arch/arm/boot/dts/imx28-cfa10058.dts
index 2469d34..ba0a625 100644
--- a/arch/arm/boot/dts/imx28-cfa10058.dts
+++ b/arch/arm/boot/dts/imx28-cfa10058.dts
@@ -126,7 +126,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
-			phy-reset-gpios = <&gpio2 21 0>;
+			phy-reset-gpios = <&gpio2 21 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-evk.dts b/arch/arm/boot/dts/imx28-evk.dts
index 4267c2b..fef39a4 100644
--- a/arch/arm/boot/dts/imx28-evk.dts
+++ b/arch/arm/boot/dts/imx28-evk.dts
@@ -263,7 +263,7 @@
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
 			phy-supply = <&reg_fec_3v3>;
-			phy-reset-gpios = <&gpio4 13 0>;
+			phy-reset-gpios = <&gpio4 13 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-m28cu3.dts b/arch/arm/boot/dts/imx28-m28cu3.dts
index d3958da..82cb4f8 100644
--- a/arch/arm/boot/dts/imx28-m28cu3.dts
+++ b/arch/arm/boot/dts/imx28-m28cu3.dts
@@ -189,7 +189,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
-			phy-reset-gpios = <&gpio4 13 0>;
+			phy-reset-gpios = <&gpio4 13 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28.dtsi b/arch/arm/boot/dts/imx28.dtsi
index cda19c8..48529cb 100644
--- a/arch/arm/boot/dts/imx28.dtsi
+++ b/arch/arm/boot/dts/imx28.dtsi
@@ -9,6 +9,7 @@
  * http://www.gnu.org/copyleft/gpl.html
  */
 
+#include <dt-bindings/gpio/gpio.h>
 #include "skeleton.dtsi"
 #include "imx28-pinfunc.h"
 
diff --git a/arch/arm/boot/dts/imx51-apf51.dts b/arch/arm/boot/dts/imx51-apf51.dts
index b360699..3eae080 100644
--- a/arch/arm/boot/dts/imx51-apf51.dts
+++ b/arch/arm/boot/dts/imx51-apf51.dts
@@ -36,7 +36,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec_2>;
 	phy-mode = "mii";
-	phy-reset-gpios = <&gpio3 0 0>;
+	phy-reset-gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
 	phy-reset-duration = <1>;
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx51.dtsi b/arch/arm/boot/dts/imx51.dtsi
index 4bcdd3a..f1ab0e2 100644
--- a/arch/arm/boot/dts/imx51.dtsi
+++ b/arch/arm/boot/dts/imx51.dtsi
@@ -10,6 +10,7 @@
  * http://www.gnu.org/copyleft/gpl.html
  */
 
+#include <dt-bindings/gpio/gpio.h>
 #include "skeleton.dtsi"
 #include "imx51-pinfunc.h"
 
diff --git a/arch/arm/boot/dts/imx53-evk.dts b/arch/arm/boot/dts/imx53-evk.dts
index 801fda7..5ee3d7d 100644
--- a/arch/arm/boot/dts/imx53-evk.dts
+++ b/arch/arm/boot/dts/imx53-evk.dts
@@ -121,6 +121,6 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec_1>;
 	phy-mode = "rmii";
-	phy-reset-gpios = <&gpio7 6 0>;
+	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx53-mba53.dts b/arch/arm/boot/dts/imx53-mba53.dts
index a630902..d57e43e 100644
--- a/arch/arm/boot/dts/imx53-mba53.dts
+++ b/arch/arm/boot/dts/imx53-mba53.dts
@@ -175,7 +175,7 @@
 };
 
 &fec {
-	phy-reset-gpios = <&gpio7 6 0>;
+	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx53-qsb.dts b/arch/arm/boot/dts/imx53-qsb.dts
index 91a5935..3e655e9 100644
--- a/arch/arm/boot/dts/imx53-qsb.dts
+++ b/arch/arm/boot/dts/imx53-qsb.dts
@@ -303,7 +303,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec_1>;
 	phy-mode = "rmii";
-	phy-reset-gpios = <&gpio7 6 0>;
+	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx53-smd.dts b/arch/arm/boot/dts/imx53-smd.dts
index a9b6e10..91dc916 100644
--- a/arch/arm/boot/dts/imx53-smd.dts
+++ b/arch/arm/boot/dts/imx53-smd.dts
@@ -177,6 +177,6 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec_1>;
 	phy-mode = "rmii";
-	phy-reset-gpios = <&gpio7 6 0>;
+	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx53.dtsi b/arch/arm/boot/dts/imx53.dtsi
index 4307e80..abf1101 100644
--- a/arch/arm/boot/dts/imx53.dtsi
+++ b/arch/arm/boot/dts/imx53.dtsi
@@ -10,6 +10,7 @@
  * http://www.gnu.org/copyleft/gpl.html
  */
 
+#include <dt-bindings/gpio/gpio.h>
 #include "skeleton.dtsi"
 #include "imx53-pinfunc.h"
 
diff --git a/arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi b/arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi
index 1a3b50d..3e28d13 100644
--- a/arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi
+++ b/arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi
@@ -152,7 +152,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet_3>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio3 23 0>;
+	phy-reset-gpios = <&gpio3 23 GPIO_ACTIVE_LOW>;
 	status = "disabled";
 };
 
diff --git a/arch/arm/boot/dts/imx6q-sabrelite.dts b/arch/arm/boot/dts/imx6q-sabrelite.dts
index f004913..e44a69b 100644
--- a/arch/arm/boot/dts/imx6q-sabrelite.dts
+++ b/arch/arm/boot/dts/imx6q-sabrelite.dts
@@ -89,7 +89,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet_1>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio3 23 0>;
+	phy-reset-gpios = <&gpio3 23 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-sabresd.dtsi b/arch/arm/boot/dts/imx6qdl-sabresd.dtsi
index e75e11b..b4a4de5 100644
--- a/arch/arm/boot/dts/imx6qdl-sabresd.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-sabresd.dtsi
@@ -116,7 +116,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet_1>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio1 25 0>;
+	phy-reset-gpios = <&gpio1 25 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-wandboard.dtsi b/arch/arm/boot/dts/imx6qdl-wandboard.dtsi
index 35f5479..773504c 100644
--- a/arch/arm/boot/dts/imx6qdl-wandboard.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-wandboard.dtsi
@@ -98,7 +98,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet_1>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio3 29 0>;
+	phy-reset-gpios = <&gpio3 29 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl.dtsi b/arch/arm/boot/dts/imx6qdl.dtsi
index fb28b2e..681b07e 100644
--- a/arch/arm/boot/dts/imx6qdl.dtsi
+++ b/arch/arm/boot/dts/imx6qdl.dtsi
@@ -10,6 +10,7 @@
  * http://www.gnu.org/copyleft/gpl.html
  */
 
+#include <dt-bindings/gpio/gpio.h>
 #include "skeleton.dtsi"
 
 / {
-- 
1.8.1.2

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-03 11:55 [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset Fabio Estevam
@ 2014-01-03 12:07 ` Shawn Guo
  2014-01-04  5:47   ` Olof Johansson
  0 siblings, 1 reply; 13+ messages in thread
From: Shawn Guo @ 2014-01-03 12:07 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Jan 03, 2014 at 09:55:56AM -0200, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.estevam@freescale.com>
> 
> Since commit 7a399e3a2e (fec: Do not assume that PHY reset is active low), we no
> longer assume that the PHY reset is active low.
> 
> Now we need to retrieve this information from the device tree instead.
> 
> Passing '0' as the phy-reset-gpios means 'active high' according to the 
> definition from include/dt-bindings/gpio/gpio.h:
> 
> #define GPIO_ACTIVE_HIGH 0
> #define GPIO_ACTIVE_LOW 1
> 
> , so in order to keep things working as before we need to explicitly pass
> GPIO_ACTIVE_LOW as the flag.
> 
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>

Acked-by: Shawn Guo <shawn.guo@linaro.org>

> ---
> Olof,
> 
> This is needed for 3.13 as 7a399e3a2e (fec: Do not assume that PHY reset is 
> active low) has already reached mainline.
> 
> This patch was generated against linus' tree.

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-03 12:07 ` Shawn Guo
@ 2014-01-04  5:47   ` Olof Johansson
  2014-01-05 17:29     ` Olof Johansson
  0 siblings, 1 reply; 13+ messages in thread
From: Olof Johansson @ 2014-01-04  5:47 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Jan 03, 2014 at 08:07:14PM +0800, Shawn Guo wrote:
> On Fri, Jan 03, 2014 at 09:55:56AM -0200, Fabio Estevam wrote:
> > From: Fabio Estevam <fabio.estevam@freescale.com>
> > 
> > Since commit 7a399e3a2e (fec: Do not assume that PHY reset is active low), we no
> > longer assume that the PHY reset is active low.
> > 
> > Now we need to retrieve this information from the device tree instead.
> > 
> > Passing '0' as the phy-reset-gpios means 'active high' according to the 
> > definition from include/dt-bindings/gpio/gpio.h:
> > 
> > #define GPIO_ACTIVE_HIGH 0
> > #define GPIO_ACTIVE_LOW 1
> > 
> > , so in order to keep things working as before we need to explicitly pass
> > GPIO_ACTIVE_LOW as the flag.
> > 
> > Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> 
> Acked-by: Shawn Guo <shawn.guo@linaro.org>
> 

Applied to fixes. Thanks.


-Olof

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-04  5:47   ` Olof Johansson
@ 2014-01-05 17:29     ` Olof Johansson
  2014-01-06  2:24       ` Shawn Guo
  0 siblings, 1 reply; 13+ messages in thread
From: Olof Johansson @ 2014-01-05 17:29 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Jan 3, 2014 at 9:47 PM, Olof Johansson <olof@lixom.net> wrote:
> On Fri, Jan 03, 2014 at 08:07:14PM +0800, Shawn Guo wrote:
>> On Fri, Jan 03, 2014 at 09:55:56AM -0200, Fabio Estevam wrote:
>> > From: Fabio Estevam <fabio.estevam@freescale.com>
>> >
>> > Since commit 7a399e3a2e (fec: Do not assume that PHY reset is active low), we no
>> > longer assume that the PHY reset is active low.
>> >
>> > Now we need to retrieve this information from the device tree instead.
>> >
>> > Passing '0' as the phy-reset-gpios means 'active high' according to the
>> > definition from include/dt-bindings/gpio/gpio.h:
>> >
>> > #define GPIO_ACTIVE_HIGH 0
>> > #define GPIO_ACTIVE_LOW 1
>> >
>> > , so in order to keep things working as before we need to explicitly pass
>> > GPIO_ACTIVE_LOW as the flag.
>> >
>> > Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
>>
>> Acked-by: Shawn Guo <shawn.guo@linaro.org>
>>
>
> Applied to fixes. Thanks.

Actually, Russell brought this to my attention (I should have looked
closer earlier). You guys have made an incompatible binding change
here. In -rc6? That's not cool, we're not doing those any more.

What should happen is that the driver change should be reverted
instead. You can't rely on every device tree out there changing to
accommodate these kind of things any more.

I'll drop the fix from the DT side.


-Olof

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-05 17:29     ` Olof Johansson
@ 2014-01-06  2:24       ` Shawn Guo
  2014-01-06  2:43         ` Olof Johansson
  2014-01-06 11:14         ` Russell King - ARM Linux
  0 siblings, 2 replies; 13+ messages in thread
From: Shawn Guo @ 2014-01-06  2:24 UTC (permalink / raw)
  To: linux-arm-kernel

On Sun, Jan 05, 2014 at 09:29:37AM -0800, Olof Johansson wrote:
> Actually, Russell brought this to my attention (I should have looked
> closer earlier). You guys have made an incompatible binding change
> here. In -rc6? That's not cool, we're not doing those any more.

Yes, the driver change hit mainline too quickly.

> 
> What should happen is that the driver change should be reverted
> instead. You can't rely on every device tree out there changing to
> accommodate these kind of things any more.

Fabio just sent a revert patch for it, and David has queued it.

This is a typical example that we did not implement device tree
bindings perfectly right in the first place, and we have to live with it
forever.  If someday there is board design using an active high PHY
reset, we basically have to introduce another property for it.  But
it does no harm to correct the level type of the existing property in
device tree sources anyway.  So I will still queue Fabio's dts patch [1]
for 3.14 - a different one from what you're dropping here.  The
patch [1] is against my for-next branch while the dropped one is
against mainline.

Shawn

[1] http://www.spinics.net/lists/arm-kernel/msg297829.html

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-06  2:24       ` Shawn Guo
@ 2014-01-06  2:43         ` Olof Johansson
  2014-01-06 11:14         ` Russell King - ARM Linux
  1 sibling, 0 replies; 13+ messages in thread
From: Olof Johansson @ 2014-01-06  2:43 UTC (permalink / raw)
  To: linux-arm-kernel

On Sun, Jan 5, 2014 at 6:24 PM, Shawn Guo <shawn.guo@linaro.org> wrote:
> On Sun, Jan 05, 2014 at 09:29:37AM -0800, Olof Johansson wrote:
>> Actually, Russell brought this to my attention (I should have looked
>> closer earlier). You guys have made an incompatible binding change
>> here. In -rc6? That's not cool, we're not doing those any more.
>
> Yes, the driver change hit mainline too quickly.
>
>>
>> What should happen is that the driver change should be reverted
>> instead. You can't rely on every device tree out there changing to
>> accommodate these kind of things any more.
>
> Fabio just sent a revert patch for it, and David has queued it.
>
> This is a typical example that we did not implement device tree
> bindings perfectly right in the first place, and we have to live with it
> forever.  If someday there is board design using an active high PHY
> reset, we basically have to introduce another property for it.

Yes, or another, more precise, binding name.
> But
> it does no harm to correct the level type of the existing property in
> device tree sources anyway.  So I will still queue Fabio's dts patch [1]
> for 3.14 - a different one from what you're dropping here.  The
> patch [1] is against my for-next branch while the dropped one is
> against mainline.

Sounds good. Thanks!


-Olof

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-06  2:24       ` Shawn Guo
  2014-01-06  2:43         ` Olof Johansson
@ 2014-01-06 11:14         ` Russell King - ARM Linux
  2014-01-06 12:43           ` Shawn Guo
  1 sibling, 1 reply; 13+ messages in thread
From: Russell King - ARM Linux @ 2014-01-06 11:14 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Jan 06, 2014 at 10:24:23AM +0800, Shawn Guo wrote:
> This is a typical example that we did not implement device tree
> bindings perfectly right in the first place, and we have to live with it
> forever.  If someday there is board design using an active high PHY
> reset, we basically have to introduce another property for it.

Yes and no.  That third number in the property is always zero at present,
right?  If so, just define zero to mean "the default level of reset"
which would be the -rc6 behaviour.

Then you can define non-zero values to mean "explicitly state the level".

-- 
FTTC broadband for 0.8mile line: 5.8Mbps down 500kbps up.  Estimation
in database were 13.1 to 19Mbit for a good line, about 7.5+ for a bad.
Estimate before purchase was "up to 13.2Mbit".

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-06 11:14         ` Russell King - ARM Linux
@ 2014-01-06 12:43           ` Shawn Guo
  0 siblings, 0 replies; 13+ messages in thread
From: Shawn Guo @ 2014-01-06 12:43 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Jan 06, 2014 at 11:14:28AM +0000, Russell King - ARM Linux wrote:
> On Mon, Jan 06, 2014 at 10:24:23AM +0800, Shawn Guo wrote:
> > This is a typical example that we did not implement device tree
> > bindings perfectly right in the first place, and we have to live with it
> > forever.  If someday there is board design using an active high PHY
> > reset, we basically have to introduce another property for it.
> 
> Yes and no.  That third number in the property is always zero at present,
> right?  If so, just define zero to mean "the default level of reset"
> which would be the -rc6 behaviour.
> 
> Then you can define non-zero values to mean "explicitly state the level".

This is not nice either, because the third number in *-gpios property is
already defined by gpio bindings: 

  Documentation/devicetree/bindings/gpio/gpio.txt
  Documentation/devicetree/bindings/gpio/fsl-imx-gpio.txt

Shawn

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-03  4:15     ` Shawn Guo
@ 2014-01-03 11:21       ` Fabio Estevam
  0 siblings, 0 replies; 13+ messages in thread
From: Fabio Estevam @ 2014-01-03 11:21 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Jan 3, 2014 at 2:15 AM, Shawn Guo <shawn.guo@linaro.org> wrote:

>> If this patch goes via your for-next there will be no harm to your
>> tree, since the fec driver will just ignore the gpio flag and the
>> behaviour will be the same as before.
>
> You need to know that my for-next branch target is v3.14-rc not v3.13.

Yes, you are right.

>>
>> If you are not happy with it, then I will have to generate the patch
>> against mainline and ask davem to apply it.
>
> You have to generate a patch against mainline, and we can send it via
> arm-soc tree.

Understood. Will send it soon.

Thanks,

Fabio Estevam

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-03  3:28   ` Fabio Estevam
@ 2014-01-03  4:15     ` Shawn Guo
  2014-01-03 11:21       ` Fabio Estevam
  0 siblings, 1 reply; 13+ messages in thread
From: Shawn Guo @ 2014-01-03  4:15 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Jan 03, 2014 at 01:28:05AM -0200, Fabio Estevam wrote:
> Hi Shawn,
> 
> On Fri, Jan 3, 2014 at 1:22 AM, Shawn Guo <shawn.guo@linaro.org> wrote:
> 
> > If this is needed for 3.13, you should generate the patch against the
> > mainline where the fec change is in place rather than my for-next
> > branch.  And for those dts files that can only be patched against my
> > for-next branch, we need another patch.
> 
> If this patch goes via your for-next there will be no harm to your
> tree, since the fec driver will just ignore the gpio flag and the
> behaviour will be the same as before.

You need to know that my for-next branch target is v3.14-rc not v3.13.

> 
> If you are not happy with it, then I will have to generate the patch
> against mainline and ask davem to apply it.

You have to generate a patch against mainline, and we can send it via
arm-soc tree.

Shawn

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-03  3:22 ` Shawn Guo
@ 2014-01-03  3:28   ` Fabio Estevam
  2014-01-03  4:15     ` Shawn Guo
  0 siblings, 1 reply; 13+ messages in thread
From: Fabio Estevam @ 2014-01-03  3:28 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Shawn,

On Fri, Jan 3, 2014 at 1:22 AM, Shawn Guo <shawn.guo@linaro.org> wrote:

> If this is needed for 3.13, you should generate the patch against the
> mainline where the fec change is in place rather than my for-next
> branch.  And for those dts files that can only be patched against my
> for-next branch, we need another patch.

If this patch goes via your for-next there will be no harm to your
tree, since the fec driver will just ignore the gpio flag and the
behaviour will be the same as before.

If you are not happy with it, then I will have to generate the patch
against mainline and ask davem to apply it.

Regards,

Fabio Estevam

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
  2014-01-03  2:14 Fabio Estevam
@ 2014-01-03  3:22 ` Shawn Guo
  2014-01-03  3:28   ` Fabio Estevam
  0 siblings, 1 reply; 13+ messages in thread
From: Shawn Guo @ 2014-01-03  3:22 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Jan 03, 2014 at 12:14:13AM -0200, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.estevam@freescale.com>
> 
> Since commit 7a399e3a2e (fec: Do not assume that PHY reset is active low), we no
> longer assume that the PHY reset is active low.
> 
> Now we need to retrieve this information from the device tree instead.
> 
> Passing '0' as the phy-reset-gpios means 'active high' according to the 
> definition from include/dt-bindings/gpio/gpio.h:
> 
> #define GPIO_ACTIVE_HIGH 0
> #define GPIO_ACTIVE_LOW 1
> 
> , so in order to keep things working as before we need to explicitly pass
> GPIO_ACTIVE_LOW as the flag.

So it sounds like we have a git bisect issue here.

> 
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> ---
> Shawn,
> 
> This is needed for 3.13 as 7a399e3a2e (fec: Do not assume that PHY reset is 
> active low) already reached mainline.

If this is needed for 3.13, you should generate the patch against the
mainline where the fec change is in place rather than my for-next
branch.  And for those dts files that can only be patched against my
for-next branch, we need another patch.

Shawn

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

* [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset
@ 2014-01-03  2:14 Fabio Estevam
  2014-01-03  3:22 ` Shawn Guo
  0 siblings, 1 reply; 13+ messages in thread
From: Fabio Estevam @ 2014-01-03  2:14 UTC (permalink / raw)
  To: linux-arm-kernel

From: Fabio Estevam <fabio.estevam@freescale.com>

Since commit 7a399e3a2e (fec: Do not assume that PHY reset is active low), we no
longer assume that the PHY reset is active low.

Now we need to retrieve this information from the device tree instead.

Passing '0' as the phy-reset-gpios means 'active high' according to the 
definition from include/dt-bindings/gpio/gpio.h:

#define GPIO_ACTIVE_HIGH 0
#define GPIO_ACTIVE_LOW 1

, so in order to keep things working as before we need to explicitly pass
GPIO_ACTIVE_LOW as the flag.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
---
Shawn,

This is needed for 3.13 as 7a399e3a2e (fec: Do not assume that PHY reset is 
active low) already reached mainline.

 arch/arm/boot/dts/imx28-apf28.dts              | 2 +-
 arch/arm/boot/dts/imx28-apf28dev.dts           | 2 +-
 arch/arm/boot/dts/imx28-cfa10037.dts           | 2 +-
 arch/arm/boot/dts/imx28-cfa10049.dts           | 2 +-
 arch/arm/boot/dts/imx28-cfa10057.dts           | 2 +-
 arch/arm/boot/dts/imx28-cfa10058.dts           | 2 +-
 arch/arm/boot/dts/imx28-duckbill.dts           | 2 +-
 arch/arm/boot/dts/imx28-evk.dts                | 2 +-
 arch/arm/boot/dts/imx28-m28cu3.dts             | 2 +-
 arch/arm/boot/dts/imx28.dtsi                   | 1 +
 arch/arm/boot/dts/imx50-evk.dts                | 2 +-
 arch/arm/boot/dts/imx50.dtsi                   | 1 +
 arch/arm/boot/dts/imx53-evk.dts                | 2 +-
 arch/arm/boot/dts/imx53-mba53.dts              | 2 +-
 arch/arm/boot/dts/imx53-qsb.dts                | 2 +-
 arch/arm/boot/dts/imx53-smd.dts                | 2 +-
 arch/arm/boot/dts/imx53-voipac-dmm-668.dtsi    | 2 +-
 arch/arm/boot/dts/imx53.dtsi                   | 1 +
 arch/arm/boot/dts/imx6q-dmo-edmqmx6.dts        | 2 +-
 arch/arm/boot/dts/imx6q-gw5400-a.dts           | 2 +-
 arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi     | 2 +-
 arch/arm/boot/dts/imx6qdl-gw51xx.dtsi          | 2 +-
 arch/arm/boot/dts/imx6qdl-gw52xx.dtsi          | 2 +-
 arch/arm/boot/dts/imx6qdl-gw53xx.dtsi          | 2 +-
 arch/arm/boot/dts/imx6qdl-gw54xx.dtsi          | 2 +-
 arch/arm/boot/dts/imx6qdl-microsom-ar8035.dtsi | 2 +-
 arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi      | 2 +-
 arch/arm/boot/dts/imx6qdl-sabresd.dtsi         | 2 +-
 arch/arm/boot/dts/imx6qdl-wandboard.dtsi       | 2 +-
 arch/arm/boot/dts/imx6qdl.dtsi                 | 1 +
 30 files changed, 30 insertions(+), 26 deletions(-)

diff --git a/arch/arm/boot/dts/imx28-apf28.dts b/arch/arm/boot/dts/imx28-apf28.dts
index 7198fe3..070e59c 100644
--- a/arch/arm/boot/dts/imx28-apf28.dts
+++ b/arch/arm/boot/dts/imx28-apf28.dts
@@ -78,7 +78,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
-			phy-reset-gpios = <&gpio4 13 0>;
+			phy-reset-gpios = <&gpio4 13 GPIO_ACTIVE_LOW>;
 			status = "okay";
 		};
 	};
diff --git a/arch/arm/boot/dts/imx28-apf28dev.dts b/arch/arm/boot/dts/imx28-apf28dev.dts
index 334dea5..d750846 100644
--- a/arch/arm/boot/dts/imx28-apf28dev.dts
+++ b/arch/arm/boot/dts/imx28-apf28dev.dts
@@ -155,7 +155,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac1_pins_a>;
-			phy-reset-gpios = <&gpio0 23 0>;
+			phy-reset-gpios = <&gpio0 23 GPIO_ACTIVE_LOW>;
 			status = "okay";
 		};
 	};
diff --git a/arch/arm/boot/dts/imx28-cfa10037.dts b/arch/arm/boot/dts/imx28-cfa10037.dts
index e5beaa5..3d13b32 100644
--- a/arch/arm/boot/dts/imx28-cfa10037.dts
+++ b/arch/arm/boot/dts/imx28-cfa10037.dts
@@ -64,7 +64,7 @@
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a
 				&mac0_pins_cfa10037>;
-			phy-reset-gpios = <&gpio2 21 0>;
+			phy-reset-gpios = <&gpio2 21 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-cfa10049.dts b/arch/arm/boot/dts/imx28-cfa10049.dts
index 7d51459..e3b964a 100644
--- a/arch/arm/boot/dts/imx28-cfa10049.dts
+++ b/arch/arm/boot/dts/imx28-cfa10049.dts
@@ -327,7 +327,7 @@
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a
 				&mac0_pins_cfa10049>;
-			phy-reset-gpios = <&gpio2 21 0>;
+			phy-reset-gpios = <&gpio2 21 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-cfa10057.dts b/arch/arm/boot/dts/imx28-cfa10057.dts
index c4e00ce..fe23064 100644
--- a/arch/arm/boot/dts/imx28-cfa10057.dts
+++ b/arch/arm/boot/dts/imx28-cfa10057.dts
@@ -162,7 +162,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
-			phy-reset-gpios = <&gpio2 21 0>;
+			phy-reset-gpios = <&gpio2 21 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-cfa10058.dts b/arch/arm/boot/dts/imx28-cfa10058.dts
index 7c9cc78..0e17e3e 100644
--- a/arch/arm/boot/dts/imx28-cfa10058.dts
+++ b/arch/arm/boot/dts/imx28-cfa10058.dts
@@ -129,7 +129,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
-			phy-reset-gpios = <&gpio2 21 0>;
+			phy-reset-gpios = <&gpio2 21 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-duckbill.dts b/arch/arm/boot/dts/imx28-duckbill.dts
index 5f326c1..b2eb88e 100644
--- a/arch/arm/boot/dts/imx28-duckbill.dts
+++ b/arch/arm/boot/dts/imx28-duckbill.dts
@@ -82,7 +82,7 @@
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
 			phy-supply = <&reg_3p3v>;
-			phy-reset-gpios = <&gpio4 13 0>;
+			phy-reset-gpios = <&gpio4 13 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-evk.dts b/arch/arm/boot/dts/imx28-evk.dts
index e4cc44c..afadd47 100644
--- a/arch/arm/boot/dts/imx28-evk.dts
+++ b/arch/arm/boot/dts/imx28-evk.dts
@@ -264,7 +264,7 @@
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
 			phy-supply = <&reg_fec_3v3>;
-			phy-reset-gpios = <&gpio4 13 0>;
+			phy-reset-gpios = <&gpio4 13 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28-m28cu3.dts b/arch/arm/boot/dts/imx28-m28cu3.dts
index 15f3b39..f960ede 100644
--- a/arch/arm/boot/dts/imx28-m28cu3.dts
+++ b/arch/arm/boot/dts/imx28-m28cu3.dts
@@ -189,7 +189,7 @@
 			phy-mode = "rmii";
 			pinctrl-names = "default";
 			pinctrl-0 = <&mac0_pins_a>;
-			phy-reset-gpios = <&gpio4 13 0>;
+			phy-reset-gpios = <&gpio4 13 GPIO_ACTIVE_LOW>;
 			phy-reset-duration = <100>;
 			status = "okay";
 		};
diff --git a/arch/arm/boot/dts/imx28.dtsi b/arch/arm/boot/dts/imx28.dtsi
index db44a0d..747bb21 100644
--- a/arch/arm/boot/dts/imx28.dtsi
+++ b/arch/arm/boot/dts/imx28.dtsi
@@ -9,6 +9,7 @@
  * http://www.gnu.org/copyleft/gpl.html
  */
 
+#include <dt-bindings/gpio/gpio.h>
 #include "skeleton.dtsi"
 #include "imx28-pinfunc.h"
 
diff --git a/arch/arm/boot/dts/imx50-evk.dts b/arch/arm/boot/dts/imx50-evk.dts
index a859264..1cafdea 100644
--- a/arch/arm/boot/dts/imx50-evk.dts
+++ b/arch/arm/boot/dts/imx50-evk.dts
@@ -54,7 +54,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec>;
 	phy-mode = "rmii";
-	phy-reset-gpios = <&gpio4 12 0>;
+	phy-reset-gpios = <&gpio4 12 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx50.dtsi b/arch/arm/boot/dts/imx50.dtsi
index 01c0499..207b714 100644
--- a/arch/arm/boot/dts/imx50.dtsi
+++ b/arch/arm/boot/dts/imx50.dtsi
@@ -14,6 +14,7 @@
 #include "skeleton.dtsi"
 #include "imx50-pingrp.h"
 #include <dt-bindings/clock/imx5-clock.h>
+#include <dt-bindings/gpio/gpio.h>
 
 / {
 	aliases {
diff --git a/arch/arm/boot/dts/imx53-evk.dts b/arch/arm/boot/dts/imx53-evk.dts
index 214ac2e..82b3773 100644
--- a/arch/arm/boot/dts/imx53-evk.dts
+++ b/arch/arm/boot/dts/imx53-evk.dts
@@ -145,6 +145,6 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec>;
 	phy-mode = "rmii";
-	phy-reset-gpios = <&gpio7 6 0>;
+	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx53-mba53.dts b/arch/arm/boot/dts/imx53-mba53.dts
index 0358366..3a5ec3e 100644
--- a/arch/arm/boot/dts/imx53-mba53.dts
+++ b/arch/arm/boot/dts/imx53-mba53.dts
@@ -183,7 +183,7 @@
 };
 
 &fec {
-	phy-reset-gpios = <&gpio7 6 0>;
+	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx53-qsb.dts b/arch/arm/boot/dts/imx53-qsb.dts
index 4c04459..35334e3 100644
--- a/arch/arm/boot/dts/imx53-qsb.dts
+++ b/arch/arm/boot/dts/imx53-qsb.dts
@@ -338,7 +338,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec>;
 	phy-mode = "rmii";
-	phy-reset-gpios = <&gpio7 6 0>;
+	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx53-smd.dts b/arch/arm/boot/dts/imx53-smd.dts
index e84decf..4d28bbd 100644
--- a/arch/arm/boot/dts/imx53-smd.dts
+++ b/arch/arm/boot/dts/imx53-smd.dts
@@ -217,6 +217,6 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec>;
 	phy-mode = "rmii";
-	phy-reset-gpios = <&gpio7 6 0>;
+	phy-reset-gpios = <&gpio7 6 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
diff --git a/arch/arm/boot/dts/imx53-voipac-dmm-668.dtsi b/arch/arm/boot/dts/imx53-voipac-dmm-668.dtsi
index 04a2895..19a3289 100644
--- a/arch/arm/boot/dts/imx53-voipac-dmm-668.dtsi
+++ b/arch/arm/boot/dts/imx53-voipac-dmm-668.dtsi
@@ -101,7 +101,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_fec>;
 	phy-mode = "rmii";
-	phy-reset-gpios = <&gpio4 2 0>;
+	phy-reset-gpios = <&gpio4 2 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx53.dtsi b/arch/arm/boot/dts/imx53.dtsi
index 90359da..ccf8bb6 100644
--- a/arch/arm/boot/dts/imx53.dtsi
+++ b/arch/arm/boot/dts/imx53.dtsi
@@ -13,6 +13,7 @@
 #include "skeleton.dtsi"
 #include "imx53-pingrp.h"
 #include <dt-bindings/clock/imx5-clock.h>
+#include <dt-bindings/gpio/gpio.h>
 
 / {
 	aliases {
diff --git a/arch/arm/boot/dts/imx6q-dmo-edmqmx6.dts b/arch/arm/boot/dts/imx6q-dmo-edmqmx6.dts
index 84f5143..5791260 100644
--- a/arch/arm/boot/dts/imx6q-dmo-edmqmx6.dts
+++ b/arch/arm/boot/dts/imx6q-dmo-edmqmx6.dts
@@ -64,7 +64,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio3 23 0>;
+	phy-reset-gpios = <&gpio3 23 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6q-gw5400-a.dts b/arch/arm/boot/dts/imx6q-gw5400-a.dts
index 5f76342..18df522 100644
--- a/arch/arm/boot/dts/imx6q-gw5400-a.dts
+++ b/arch/arm/boot/dts/imx6q-gw5400-a.dts
@@ -153,7 +153,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio1 30 0>;
+	phy-reset-gpios = <&gpio1 30 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi b/arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi
index 05b4796..dea52ff 100644
--- a/arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi
+++ b/arch/arm/boot/dts/imx6q-phytec-pfla02.dtsi
@@ -174,7 +174,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio3 23 0>;
+	phy-reset-gpios = <&gpio3 23 GPIO_ACTIVE_LOW>;
 	status = "disabled";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-gw51xx.dtsi b/arch/arm/boot/dts/imx6qdl-gw51xx.dtsi
index fb29da0..7f81df9 100644
--- a/arch/arm/boot/dts/imx6qdl-gw51xx.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-gw51xx.dtsi
@@ -91,7 +91,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio1 30 0>;
+	phy-reset-gpios = <&gpio1 30 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-gw52xx.dtsi b/arch/arm/boot/dts/imx6qdl-gw52xx.dtsi
index a6c77b5..ceb5d43 100644
--- a/arch/arm/boot/dts/imx6qdl-gw52xx.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-gw52xx.dtsi
@@ -138,7 +138,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio1 30 0>;
+	phy-reset-gpios = <&gpio1 30 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-gw53xx.dtsi b/arch/arm/boot/dts/imx6qdl-gw53xx.dtsi
index 35028a5..92506b1 100644
--- a/arch/arm/boot/dts/imx6qdl-gw53xx.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-gw53xx.dtsi
@@ -147,7 +147,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio1 30 0>;
+	phy-reset-gpios = <&gpio1 30 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-gw54xx.dtsi b/arch/arm/boot/dts/imx6qdl-gw54xx.dtsi
index 34b26b9..609d85b 100644
--- a/arch/arm/boot/dts/imx6qdl-gw54xx.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-gw54xx.dtsi
@@ -137,7 +137,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio1 30 0>;
+	phy-reset-gpios = <&gpio1 30 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-microsom-ar8035.dtsi b/arch/arm/boot/dts/imx6qdl-microsom-ar8035.dtsi
index c1be487..f23ed67 100644
--- a/arch/arm/boot/dts/imx6qdl-microsom-ar8035.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-microsom-ar8035.dtsi
@@ -16,7 +16,7 @@
 	pinctrl-0 = <&pinctrl_microsom_enet_ar8035>;
 	phy-mode = "rgmii";
 	phy-reset-duration = <2>;
-	phy-reset-gpios = <&gpio4 15 0>;
+	phy-reset-gpios = <&gpio4 15 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
index e83ffc7..d75dc0d 100644
--- a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
@@ -152,7 +152,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio1 27 0>;
+	phy-reset-gpios = <&gpio1 27 GPIO_ACTIVE_LOW>;
 	txen-skew-ps = <0>;
 	txc-skew-ps = <3000>;
 	rxdv-skew-ps = <0>;
diff --git a/arch/arm/boot/dts/imx6qdl-sabresd.dtsi b/arch/arm/boot/dts/imx6qdl-sabresd.dtsi
index 91e5dd4..10b912b 100644
--- a/arch/arm/boot/dts/imx6qdl-sabresd.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-sabresd.dtsi
@@ -132,7 +132,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio1 25 0>;
+	phy-reset-gpios = <&gpio1 25 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl-wandboard.dtsi b/arch/arm/boot/dts/imx6qdl-wandboard.dtsi
index 88894b1..c290017 100644
--- a/arch/arm/boot/dts/imx6qdl-wandboard.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-wandboard.dtsi
@@ -142,7 +142,7 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
 	phy-mode = "rgmii";
-	phy-reset-gpios = <&gpio3 29 0>;
+	phy-reset-gpios = <&gpio3 29 GPIO_ACTIVE_LOW>;
 	status = "okay";
 };
 
diff --git a/arch/arm/boot/dts/imx6qdl.dtsi b/arch/arm/boot/dts/imx6qdl.dtsi
index 8948016..ac948fc 100644
--- a/arch/arm/boot/dts/imx6qdl.dtsi
+++ b/arch/arm/boot/dts/imx6qdl.dtsi
@@ -10,6 +10,7 @@
  * http://www.gnu.org/copyleft/gpl.html
  */
 
+#include <dt-bindings/gpio/gpio.h>
 #include "skeleton.dtsi"
 
 / {
-- 
1.8.1.2

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

end of thread, other threads:[~2014-01-06 12:43 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-03 11:55 [PATCH] ARM: imx: Explicitly pass the active level of the PHY reset Fabio Estevam
2014-01-03 12:07 ` Shawn Guo
2014-01-04  5:47   ` Olof Johansson
2014-01-05 17:29     ` Olof Johansson
2014-01-06  2:24       ` Shawn Guo
2014-01-06  2:43         ` Olof Johansson
2014-01-06 11:14         ` Russell King - ARM Linux
2014-01-06 12:43           ` Shawn Guo
  -- strict thread matches above, loose matches on Subject: below --
2014-01-03  2:14 Fabio Estevam
2014-01-03  3:22 ` Shawn Guo
2014-01-03  3:28   ` Fabio Estevam
2014-01-03  4:15     ` Shawn Guo
2014-01-03 11:21       ` Fabio Estevam

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).