drm/i915: Do not handle a null plane state.
authorMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Thu, 10 Sep 2015 14:08:02 +0000 (16:08 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Thu, 10 Sep 2015 16:27:17 +0000 (18:27 +0200)
With the conversion to atomic this cannot happen any more.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/intel_atomic_plane.c

index f1ab8e4b9c11c6b75534c52ad5e3bc1b05000dce..a119806965951eb15b9cbc66daa898e4ad52b3b4 100644 (file)
@@ -76,11 +76,7 @@ intel_plane_duplicate_state(struct drm_plane *plane)
        struct drm_plane_state *state;
        struct intel_plane_state *intel_state;
 
-       if (WARN_ON(!plane->state))
-               intel_state = intel_create_plane_state(plane);
-       else
-               intel_state = kmemdup(plane->state, sizeof(*intel_state),
-                                     GFP_KERNEL);
+       intel_state = kmemdup(plane->state, sizeof(*intel_state), GFP_KERNEL);
 
        if (!intel_state)
                return NULL;