Searched hist:e782bc169cd02d3411a6db6ff0c26d7f27f8b81a (Results 1 – 1 of 1) sorted by relevance
/linux/drivers/thermal/ |
H A D | thermal_hwmon.c | diff e782bc169cd02d3411a6db6ff0c26d7f27f8b81a Sat Jan 13 15:08:49 CET 2018 Fabio Estevam <fabio.estevam@nxp.com> thermal: thermal_hwmon: Convert to hwmon_device_register_with_info()
Booting Linux on a mx6q based board leads to the following warning:
(NULL device *): hwmon_device_register() is deprecated. Please convert the driver to use hwmon_device_register_with_info().
, so do the conversion as suggested.
Also, this results in the core taking care of creating the 'name' attribute, so drop the code doing that from the thermal driver.
The initial attempt to convert this driver to hwmon_device_register_with_info() caused issues on the N900 platform in commit 7611fb68062f ("thermal: thermal_hwmon: Convert to hwmon_device_register_with_info()"):
bq27xxx-battery 2-0055: failed to register battery bq27xxx-battery: probe of 2-0055 failed with error -22 ... rx51-battery: probe of n900-battery failed with error -22
, leading to a revert in commit 3feb479cea37 ("Revert "thermal: thermal_hwmon: Convert to hwmon_device_register_with_info()"").
The probe errors happened due to the '-' character being present in the name of the power supply devices: bq27200-0 and rx51-battery.
Since commit 74d3b6419772 ("hwmon: Relax name attribute validation for new APIs") hwmon will no longer treat these names as errors, allowing the transition for hwmon_device_register_with_info() to happen in a safely manner.
Cc: Pavel Machek <pavel@ucw.cz> Cc: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Acked-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Zhang Rui <rui.zhang@intel.com>
|