2022-07-19 20:16:21

by Horatiu Vultur

[permalink] [raw]
Subject: [PATCH v2 0/3] ARM: dts: lan966x: Extend pcb8291

Extend pcb8291 with different features like, add support to reset the board
using GPIO and add network support.

v1->v2:
- instead of removing the can0 node, just disable and add a comment
- reorder the nodes to be alphabetical

Horatiu Vultur (3):
ARM: dts: lan966x: Add gpio-restart
ARM: dts: lan966x: Disable can0 on pcb8291
ARM: dts: lan966x: Enable network driver on pcb8291

arch/arm/boot/dts/lan966x-pcb8291.dts | 43 ++++++++++++++++++++++++++-
1 file changed, 42 insertions(+), 1 deletion(-)

--
2.33.0


2022-07-19 20:16:34

by Horatiu Vultur

[permalink] [raw]
Subject: [PATCH v2 3/3] ARM: dts: lan966x: Enable network driver on pcb8291

The pcb8291 has 2 ports that are connected to the internal ports
of the switch. Enable them in DT.

Signed-off-by: Horatiu Vultur <[email protected]>
---
arch/arm/boot/dts/lan966x-pcb8291.dts | 35 +++++++++++++++++++++++++++
1 file changed, 35 insertions(+)

diff --git a/arch/arm/boot/dts/lan966x-pcb8291.dts b/arch/arm/boot/dts/lan966x-pcb8291.dts
index ab80558de259..228ae16e4737 100644
--- a/arch/arm/boot/dts/lan966x-pcb8291.dts
+++ b/arch/arm/boot/dts/lan966x-pcb8291.dts
@@ -4,6 +4,7 @@
*/
/dts-v1/;
#include "lan966x.dtsi"
+#include "dt-bindings/phy/phy-lan966x-serdes.h"

/ {
model = "Microchip EVB - LAN9662";
@@ -55,6 +56,40 @@ usart3: serial@200 {
};
};

+&mdio1 {
+ status = "okay";
+};
+
+&phy0 {
+ status = "okay";
+};
+
+&phy1 {
+ status = "okay";
+};
+
+&port0 {
+ status = "okay";
+ phy-handle = <&phy0>;
+ phy-mode = "gmii";
+ phys = <&serdes 0 CU(0)>;
+};
+
+&port1 {
+ status = "okay";
+ phy-handle = <&phy1>;
+ phy-mode = "gmii";
+ phys = <&serdes 1 CU(1)>;
+};
+
+&serdes {
+ status = "okay";
+};
+
+&switch {
+ status = "okay";
+};
+
&watchdog {
status = "okay";
};
--
2.33.0

2022-07-19 20:30:17

by Horatiu Vultur

[permalink] [raw]
Subject: [PATCH v2 1/3] ARM: dts: lan966x: Add gpio-restart

The pcb8291 can be rebooted by toggling the GPIO 56. Therefore enable
this in DT.

Signed-off-by: Horatiu Vultur <[email protected]>
---
arch/arm/boot/dts/lan966x-pcb8291.dts | 6 ++++++
1 file changed, 6 insertions(+)

diff --git a/arch/arm/boot/dts/lan966x-pcb8291.dts b/arch/arm/boot/dts/lan966x-pcb8291.dts
index d56d2054c38d..02fbf7371a8d 100644
--- a/arch/arm/boot/dts/lan966x-pcb8291.dts
+++ b/arch/arm/boot/dts/lan966x-pcb8291.dts
@@ -16,6 +16,12 @@ chosen {
aliases {
serial0 = &usart3;
};
+
+ gpio-restart {
+ compatible = "gpio-restart";
+ gpios = <&gpio 56 GPIO_ACTIVE_LOW>;
+ priority = <200>;
+ };
};

&gpio {
--
2.33.0