]> git.baikalelectronics.ru Git - kernel.git/commit
hwmon: (tmp102) Use devm_add_action to register cleanup function
authorGuenter Roeck <linux@roeck-us.net>
Mon, 20 Jun 2016 03:09:54 +0000 (20:09 -0700)
committerGuenter Roeck <linux@roeck-us.net>
Tue, 28 Jun 2016 01:58:31 +0000 (18:58 -0700)
commit368409acd4b8a03957e3a93da1f8780cace7986e
tree821d25a5ed827c25af9f329637ffb7f899521f0e
parentaec7d07359c0138fdc8ffd9a6fc18654e7d6b4d3
hwmon: (tmp102) Use devm_add_action to register cleanup function

By registering a cleanup function with devm_add_action(), we can
simplify the error path in the probe function and drop the remove
function entirely.

Acked-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/tmp102.c