Skip to content

Commit 3257ec7

Browse files
mripardanholt
authored andcommitted
drm/vc4: plane: Expand the lower bits by repeating the higher bits
The vc4 HVS uses an internal RGB888 representation of the frames, and will by default expand formats using a lower depth using zeros. This causes an issue when we try to use other compositing software such as pixman that fill the missing bits by repeating the higher significant bits. As such, we can't check the display output in a reliable way by doing a software composition and an hardware one and compare both. To prevent this, force the same behaviour so that we can do such things. Signed-off-by: Maxime Ripard <maxime.ripard@bootlin.com> Signed-off-by: Eric Anholt <eric@anholt.net> Link: https://patchwork.freedesktop.org/patch/msgid/20180517133759.25626-1-maxime.ripard@bootlin.com
1 parent 584a014 commit 3257ec7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/gpu/drm/vc4/vc4_plane.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -544,6 +544,7 @@ static int vc4_plane_mode_set(struct drm_plane *plane,
544544
/* Control word */
545545
vc4_dlist_write(vc4_state,
546546
SCALER_CTL0_VALID |
547+
VC4_SET_FIELD(SCALER_CTL0_RGBA_EXPAND_ROUND, SCALER_CTL0_RGBA_EXPAND) |
547548
(format->pixel_order << SCALER_CTL0_ORDER_SHIFT) |
548549
(format->hvs << SCALER_CTL0_PIXEL_FORMAT_SHIFT) |
549550
VC4_SET_FIELD(tiling, SCALER_CTL0_TILING) |

0 commit comments

Comments
 (0)