mvebu: LS421DE: add linkstation poweroff driver
authorDaniel González Cabanelas <dgcbueu@gmail.com>
Fri, 28 Aug 2020 09:20:46 +0000 (11:20 +0200)
committerDaniel Golle <daniel@makrotopia.org>
Fri, 28 Aug 2020 09:44:29 +0000 (10:44 +0100)
Compile the Linkstation poweroff module for the Buffalo LS421DE.
Without this driver the device remains forever halted if a power off
command is executed.

The driver will also allow to use the WoL feature, which wasn't availabe
in the stock firmware.

Signed-off-by: Daniel González Cabanelas <dgcbueu@gmail.com>
target/linux/mvebu/files/arch/arm/boot/dts/armada-370-buffalo-ls421de.dts
target/linux/mvebu/image/cortexa9.mk

index ea392f9e415b4fda3a3983b1e9900059612c680d..e0c0cb55a086e9043c26a83f3400b1efd006caea 100644 (file)
                        gpio = <&gpio0 9 GPIO_ACTIVE_HIGH>;
                };
        };
-
-       /* FIXME: this driver needs to be aware of the LED2 eth phy use,
-          which must be set to off state before shutting down the machine */
-       restart_poweroff {
-               compatible = "restart-poweroff";
-       };
 };
 
 &eth1 {
 
        ethphy0: ethernet-phy@0 { /* Marvell 88E1518 */
                reg = <0>;
-               /*
-                * LED2 is used to inform, at restart time, if the power
-                * switch was slided to the "off" position.
-                * Page 0x3, Register 0x10, bits 8-11:
-                *     0x800: LED2 off, power off the machine
-                *     0x900: LED2 on, boot the machine
-                */
                marvell,reg-init = <0x3 0x10 0x1 0x1991>, /* LED function */
                                   <0x3 0x11 0x1 0x4401>, /* LED polarity */
                                   <0x3 0x12 0x1 0x4905>; /* LED timer */
index 7c2069ed2f6bb30941da9fabfae03233b1f07235..824f142a8b3f142eb40abd782a1acf4cd7f50570 100644 (file)
@@ -24,8 +24,8 @@ define Device/buffalo_ls421de
   DEVICE_DTS := armada-370-buffalo-ls421de
   DEVICE_PACKAGES :=  \
     kmod-rtc-rs5c372a kmod-hwmon-gpiofan kmod-hwmon-drivetemp kmod-usb3 \
-    kmod-md-raid0 kmod-md-raid1 kmod-md-mod kmod-fs-xfs mkf2fs e2fsprogs \
-    partx-utils
+    kmod-linkstation-poweroff kmod-md-raid0 kmod-md-raid1 kmod-md-mod \
+    kmod-fs-xfs mkf2fs e2fsprogs partx-utils
 endef
 TARGET_DEVICES += buffalo_ls421de