Commit 9a0e9802 authored by Boris Brezillon's avatar Boris Brezillon

drm/vc4: Fix scaling of uni-planar formats

When using uni-planar formats (like RGB), the scaling parameters are
stored in plane 0, not plane 1.

Fixes: fc04023f ("drm/vc4: Add support for YUV planes.")
Cc: stable@vger.kernel.org
Signed-off-by: default avatarBoris Brezillon <boris.brezillon@bootlin.com>
Reviewed-by: default avatarEric Anholt <eric@anholt.net>
Link: https://patchwork.freedesktop.org/patch/msgid/20180507121303.5610-1-boris.brezillon@bootlin.com
parent 7a109673
...@@ -503,7 +503,7 @@ static int vc4_plane_mode_set(struct drm_plane *plane, ...@@ -503,7 +503,7 @@ static int vc4_plane_mode_set(struct drm_plane *plane,
* the scl fields here. * the scl fields here.
*/ */
if (num_planes == 1) { if (num_planes == 1) {
scl0 = vc4_get_scl_field(state, 1); scl0 = vc4_get_scl_field(state, 0);
scl1 = scl0; scl1 = scl0;
} else { } else {
scl0 = vc4_get_scl_field(state, 1); scl0 = vc4_get_scl_field(state, 1);
......
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