diff options
author | Joonyoung Shim <jy0922.shim@samsung.com> | 2015-09-01 03:22:54 -0400 |
---|---|---|
committer | Inki Dae <daeinki@gmail.com> | 2015-09-02 10:10:34 -0400 |
commit | faec262b14f3d92601c06b5c73b45ea71d0d164b (patch) | |
tree | dfcbf3185003b8c6d8bd77cc7699f6257ca4a10c /drivers/gpu/drm | |
parent | 8d31758ecfe156fa4775017858613a5087eb57bf (diff) |
drm/exynos: remove exynos_drm_fb_get_buf_cnt()
We can get buffer count of framebuffer using drm_format_num_planes(), so
keeping exynos_drm_fb_get_buf_cnt() is unnecessary.
Signed-off-by: Joonyoung Shim <jy0922.shim@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')
-rw-r--r-- | drivers/gpu/drm/exynos/exynos_drm_fb.c | 9 | ||||
-rw-r--r-- | drivers/gpu/drm/exynos/exynos_drm_fb.h | 3 | ||||
-rw-r--r-- | drivers/gpu/drm/exynos/exynos_drm_plane.c | 2 |
3 files changed, 1 insertions, 13 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fb.c b/drivers/gpu/drm/exynos/exynos_drm_fb.c index 849925ca0cdd..5087f60985f5 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fb.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fb.c | |||
@@ -121,15 +121,6 @@ static struct drm_framebuffer_funcs exynos_drm_fb_funcs = { | |||
121 | .dirty = exynos_drm_fb_dirty, | 121 | .dirty = exynos_drm_fb_dirty, |
122 | }; | 122 | }; |
123 | 123 | ||
124 | unsigned int exynos_drm_fb_get_buf_cnt(struct drm_framebuffer *fb) | ||
125 | { | ||
126 | struct exynos_drm_fb *exynos_fb; | ||
127 | |||
128 | exynos_fb = to_exynos_fb(fb); | ||
129 | |||
130 | return exynos_fb->buf_cnt; | ||
131 | } | ||
132 | |||
133 | struct drm_framebuffer * | 124 | struct drm_framebuffer * |
134 | exynos_drm_framebuffer_init(struct drm_device *dev, | 125 | exynos_drm_framebuffer_init(struct drm_device *dev, |
135 | struct drm_mode_fb_cmd2 *mode_cmd, | 126 | struct drm_mode_fb_cmd2 *mode_cmd, |
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fb.h b/drivers/gpu/drm/exynos/exynos_drm_fb.h index 8900f6baf315..85e4445b920e 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fb.h +++ b/drivers/gpu/drm/exynos/exynos_drm_fb.h | |||
@@ -28,7 +28,4 @@ struct exynos_drm_gem_obj *exynos_drm_fb_gem_obj(struct drm_framebuffer *fb, | |||
28 | 28 | ||
29 | void exynos_drm_mode_config_init(struct drm_device *dev); | 29 | void exynos_drm_mode_config_init(struct drm_device *dev); |
30 | 30 | ||
31 | /* get a buffer count to drm framebuffer. */ | ||
32 | unsigned int exynos_drm_fb_get_buf_cnt(struct drm_framebuffer *fb); | ||
33 | |||
34 | #endif | 31 | #endif |
diff --git a/drivers/gpu/drm/exynos/exynos_drm_plane.c b/drivers/gpu/drm/exynos/exynos_drm_plane.c index 865d6eb0c845..714822441467 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_plane.c +++ b/drivers/gpu/drm/exynos/exynos_drm_plane.c | |||
@@ -126,7 +126,7 @@ static int exynos_plane_atomic_check(struct drm_plane *plane, | |||
126 | if (!state->fb) | 126 | if (!state->fb) |
127 | return 0; | 127 | return 0; |
128 | 128 | ||
129 | nr = exynos_drm_fb_get_buf_cnt(state->fb); | 129 | nr = drm_format_num_planes(state->fb->pixel_format); |
130 | for (i = 0; i < nr; i++) { | 130 | for (i = 0; i < nr; i++) { |
131 | struct exynos_drm_gem_obj *obj = | 131 | struct exynos_drm_gem_obj *obj = |
132 | exynos_drm_fb_gem_obj(state->fb, i); | 132 | exynos_drm_fb_gem_obj(state->fb, i); |