drm/exynos: Remove event cancelling from postclose
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Mon, 25 Jan 2016 21:16:47 +0000 (22:16 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Mon, 8 Feb 2016 08:55:49 +0000 (09:55 +0100)
The core takes care of this now. And since kfree(NULL) is ok we can
simplify the function even further now.

Note: There's another spin on this patch, but for different reasons,
in-flight already: http://www.spinics.net/lists/dri-devel/msg97922.html

Cc: Inki Dae <inki.dae@samsung.com>
Acked-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Acked-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1453756616-28942-6-git-send-email-daniel.vetter@ffwll.ch
drivers/gpu/drm/exynos/exynos_drm_drv.c

index 68f0f36f6e7e073af4d88da75a7a84f0734576f2..1e535f981240d3bb81ac002c71b26f22f0085114 100644 (file)
@@ -340,20 +340,6 @@ static void exynos_drm_preclose(struct drm_device *dev,
 
 static void exynos_drm_postclose(struct drm_device *dev, struct drm_file *file)
 {
-       struct drm_pending_event *e, *et;
-       unsigned long flags;
-
-       if (!file->driver_priv)
-               return;
-
-       spin_lock_irqsave(&dev->event_lock, flags);
-       /* Release all events handled by page flip handler but not freed. */
-       list_for_each_entry_safe(e, et, &file->event_list, link) {
-               list_del(&e->link);
-               e->destroy(e);
-       }
-       spin_unlock_irqrestore(&dev->event_lock, flags);
-
        kfree(file->driver_priv);
        file->driver_priv = NULL;
 }