Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1456135
| From | Bibby Hsieh <bibby.hsieh@mediatek.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH v2 6/7] drm/mediatek: plane: Use FB's format's cpp to compute x offset |
| Date | 2016-08-04 05:10 +0200 |
| Message-ID | <s2hcK-3aD-19@gated-at.bofh.it> (permalink) |
| References | <s2hcJ-3aD-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
From: Daniel Kurtz <djkurtz@chromium.org> Use the framebuffer's format to compute its cpp, and use it when calculating the address shift value. Signed-off-by: Bibby Hsieh <bibby.hsieh@mediatek.com> --- drivers/gpu/drm/mediatek/mtk_drm_plane.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/mediatek/mtk_drm_plane.c b/drivers/gpu/drm/mediatek/mtk_drm_plane.c index b3ddb20..c461a23 100644 --- a/drivers/gpu/drm/mediatek/mtk_drm_plane.c +++ b/drivers/gpu/drm/mediatek/mtk_drm_plane.c @@ -135,7 +135,7 @@ static void mtk_plane_atomic_update(struct drm_plane *plane, pitch = fb->pitches[0]; format = fb->pixel_format; - addr += (plane->state->src.x1 >> 16) * 4; + addr += (plane->state->src.x1 >> 16) * drm_format_plane_cpp(format, 0); addr += (plane->state->src.y1 >> 16) * pitch; state->pending.enable = true; -- 1.7.9.5
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v2 0/7] drm/mediatek: cleaning up and refine Bibby Hsieh <bibby.hsieh@mediatek.com> - 2016-08-04 05:10 +0200 [PATCH v2 3/7] drm/mediatek: Remove mtk_drm_plane Bibby Hsieh <bibby.hsieh@mediatek.com> - 2016-08-04 05:10 +0200 [PATCH v2 1/7] drm/mediatek: Remove mtk_drm_crtc_check_flush Bibby Hsieh <bibby.hsieh@mediatek.com> - 2016-08-04 05:10 +0200 [PATCH v2 6/7] drm/mediatek: plane: Use FB's format's cpp to compute x offset Bibby Hsieh <bibby.hsieh@mediatek.com> - 2016-08-04 05:10 +0200 [PATCH v2 4/7] drm/mediatek: Use drm_atomic destroy_state helpers Bibby Hsieh <bibby.hsieh@mediatek.com> - 2016-08-04 05:10 +0200 Re: [PATCH v2 0/7] drm/mediatek: cleaning up and refine Sean Paul <seanpaul@chromium.org> - 2016-08-04 21:00 +0200
csiph-web