Commit ac8f7c48 authored by Thierry Reding's avatar Thierry Reding Committed by Dave Airlie

drm: tegra: Use framebuffer pitch as line stride

Instead of using the stride derived from the display mode, use the pitch
associated with the currently active framebuffer. This fixes a bug where
the LCD display content would be skewed when enabling HDMI with a video
mode different from that of the LCD.
Signed-off-by: default avatarThierry Reding <thierry.reding@avionic-design.de>
Tested-by: default avatarTerje Bergstrom <tbergstrom@nvidia.com>
Tested-by: default avatarMark Zhang <markz@nvidia.com>
Tested-by: default avatarStephen Warren <swarren@nvidia.com>
Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
parent 82fe50bc
......@@ -218,7 +218,7 @@ static int tegra_crtc_mode_set(struct drm_crtc *crtc,
}
bpp = crtc->fb->bits_per_pixel / 8;
win.stride = win.outw * bpp;
win.stride = crtc->fb->pitches[0];
/* program window registers */
value = tegra_dc_readl(dc, DC_CMD_DISPLAY_WINDOW_HEADER);
......
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