public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] media: marvell-ccic: drop resource free in driver remove
@ 2013-11-05  3:21 lbyang
  2013-11-05 16:07 ` Jonathan Corbet
  0 siblings, 1 reply; 2+ messages in thread
From: lbyang @ 2013-11-05  3:21 UTC (permalink / raw)
  To: corbet; +Cc: linux-media

From: Libin Yang <lbyang@marvell.com>
Date: Tue, 5 Nov 2013 10:18:15 +0800
Subject: [PATCH] marvell-ccic: drop resource free in driver remove

The mmp-driver is using devm_* to allocate the resource. The old
resource release methods are not appropriate here.

Signed-off-by: Libin Yang <lbyang@marvell.com>
---
 drivers/media/platform/marvell-ccic/mmp-driver.c |    7 -------
 1 file changed, 7 deletions(-)

diff --git a/drivers/media/platform/marvell-ccic/mmp-driver.c
b/drivers/media/platform/marvell-ccic/mmp-driver.c
index 3458fa0..70cb57f 100644
--- a/drivers/media/platform/marvell-ccic/mmp-driver.c
+++ b/drivers/media/platform/marvell-ccic/mmp-driver.c
@@ -478,18 +478,11 @@ out_deinit_clk:
 static int mmpcam_remove(struct mmp_camera *cam)
 {
 	struct mcam_camera *mcam = &cam->mcam;
-	struct mmp_camera_platform_data *pdata;
 
 	mmpcam_remove_device(cam);
 	mccic_shutdown(mcam);
 	mmpcam_power_down(mcam);
-	pdata = cam->pdev->dev.platform_data;
-	gpio_free(pdata->sensor_reset_gpio);
-	gpio_free(pdata->sensor_power_gpio);
 	mcam_deinit_clk(mcam);
-	iounmap(cam->power_regs);
-	iounmap(mcam->regs);
-	kfree(cam);
 	return 0;
 }
 
-- 
1.7.9.5






^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] media: marvell-ccic: drop resource free in driver remove
  2013-11-05  3:21 [PATCH] media: marvell-ccic: drop resource free in driver remove lbyang
@ 2013-11-05 16:07 ` Jonathan Corbet
  0 siblings, 0 replies; 2+ messages in thread
From: Jonathan Corbet @ 2013-11-05 16:07 UTC (permalink / raw)
  To: lbyang; +Cc: linux-media

On Tue, 5 Nov 2013 11:21:08 +0800
lbyang <lbyang@marvell.com> wrote:

> From: Libin Yang <lbyang@marvell.com>
> Date: Tue, 5 Nov 2013 10:18:15 +0800
> Subject: [PATCH] marvell-ccic: drop resource free in driver remove
> 
> The mmp-driver is using devm_* to allocate the resource. The old
> resource release methods are not appropriate here.

Acked-by: Jonathan Corbet <corbet@lwn.net>

jon

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-11-05 16:07 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-11-05  3:21 [PATCH] media: marvell-ccic: drop resource free in driver remove lbyang
2013-11-05 16:07 ` Jonathan Corbet

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox