summaryrefslogtreecommitdiff
path: root/drivers/thermal
diff options
context:
space:
mode:
authorLaxman Dewangan <ldewangan@nvidia.com>2014-04-23 15:40:04 +0530
committerRiham Haidar <rhaidar@nvidia.com>2014-05-05 14:12:02 -0700
commit9ceb76f2cf55752bd7e69e1b7a3dd490872edb80 (patch)
treeeeda00eca899aa3b7aad4eb135cb778194630232 /drivers/thermal
parentbed28ce105ba81dabf4fd295ca3754f83cb62018 (diff)
thermal: palmas: no need to free devm_ memory on remove
It is not required to free the memory which is allocated using devm_. The device framework take care or releasing the memory. Change-Id: I40d4815d4ae1385ad3715421b505bec227e3d1b1 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/400355 Reviewed-on: http://git-master/r/405009 GVS: Gerrit_Virtual_Submit
Diffstat (limited to 'drivers/thermal')
-rw-r--r--drivers/thermal/palmas_thermal.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/thermal/palmas_thermal.c b/drivers/thermal/palmas_thermal.c
index 72acaf411c42..96a160a611ea 100644
--- a/drivers/thermal/palmas_thermal.c
+++ b/drivers/thermal/palmas_thermal.c
@@ -225,9 +225,8 @@ static int palmas_thermal_remove(struct platform_device *pdev)
{
struct palmas_therm_zone *ptherm_zone = platform_get_drvdata(pdev);
- thermal_zone_device_unregister(ptherm_zone->tz_device);
free_irq(ptherm_zone->irq, ptherm_zone);
- kfree(ptherm_zone);
+ thermal_zone_device_unregister(ptherm_zone->tz_device);
return 0;
}