Commit 52e4607d authored by Paul Cercueil's avatar Paul Cercueil

gpu/drm: ingenic: Use the plane's src_[x,y] to configure DMA length

Instead of obtaining the width/height of the framebuffer from the CRTC
state, obtain it from the current plane state.

v2: No change
Signed-off-by: default avatarPaul Cercueil <paul@crapouillou.net>
Link: https://patchwork.freedesktop.org/patch/msgid/20191210144142.33143-3-paul@crapouillou.net
# *** extracted tags ***
Acked-by: default avatarSam Ravnborg <sam@ravnborg.org>
parent 354b051c
...@@ -376,8 +376,8 @@ static void ingenic_drm_plane_atomic_update(struct drm_plane *plane, ...@@ -376,8 +376,8 @@ static void ingenic_drm_plane_atomic_update(struct drm_plane *plane,
if (state && state->fb) { if (state && state->fb) {
addr = drm_fb_cma_get_gem_addr(state->fb, state, 0); addr = drm_fb_cma_get_gem_addr(state->fb, state, 0);
width = state->crtc->state->adjusted_mode.hdisplay; width = state->src_w >> 16;
height = state->crtc->state->adjusted_mode.vdisplay; height = state->src_h >> 16;
cpp = state->fb->format->cpp[plane->index]; cpp = state->fb->format->cpp[plane->index];
priv->dma_hwdesc->addr = addr; priv->dma_hwdesc->addr = addr;
......
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