realtek: HPE 1920 8G PoE+ 180W move fans to hwmon
authorEvan Jobling <evan@jobling.au>
Tue, 14 Jan 2025 12:13:21 +0000 (12:13 +0000)
committerSander Vanheule <sander@svanheule.net>
Wed, 15 Jan 2025 07:21:08 +0000 (08:21 +0100)
commitf64541db020ef5689186609e8b7b7a3bb9755160
tree026f5df127532cacb00563ecb8a0dbbf32b3f921
parentc9ebd4fb30773ca55cc2da6b2c1962046a2e0fff
realtek: HPE 1920 8G PoE+ 180W move fans to hwmon

The GPIO numbering has changed and is not stable. As a result fan
control via gpio_switch is broken, resulting in errors:
    "export_store: invalid GPIO 456"

Move to using hwmon and gpio-fan. This is by adding gpio_fan_array to
DTS and kmod-hwmon-gpiofan to DEVICE_PACKAGES.

In combination with the new rtl8231 gpio driver the default fan
behaviour will be maximum fan speed.

Bump compat value to 1.1 due to existing config in /etc/config/system
via gpio_switch. Also notify in device compat that fan is now going to
be at bootloader setting (maximum in this case) by default unless turned
down.

Signed-off-by: Evan Jobling <evan@jobling.au>
Link: https://github.com/openwrt/openwrt/pull/17605
Signed-off-by: Sander Vanheule <sander@svanheule.net>
target/linux/realtek/base-files/etc/board.d/03_gpio_switches
target/linux/realtek/base-files/etc/board.d/05_compat-version
target/linux/realtek/dts/rtl8380_hpe_1920-8g-poe-180w.dts
target/linux/realtek/image/common.mk
target/linux/realtek/image/rtl838x.mk