From 3feaf3e5ae89347a2ab3b9e994f1f3d85c09185f Mon Sep 17 00:00:00 2001 From: Thierry Reding Date: Tue, 21 Oct 2014 13:56:59 +0200 Subject: [PATCH] drm/tegra: fb: Do not destroy framebuffer Drop a reference instead of directly calling the framebuffer .destroy() callback at fbdev free time. This is necessary to make sure the object isn't destroyed if anyone else still has a reference. Reviewed-by: Daniel Vetter Signed-off-by: Thierry Reding --- drivers/gpu/drm/tegra/fb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/tegra/fb.c b/drivers/gpu/drm/tegra/fb.c index fab39eb2dae8..ec5ae7cf4349 100644 --- a/drivers/gpu/drm/tegra/fb.c +++ b/drivers/gpu/drm/tegra/fb.c @@ -360,7 +360,7 @@ static void tegra_fbdev_exit(struct tegra_fbdev *fbdev) if (fbdev->fb) { drm_framebuffer_unregister_private(&fbdev->fb->base); - tegra_fb_destroy(&fbdev->fb->base); + drm_framebuffer_remove(&fbdev->fb->base); } drm_fb_helper_fini(&fbdev->base); -- 2.20.1