]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
kernel: kmod-backlight-pwm/kmod-hwmon-pwmfan: Depend on PWM_SUPPORT
authorHauke Mehrtens <hauke@hauke-m.de>
Sun, 20 Jul 2025 16:24:45 +0000 (18:24 +0200)
committerHauke Mehrtens <hauke@hauke-m.de>
Fri, 25 Jul 2025 23:11:20 +0000 (01:11 +0200)
These drivers depend on the kernel option CONFIG_PWM, only add them to
OpenWrt for targets which have PWM support.

Link: https://github.com/openwrt/openwrt/pull/19480
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
package/kernel/linux/modules/hwmon.mk
package/kernel/linux/modules/video.mk

index 8e222434819408248bc55bbaca2b4aa6857b8651..21c522edcddee1a0900e2d80ced2ceff9ddd443e 100644 (file)
@@ -529,7 +529,7 @@ define KernelPackage/hwmon-pwmfan
   KCONFIG:=CONFIG_SENSORS_PWM_FAN
   FILES:=$(LINUX_DIR)/drivers/hwmon/pwm-fan.ko
   AUTOLOAD:=$(call AutoLoad,60,pwm-fan)
-  $(call AddDepends/hwmon, +PACKAGE_kmod-thermal:kmod-thermal)
+  $(call AddDepends/hwmon,@PWM_SUPPORT +PACKAGE_kmod-thermal:kmod-thermal)
 endef
 
 define KernelPackage/hwmon-pwmfan/description
index 9472c67b807ab99ac7b5ad61d0749c4b35e2ff43..a024ac0fed5799f292359714a4c0e17f8c0f7a0a 100644 (file)
@@ -86,7 +86,7 @@ $(eval $(call KernelPackage,backlight))
 define KernelPackage/backlight-pwm
        SUBMENU:=$(VIDEO_MENU)
        TITLE:=PWM Backlight support
-       DEPENDS:=+kmod-backlight
+       DEPENDS:=@PWM_SUPPORT +kmod-backlight
        KCONFIG:=CONFIG_BACKLIGHT_PWM
        FILES:=$(LINUX_DIR)/drivers/video/backlight/pwm_bl.ko
        AUTOLOAD:=$(call AutoProbe,video pwm_bl)