Commit a9777267 authored by Christoph Manszewski's avatar Christoph Manszewski Committed by Inki Dae

drm/exynos: drm_plane: Correct exynos_drm_plane_reset

Make use of helper functions in exynos_drm_plane_reset in order to set
all default values. Currently alpha isn't set during reset.
Signed-off-by: default avatarChristoph Manszewski <c.manszewski@samsung.com>
Signed-off-by: default avatarInki Dae <inki.dae@samsung.com>
parent d25a40a7
...@@ -131,16 +131,14 @@ static void exynos_drm_plane_reset(struct drm_plane *plane) ...@@ -131,16 +131,14 @@ static void exynos_drm_plane_reset(struct drm_plane *plane)
if (plane->state) { if (plane->state) {
exynos_state = to_exynos_plane_state(plane->state); exynos_state = to_exynos_plane_state(plane->state);
if (exynos_state->base.fb) __drm_atomic_helper_plane_destroy_state(plane->state);
drm_framebuffer_put(exynos_state->base.fb);
kfree(exynos_state); kfree(exynos_state);
plane->state = NULL; plane->state = NULL;
} }
exynos_state = kzalloc(sizeof(*exynos_state), GFP_KERNEL); exynos_state = kzalloc(sizeof(*exynos_state), GFP_KERNEL);
if (exynos_state) { if (exynos_state) {
plane->state = &exynos_state->base; __drm_atomic_helper_plane_reset(plane, &exynos_state->base);
plane->state->plane = plane;
plane->state->zpos = exynos_plane->config->zpos; plane->state->zpos = exynos_plane->config->zpos;
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment