diff mbox

[03/50] drm/imx: directly call drm_put_dev in ->remove

Message ID 1386758111-3446-4-git-send-email-daniel.vetter@ffwll.ch
State Accepted
Headers show

Commit Message

Daniel Vetter Dec. 11, 2013, 10:34 a.m. UTC
Again no apparent user of the driver data field.

Cc: Sascha Hauer <s.hauer@pengutronix.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Acked-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 drivers/staging/imx-drm/imx-drm-core.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/drivers/staging/imx-drm/imx-drm-core.c b/drivers/staging/imx-drm/imx-drm-core.c
index 51aa9772f959..dfd8a79032dd 100644
--- a/drivers/staging/imx-drm/imx-drm-core.c
+++ b/drivers/staging/imx-drm/imx-drm-core.c
@@ -443,6 +443,8 @@  static int imx_drm_driver_load(struct drm_device *drm, unsigned long flags)
 	if (!imx_drm_device_get())
 		ret = -EINVAL;
 
+	platform_set_drvdata(drm->platformdev, drm);
+
 	ret = 0;
 
 err_init:
@@ -828,7 +830,7 @@  static int imx_drm_platform_probe(struct platform_device *pdev)
 
 static int imx_drm_platform_remove(struct platform_device *pdev)
 {
-	drm_platform_exit(&imx_drm_driver, pdev);
+	drm_put_dev(platform_get_drvdata(pdev));
 
 	return 0;
 }