[PATCH 48/81] drm/i915: Update CRTC properties after modeset

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Ville Syrj?l? <ville.syrjala at linux.intel.com>

Update cursor related CRTC properties after a modeset. The cursor
properties aren't handled by the drm core since not all CRTCs have
cursors.

Signed-off-by: Ville Syrj?l? <ville.syrjala at linux.intel.com>
---
 drivers/gpu/drm/i915/intel_display.c |   15 +++++++++++++++
 1 files changed, 15 insertions(+), 0 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 566bf29..321c840 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -6368,6 +6368,8 @@ static int intel_crtc_cursor_set(struct drm_crtc *crtc,
 	if (old_obj)
 		intel_crtc_cursor_bo_unref(crtc, old_obj);
 
+	intel_crtc_update_properties(crtc);
+
 	return 0;
 }
 
@@ -6380,6 +6382,8 @@ static int intel_crtc_cursor_move(struct drm_crtc *crtc, int x, int y)
 
 	intel_crtc_update_cursor(crtc, true);
 
+	intel_crtc_update_properties(crtc);
+
 	return 0;
 }
 
@@ -7341,6 +7345,8 @@ static int intel_crtc_page_flip(struct drm_crtc *crtc,
 
 	trace_i915_flip_request(intel_crtc->plane, obj);
 
+	intel_crtc_update_properties(crtc);
+
 	return 0;
 
 cleanup_pending:
@@ -8067,6 +8073,7 @@ next_encoder:
 static int intel_crtc_set_config(struct drm_mode_set *set)
 {
 	struct drm_device *dev;
+	struct drm_crtc *crtc;
 	struct drm_mode_set save_set;
 	struct intel_set_config *config;
 	int ret;
@@ -8140,6 +8147,10 @@ static int intel_crtc_set_config(struct drm_mode_set *set)
 
 	intel_set_config_free(config);
 
+	/* changes in one CRTC can affect the others */
+	list_for_each_entry(crtc, &dev->mode_config.crtc_list, head)
+		intel_crtc_update_properties(crtc);
+
 	return 0;
 
 fail:
@@ -8151,6 +8162,10 @@ fail:
 			    save_set.x, save_set.y, save_set.fb))
 		DRM_ERROR("failed to restore config after modeset failure\n");
 
+	/* changes in one CRTC can affect the others */
+	list_for_each_entry(crtc, &dev->mode_config.crtc_list, head)
+		intel_crtc_update_properties(crtc);
+
 out_config:
 	intel_set_config_free(config);
 	return ret;
-- 
1.7.8.6



[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux