diff options
author | Axel Lin <axel.lin@gmail.com> | 2010-10-20 04:56:59 -0400 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2010-10-28 18:30:34 -0400 |
commit | 8220fe4cb25d0177bd0795a516d2023799008ca0 (patch) | |
tree | a6b2980984826b2540d3c7fa076da53c080a977e /drivers | |
parent | bf56f0a6668cd399b5136d2216f24ec97f0ce716 (diff) |
mfd: Fix resource reclaim in pcf50633_remove()
Calling sysfs_remove_group() to remove sysfs entries
and unregister bl_pdev in pcf50633_remove().
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Harald Welte <laforge@gnumonks.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/mfd/pcf50633-core.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/mfd/pcf50633-core.c b/drivers/mfd/pcf50633-core.c index 6d4233f0d0d3..501ce13b693e 100644 --- a/drivers/mfd/pcf50633-core.c +++ b/drivers/mfd/pcf50633-core.c | |||
@@ -339,12 +339,14 @@ static int __devexit pcf50633_remove(struct i2c_client *client) | |||
339 | struct pcf50633 *pcf = i2c_get_clientdata(client); | 339 | struct pcf50633 *pcf = i2c_get_clientdata(client); |
340 | int i; | 340 | int i; |
341 | 341 | ||
342 | sysfs_remove_group(&client->dev.kobj, &pcf_attr_group); | ||
342 | pcf50633_irq_free(pcf); | 343 | pcf50633_irq_free(pcf); |
343 | 344 | ||
344 | platform_device_unregister(pcf->input_pdev); | 345 | platform_device_unregister(pcf->input_pdev); |
345 | platform_device_unregister(pcf->rtc_pdev); | 346 | platform_device_unregister(pcf->rtc_pdev); |
346 | platform_device_unregister(pcf->mbc_pdev); | 347 | platform_device_unregister(pcf->mbc_pdev); |
347 | platform_device_unregister(pcf->adc_pdev); | 348 | platform_device_unregister(pcf->adc_pdev); |
349 | platform_device_unregister(pcf->bl_pdev); | ||
348 | 350 | ||
349 | for (i = 0; i < PCF50633_NUM_REGULATORS; i++) | 351 | for (i = 0; i < PCF50633_NUM_REGULATORS; i++) |
350 | platform_device_unregister(pcf->regulator_pdev[i]); | 352 | platform_device_unregister(pcf->regulator_pdev[i]); |