thermal: core: Add some new helper functions to free resources
authorChristophe Jaillet <christophe.jaillet@wanadoo.fr>
Tue, 8 Aug 2017 14:39:52 +0000 (16:39 +0200)
committerZhang Rui <rui.zhang@intel.com>
Fri, 11 Aug 2017 03:33:49 +0000 (11:33 +0800)
commit32fa5ba3171116a5501e60245dc97e82fe3cf267
treed5d3cae080986bd116c9497b5d80f0cdca8fd452
parent039f6cf5b5566b92fae8d31924b1d59365798abb
thermal: core: Add some new helper functions to free resources

In order to easily free resources allocated by
'thermal_zone_create_device_groups()' we need 2 new helper functions.

The first one undoes 'thermal_zone_create_device_groups()'.
The 2nd one undoes 'create_trip_attrs()', which is a function called by
'thermal_zone_create_device_groups()'.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
drivers/thermal/thermal_core.h
drivers/thermal/thermal_sysfs.c