summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/exynos/exynos_drm_crtc.c
diff options
context:
space:
mode:
authorInki Dae <inki.dae@samsung.com>2014-12-02 22:05:01 +0900
committerInki Dae <inki.dae@samsung.com>2015-06-08 17:56:43 +0900
commit3bdf6a624cd1225fa8fe2e6366ca6b63c8882c72 (patch)
tree1b277cbdbc6469781b779a8f963b9f41c8d2fd7d /drivers/gpu/drm/exynos/exynos_drm_crtc.c
parent6c0f62d75991cffb9f27e0e45a22e8ea4b06e7e7 (diff)
downloadlinux-3.10-3bdf6a624cd1225fa8fe2e6366ca6b63c8882c72.tar.gz
linux-3.10-3bdf6a624cd1225fa8fe2e6366ca6b63c8882c72.tar.bz2
linux-3.10-3bdf6a624cd1225fa8fe2e6366ca6b63c8882c72.zip
drm/exynos: add LPD: Low Power Display mechanism supporttizen_LPD
The purpose of this mechanism is to transfer the only framebuffer region updated by X server to Display panel to save power consumed by Display relevant DMA devices. Change-Id: I2589c617d817833011e761c9c8835e287ff2fb7c Signed-off-by: Inki Dae <inki.dae@samsung.com>
Diffstat (limited to 'drivers/gpu/drm/exynos/exynos_drm_crtc.c')
-rw-r--r--drivers/gpu/drm/exynos/exynos_drm_crtc.c34
1 files changed, 34 insertions, 0 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_crtc.c b/drivers/gpu/drm/exynos/exynos_drm_crtc.c
index 7e52a170d1f..d35f7782e36 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_crtc.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_crtc.c
@@ -594,3 +594,37 @@ int exynos_drm_crtc_te_handler(struct drm_crtc *crtc)
return ret;
}
+
+void exynos_drm_crtc_adjust_partial_region(struct drm_crtc *crtc,
+ struct exynos_drm_partial_pos *pos)
+{
+ struct exynos_drm_crtc *exynos_crtc = to_exynos_crtc(crtc);
+ struct exynos_drm_manager *mgr = exynos_crtc->manager;
+
+ if (mgr && mgr->ops->adjust_partial_region)
+ mgr->ops->adjust_partial_region(mgr, &pos->x, &pos->y,
+ &pos->w, &pos->h);
+}
+
+void exynos_drm_crtc_change_resolution(struct drm_device *drm_dev,
+ unsigned int pipe, unsigned int x,
+ unsigned int y, unsigned int w,
+ unsigned int h)
+{
+ struct exynos_drm_private *private = drm_dev->dev_private;
+ struct exynos_drm_crtc *exynos_crtc =
+ to_exynos_crtc(private->crtc[pipe]);
+ struct exynos_drm_manager *manager = exynos_crtc->manager;
+ struct drm_encoder *encoder;
+
+ /* TODO. mutex_lock */
+
+ list_for_each_entry(encoder, &drm_dev->mode_config.encoder_list, head) {
+ if (encoder->crtc == &exynos_crtc->drm_crtc) {
+ exynos_drm_encoder_change_resolution(encoder, x, y,
+ w, h);
+ break;
+ }
+ }
+}
+