Skip to content

Commit

Permalink
drm/hisilicon: Make kirin_drm_unbind sufficient
Browse files Browse the repository at this point in the history
Remove deprecated drm_put_dev.
Clean up everything needed in unbind.
Thanks to Daniel Vetter, this issue is reported by him.

Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reported-by: Daniel Vetter <daniel.vetter@intel.com>
Signed-off-by: Xinliang Liu <xinliang.liu@linaro.org>
  • Loading branch information
Xinliang Liu committed May 11, 2016
1 parent b93c846 commit 12cb4c8
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,12 @@ static int kirin_drm_bind(struct device *dev)

static void kirin_drm_unbind(struct device *dev)
{
drm_put_dev(dev_get_drvdata(dev));
struct drm_device *drm_dev = dev_get_drvdata(dev);

drm_connector_unregister_all(drm_dev);
drm_dev_unregister(drm_dev);
kirin_drm_kms_cleanup(drm_dev);
drm_dev_unref(drm_dev);
}

static const struct component_master_ops kirin_drm_ops = {
Expand Down

0 comments on commit 12cb4c8

Please sign in to comment.