diff options
author | Inki Dae <inki.dae@samsung.com> | 2013-05-12 03:09:33 -0400 |
---|---|---|
committer | Inki Dae <daeinki@gmail.com> | 2013-06-28 08:12:51 -0400 |
commit | 7fd65df155ebcd3684537c1e8f738b98ae595e28 (patch) | |
tree | 95548f7a9a9cb87a0d002bfdfe58877ea05a181b | |
parent | e436b09dc5fa33d36f4906f4556c4f543afd4b65 (diff) |
drm/exynos: do not use mode_set_base function directly
This patch adds exynos_drm_crtc_mode_set_commit function
to update mode data and it makes page flip call this function
instead of calling exynos_drm_crtc_mode_set_base function directly.
exynos_drm_crtc_mode_set_base function is called by drm subsystem
as a callback so we don't have to call this function directly.
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
-rw-r--r-- | drivers/gpu/drm/exynos/exynos_drm_crtc.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_crtc.c b/drivers/gpu/drm/exynos/exynos_drm_crtc.c index 073c10a35b2a..a143605884a4 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_crtc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_crtc.c | |||
@@ -139,7 +139,7 @@ exynos_drm_crtc_mode_set(struct drm_crtc *crtc, struct drm_display_mode *mode, | |||
139 | return 0; | 139 | return 0; |
140 | } | 140 | } |
141 | 141 | ||
142 | static int exynos_drm_crtc_mode_set_base(struct drm_crtc *crtc, int x, int y, | 142 | static int exynos_drm_crtc_mode_set_commit(struct drm_crtc *crtc, int x, int y, |
143 | struct drm_framebuffer *old_fb) | 143 | struct drm_framebuffer *old_fb) |
144 | { | 144 | { |
145 | struct exynos_drm_crtc *exynos_crtc = to_exynos_crtc(crtc); | 145 | struct exynos_drm_crtc *exynos_crtc = to_exynos_crtc(crtc); |
@@ -169,6 +169,12 @@ static int exynos_drm_crtc_mode_set_base(struct drm_crtc *crtc, int x, int y, | |||
169 | return 0; | 169 | return 0; |
170 | } | 170 | } |
171 | 171 | ||
172 | static int exynos_drm_crtc_mode_set_base(struct drm_crtc *crtc, int x, int y, | ||
173 | struct drm_framebuffer *old_fb) | ||
174 | { | ||
175 | return exynos_drm_crtc_mode_set_commit(crtc, x, y, old_fb); | ||
176 | } | ||
177 | |||
172 | static void exynos_drm_crtc_disable(struct drm_crtc *crtc) | 178 | static void exynos_drm_crtc_disable(struct drm_crtc *crtc) |
173 | { | 179 | { |
174 | struct exynos_drm_crtc *exynos_crtc = to_exynos_crtc(crtc); | 180 | struct exynos_drm_crtc *exynos_crtc = to_exynos_crtc(crtc); |
@@ -230,7 +236,7 @@ static int exynos_drm_crtc_page_flip(struct drm_crtc *crtc, | |||
230 | spin_unlock_irq(&dev->event_lock); | 236 | spin_unlock_irq(&dev->event_lock); |
231 | 237 | ||
232 | crtc->fb = fb; | 238 | crtc->fb = fb; |
233 | ret = exynos_drm_crtc_mode_set_base(crtc, crtc->x, crtc->y, | 239 | ret = exynos_drm_crtc_mode_set_commit(crtc, crtc->x, crtc->y, |
234 | NULL); | 240 | NULL); |
235 | if (ret) { | 241 | if (ret) { |
236 | crtc->fb = old_fb; | 242 | crtc->fb = old_fb; |