From 5720a18baa4686d56d0a235e6ecbcc55f8d716d7 Mon Sep 17 00:00:00 2001 From: Guenter Roeck Date: Thu, 16 Feb 2023 11:34:19 -0800 Subject: hwmon: Deprecate [devm_]hwmon_device_register_with_groups Even though the hardware monitoring documentation already stated that new drivers should use [devm_]devm_hwmon_device_register_with_info() to register with the hardware monitoring subsystem, we still get submissions for new drivers using the older APIs. There is no benefit to use those APIs. On the contrary, using the older APIs results in substantially larger code size. Explicitly deprecate [devm_]hwmon_device_register_with_groups() to ensure that all new drivers use the latest API. Signed-off-by: Guenter Roeck --- include/linux/hwmon.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'include/linux/hwmon.h') diff --git a/include/linux/hwmon.h b/include/linux/hwmon.h index 14325f93c6b2..c1b62384b6ee 100644 --- a/include/linux/hwmon.h +++ b/include/linux/hwmon.h @@ -436,6 +436,10 @@ struct hwmon_chip_info { /* hwmon_device_register() is deprecated */ struct device *hwmon_device_register(struct device *dev); +/* + * hwmon_device_register_with_groups() and + * devm_hwmon_device_register_with_groups() are deprecated. + */ struct device * hwmon_device_register_with_groups(struct device *dev, const char *name, void *drvdata, -- cgit v1.2.3-59-g8ed1b