summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm/tilcdc/tilcdc_crtc.c')
-rw-r--r--drivers/gpu/drm/tilcdc/tilcdc_crtc.c23
1 files changed, 17 insertions, 6 deletions
diff --git a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
index d745e8b50fb8..afd2a7b2aff7 100644
--- a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
+++ b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
@@ -579,7 +579,7 @@ static void tilcdc_crtc_recover_work(struct work_struct *work)
dev_info(crtc->dev->dev, "%s: Reset CRTC", __func__);
- drm_modeset_lock_crtc(crtc, NULL);
+ drm_modeset_lock(&crtc->mutex, NULL);
if (!tilcdc_crtc_is_on(crtc))
goto out;
@@ -587,7 +587,7 @@ static void tilcdc_crtc_recover_work(struct work_struct *work)
tilcdc_crtc_disable(crtc);
tilcdc_crtc_enable(crtc);
out:
- drm_modeset_unlock_crtc(crtc);
+ drm_modeset_unlock(&crtc->mutex);
}
static void tilcdc_crtc_destroy(struct drm_crtc *crtc)
@@ -595,9 +595,9 @@ static void tilcdc_crtc_destroy(struct drm_crtc *crtc)
struct tilcdc_crtc *tilcdc_crtc = to_tilcdc_crtc(crtc);
struct tilcdc_drm_private *priv = crtc->dev->dev_private;
- drm_modeset_lock_crtc(crtc, NULL);
+ drm_modeset_lock(&crtc->mutex, NULL);
tilcdc_crtc_disable(crtc);
- drm_modeset_unlock_crtc(crtc);
+ drm_modeset_unlock(&crtc->mutex);
flush_workqueue(priv->wq);
@@ -706,6 +706,15 @@ static int tilcdc_crtc_atomic_check(struct drm_crtc *crtc,
return 0;
}
+static int tilcdc_crtc_enable_vblank(struct drm_crtc *crtc)
+{
+ return 0;
+}
+
+static void tilcdc_crtc_disable_vblank(struct drm_crtc *crtc)
+{
+}
+
static const struct drm_crtc_funcs tilcdc_crtc_funcs = {
.destroy = tilcdc_crtc_destroy,
.set_config = drm_atomic_helper_set_config,
@@ -713,6 +722,8 @@ static const struct drm_crtc_funcs tilcdc_crtc_funcs = {
.reset = drm_atomic_helper_crtc_reset,
.atomic_duplicate_state = drm_atomic_helper_crtc_duplicate_state,
.atomic_destroy_state = drm_atomic_helper_crtc_destroy_state,
+ .enable_vblank = tilcdc_crtc_enable_vblank,
+ .disable_vblank = tilcdc_crtc_disable_vblank,
};
static const struct drm_crtc_helper_funcs tilcdc_crtc_helper_funcs = {
@@ -845,7 +856,7 @@ void tilcdc_crtc_update_clk(struct drm_crtc *crtc)
struct tilcdc_drm_private *priv = dev->dev_private;
struct tilcdc_crtc *tilcdc_crtc = to_tilcdc_crtc(crtc);
- drm_modeset_lock_crtc(crtc, NULL);
+ drm_modeset_lock(&crtc->mutex, NULL);
if (tilcdc_crtc->lcd_fck_rate != clk_get_rate(priv->clk)) {
if (tilcdc_crtc_is_on(crtc)) {
pm_runtime_get_sync(dev->dev);
@@ -857,7 +868,7 @@ void tilcdc_crtc_update_clk(struct drm_crtc *crtc)
pm_runtime_put_sync(dev->dev);
}
}
- drm_modeset_unlock_crtc(crtc);
+ drm_modeset_unlock(&crtc->mutex);
}
#define SYNC_LOST_COUNT_LIMIT 50
OpenPOWER on IntegriCloud