Skip to content

Commit feddb41

Browse files
committed
drivers: ksz8081: fix reset pin polarity
The reset pin, like most reset pins, is active low. Fix the driver to treat it as active low and simplify the pin control logic while at it. Fix all current boards using the wrong pin definition and add a note for out of tree users. Signed-off-by: Fabio Baltieri <[email protected]>
1 parent 75ff93a commit feddb41

File tree

11 files changed

+16
-34
lines changed

11 files changed

+16
-34
lines changed

boards/nxp/frdm_rw612/frdm_rw612_common.dtsi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ mikrobus_serial: &flexcomm0 {};
232232
compatible = "microchip,ksz8081";
233233
reg = <2>;
234234
status = "okay";
235-
reset-gpios = <&hsgpio1 23 GPIO_ACTIVE_HIGH>;
235+
reset-gpios = <&hsgpio1 23 GPIO_ACTIVE_LOW>;
236236
int-gpios = <&hsgpio0 21 GPIO_ACTIVE_HIGH>;
237237
microchip,interface-type = "rmii";
238238
};

boards/nxp/mimxrt1020_evk/mimxrt1020_evk.dts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ arduino_serial: &lpuart2 {
160160
compatible = "microchip,ksz8081";
161161
reg = <0>;
162162
status = "okay";
163-
reset-gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>;
163+
reset-gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
164164
int-gpios = <&gpio1 22 GPIO_ACTIVE_HIGH>;
165165
microchip,interface-type = "rmii";
166166
};

boards/nxp/mimxrt1024_evk/mimxrt1024_evk.dts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ arduino_serial: &lpuart2 {
152152
compatible = "microchip,ksz8081";
153153
reg = <0>;
154154
status = "okay";
155-
reset-gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>;
155+
reset-gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
156156
int-gpios = <&gpio1 22 GPIO_ACTIVE_HIGH>;
157157
microchip,interface-type = "rmii";
158158
};

boards/nxp/mimxrt1050_evk/mimxrt1050_evk.dtsi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ zephyr_lcdif: &lcdif {
200200
compatible = "microchip,ksz8081";
201201
reg = <0>;
202202
status = "okay";
203-
reset-gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
203+
reset-gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
204204
int-gpios = <&gpio1 10 GPIO_ACTIVE_HIGH>;
205205
microchip,interface-type = "rmii";
206206
};

boards/nxp/mimxrt1060_evk/mimxrt1060_evk.dtsi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ arduino_i2c: &lpi2c1 {
178178
compatible = "microchip,ksz8081";
179179
reg = <0>;
180180
status = "okay";
181-
reset-gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
181+
reset-gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
182182
int-gpios = <&gpio1 10 GPIO_ACTIVE_HIGH>;
183183
microchip,interface-type = "rmii";
184184
};

boards/nxp/mimxrt1064_evk/mimxrt1064_evk.dts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ arduino_serial: &lpuart3 {
244244
compatible = "microchip,ksz8081";
245245
reg = <0>;
246246
status = "okay";
247-
reset-gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
247+
reset-gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
248248
int-gpios = <&gpio1 10 GPIO_ACTIVE_HIGH>;
249249
microchip,interface-type = "rmii";
250250
};

boards/nxp/mimxrt1160_evk/mimxrt1160_evk.dtsi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@
160160
compatible = "microchip,ksz8081";
161161
reg = <0>;
162162
status = "okay";
163-
reset-gpios = <&gpio12 12 GPIO_ACTIVE_HIGH>;
163+
reset-gpios = <&gpio12 12 GPIO_ACTIVE_LOW>;
164164
int-gpios = <&gpio9 11 GPIO_ACTIVE_HIGH>;
165165
microchip,interface-type = "rmii";
166166
};

boards/nxp/mimxrt1170_evk/mimxrt1170_evk.dtsi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ arduino_serial: &lpuart2 {
154154
compatible = "microchip,ksz8081";
155155
reg = <0>;
156156
status = "okay";
157-
reset-gpios = <&gpio12 12 GPIO_ACTIVE_HIGH>;
157+
reset-gpios = <&gpio12 12 GPIO_ACTIVE_LOW>;
158158
int-gpios = <&gpio9 11 GPIO_ACTIVE_HIGH>;
159159
microchip,interface-type = "rmii";
160160
};

boards/nxp/rd_rw612_bga/rd_rw612_bga_rw612_ethernet.dts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
compatible = "microchip,ksz8081";
3434
reg = <2>;
3535
status = "okay";
36-
reset-gpios = <&hsgpio1 23 GPIO_ACTIVE_HIGH>;
36+
reset-gpios = <&hsgpio1 23 GPIO_ACTIVE_LOW>;
3737
int-gpios = <&hsgpio0 21 GPIO_ACTIVE_HIGH>;
3838
microchip,interface-type = "rmii";
3939
};

doc/releases/migration-guide-4.4.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,10 @@ Ethernet
6060
is needed. There you need to specify the fixed link parameters using the ``default-speeds``
6161
property (:github:`100454`).
6262

63+
* The ``reset-gpios`` property of :dtcompatible:`microchip,ksz8081` has been
64+
reworked to be used as active low, you may have to set the pin as
65+
``GPIO_ACTIVE_LOW`` in devicetree (:github:`100751`).
66+
6367
MDIO
6468
====
6569

0 commit comments

Comments
 (0)