Skip to content

Commit 05a0177

Browse files
Boris Brezillongregkh
authored andcommitted
drm/vc4: Set ->is_yuv to false when num_planes == 1
commit 2b02a05 upstream. When vc4_plane_state is duplicated ->is_yuv is left assigned to its previous value, and we never set it back to false when switching to a non-YUV format. Fix that by setting ->is_yuv to false in the 'num_planes == 1' branch of the vc4_plane_setup_clipping_and_scaling() function. Fixes: fc04023 ("drm/vc4: Add support for YUV planes.") Cc: <stable@vger.kernel.org> Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com> Reviewed-by: Eric Anholt <eric@anholt.net> Link: https://patchwork.freedesktop.org/patch/msgid/20181009132446.21960-1-boris.brezillon@bootlin.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 85c8c61 commit 05a0177

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

drivers/gpu/drm/vc4/vc4_plane.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -322,6 +322,7 @@ static int vc4_plane_setup_clipping_and_scaling(struct drm_plane_state *state)
322322
if (vc4_state->is_unity)
323323
vc4_state->x_scaling[0] = VC4_SCALING_PPF;
324324
} else {
325+
vc4_state->is_yuv = false;
325326
vc4_state->x_scaling[1] = VC4_SCALING_NONE;
326327
vc4_state->y_scaling[1] = VC4_SCALING_NONE;
327328
}

0 commit comments

Comments
 (0)