Skip to contentSkip to conversation

sensors: fix build of pwm-fan.c when THERMAL=m

PATCH Applied Randy Dunlap 2 participants 2 messages Mar 5, 2015 – Mar 6, 2015 Hardware monitoring

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 sensors: fix build of pwm-fan.c when THERMAL=m

From: Randy Dunlap <[email protected]>

Fix build errors when CONFIG_THERMAL=m and SENSORS_PWM_FAN=y by restricting SENSORS_PWM_FAN to 'm' when THERMAL=m.

drivers/built-in.o: In function `pwm_fan_remove':
pwm-fan.c:(.text+0x22ba58): undefined reference to thermal_cooling_device_unregister' drivers/built-in.o: In function pwm_fan_probe':
pwm-fan.c:(.text+0x22bebb): undefined reference to thermal_of_cooling_device_register' pwm-fan.c:(.text+0x22bf11): undefined reference to thermal_cdev_update'

---
 drivers/hwmon/Kconfig |    1 +
 1 file changed, 1 insertion(+)
drivers/hwmon/Kconfig +1 -0
@@ -1174,6 +1174,7 @@ source drivers/hwmon/pmbus/Kconfig
 config SENSORS_PWM_FAN
 	tristate "PWM fan"
 	depends on (PWM && OF) || COMPILE_TEST
+	depends on THERMAL || THERMAL=n
 	help
 	  If you say yes here you get support for fans connected to PWM lines.
 	  The driver uses the generic PWM interface, thus it will work on a

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

maintainer Applied
#1 lore raw
Quoted 11 lines · Randy Dunlap

From: Randy Dunlap <[email protected]>

Fix build errors when CONFIG_THERMAL=m and SENSORS_PWM_FAN=y by restricting SENSORS_PWM_FAN to 'm' when THERMAL=m.

drivers/built-in.o: In function `pwm_fan_remove':
pwm-fan.c:(.text+0x22ba58): undefined reference to thermal_cooling_device_unregister' drivers/built-in.o: In function pwm_fan_probe':
pwm-fan.c:(.text+0x22bebb): undefined reference to thermal_of_cooling_device_register' pwm-fan.c:(.text+0x22bf11): undefined reference to thermal_cdev_update'

Quoted 3 lines

---

Applied, thanks.

Guenter

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors