apm821xx: add drivetemp sensor for the WD MyBook Series
authorChristian Lamparter <chunkeey@gmail.com>
Sat, 21 Mar 2020 19:58:16 +0000 (20:58 +0100)
committerChristian Lamparter <chunkeey@gmail.com>
Sun, 22 Mar 2020 22:02:09 +0000 (23:02 +0100)
This patch adds the hwmon-drivetemp to the device.
It also adds device-tree bindings. This can be useful to
automate external fans which can be controlled for example
by either an unused sata-port or by the usb-power regulator.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
target/linux/apm821xx/dts/wd-mybooklive.dts
target/linux/apm821xx/sata/target.mk

index 6cba7d2f26dd05c7d41edfcd5a45acc52f82e03c..82e9497ecdb15192f35cbd2b8bfc9d983b46d329 100644 (file)
 
 &SATA0 {
        status = "okay";
+
+       drive0: sata-port@0 {
+               reg = <0>;
+               #thermal-sensor-cells = <0>;
+       };
 };
 
 &SATA1 {
        status = "okay";
+
+       drive1: sata-port@0 {
+               reg = <0>;
+               #thermal-sensor-cells = <0>;
+       };
 };
 
 &UART0 {
index 790746c4800b4792c8093581c1a4cd83cc329b33..d3af6ef82105e6edfb419725c629ce2b8229ddd8 100644 (file)
@@ -1,6 +1,6 @@
 BOARDNAME := Devices which boot from SATA (NAS)
 FEATURES += ext4 usb ramdisk squashfs rootfs-part boot-part
-DEFAULT_PACKAGES += badblocks block-mount e2fsprogs \
+DEFAULT_PACKAGES += badblocks block-mount e2fsprogs kmod-hwmon-drivetemp \
                    kmod-dm kmod-md-mod partx-utils mkf2fs f2fsck
 
 define Target/Description