realtek: EnGenius EWS2910P: declare and hog the poe-enable GPIO
authorAlexandru Gagniuc <mr.nuke.me@gmail.com>
Sun, 22 May 2022 02:59:10 +0000 (21:59 -0500)
committerSander Vanheule <sander@svanheule.net>
Sat, 2 Jul 2022 09:50:47 +0000 (11:50 +0200)
GPIO 1 on the RTL8231 is used to force the PoE MCU to disable power
outputs. It is not used by any driver, but if accidentally set low,
PoE outputs are disabled. This situation is hard to debug, and
requires knowledge of the Broadcom PoE protocol used by the MCU.

To prevent this situation, hog it as an output high. This is
consistent with the ZyXel GS1900 series handles it.

Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com>
target/linux/realtek/dts-5.10/rtl8380_engenius_ews2910p.dts

index f87c9585f9d30384508044c1f3c4dc4a2cb3b9ea..dd57b2bf48602559b74a44b3a2524a9b5ab7c230 100644 (file)
                gpio-controller;
                indirect-access-bus-id = <0>;
 
+               poe_enable {
+                       gpio-hog;
+                       gpios = <1 GPIO_ACTIVE_HIGH>;
+                       output-high;
+                       line-name = "poe-enable";
+               };
+
                sff_p9_gpios {
                        gpio-hog;
                        gpios = < 6 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>,