diff options
author | Marek Szyprowski <m.szyprowski@samsung.com> | 2015-11-30 16:53:21 +0300 |
---|---|---|
committer | Inki Dae <daeinki@gmail.com> | 2015-12-13 16:22:54 +0300 |
commit | 0488f50e998dfa42a99a1e44882da408e71a09b2 (patch) | |
tree | e0e1c44541094cece38aa94adf019cb1ba56e254 /drivers/gpu/drm/exynos/exynos_drm_plane.c | |
parent | 42f8119c8ae22196ecbc8eb9cd839111f37afd2b (diff) | |
download | linux-0488f50e998dfa42a99a1e44882da408e71a09b2.tar.xz |
drm/exynos: move dma_addr attribute from exynos plane to exynos fb
DMA address is a framebuffer attribute and the right place for it is
exynos_drm_framebuffer not exynos_drm_plane. This patch also introduces
helper function for getting dma address of the given framebuffer.
Changelog v2:
- use state->fb instead of plane->base.fb.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Reviewed-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Diffstat (limited to 'drivers/gpu/drm/exynos/exynos_drm_plane.c')
-rw-r--r-- | drivers/gpu/drm/exynos/exynos_drm_plane.c | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_plane.c b/drivers/gpu/drm/exynos/exynos_drm_plane.c index 179311760bb7..c725409421b8 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_plane.c +++ b/drivers/gpu/drm/exynos/exynos_drm_plane.c @@ -120,28 +120,10 @@ static int exynos_plane_atomic_check(struct drm_plane *plane, struct drm_plane_state *state) { struct exynos_drm_plane *exynos_plane = to_exynos_plane(plane); - int nr; - int i; if (!state->fb) return 0; - nr = drm_format_num_planes(state->fb->pixel_format); - for (i = 0; i < nr; i++) { - struct exynos_drm_gem *exynos_gem = - exynos_drm_fb_gem(state->fb, i); - if (!exynos_gem) { - DRM_DEBUG_KMS("gem object is null\n"); - return -EFAULT; - } - - exynos_plane->dma_addr[i] = exynos_gem->dma_addr + - state->fb->offsets[i]; - - DRM_DEBUG_KMS("buffer: %d, dma_addr = 0x%lx\n", - i, (unsigned long)exynos_plane->dma_addr[i]); - } - return 0; } |