Skip to content
Commit 389c0ad1 authored by Guenter Roeck's avatar Guenter Roeck Committed by Eduardo Valentin
Browse files

hwmon: (aspeed-pwm-tacho) Use devm_thermal_of_cooling_device_register



Use devm_thermal_of_cooling_device_register() to register the cooling
device. As a side effect, this fixes a driver bug:
thermal_cooling_device_unregister() was not called on removal.

Fixes: f198907d ("hwmon: (aspeed-pwm-tacho) cooling device support.")
Cc: Mykola Kostenok <c_mykolak@mellanox.com>
Cc: Joel Stanley <joel@jms.id.au>
Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
Reviewed-by: default avatarPatrick Venture <venture@google.com>
Signed-off-by: default avatarEduardo Valentin <edubezval@gmail.com>
parent e380ea81
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment