[PATCH 5/6] drm/i915: Make sure panel fixed_mode has vrefresh populated

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

 



From: Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx>

We want to use fixed_mode->vrefresh during mode validation, so first
make sure it's set correctly.

And we'll do the same for the downclock mode for consistency.

Signed-off-by: Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx>
---
 drivers/gpu/drm/i915/intel_panel.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_panel.c b/drivers/gpu/drm/i915/intel_panel.c
index 14b827ec5427..c784e772b6aa 100644
--- a/drivers/gpu/drm/i915/intel_panel.c
+++ b/drivers/gpu/drm/i915/intel_panel.c
@@ -1932,6 +1932,15 @@ int intel_panel_init(struct intel_panel *panel,
 {
 	intel_panel_init_backlight_funcs(panel);
 
+	if (fixed_mode) {
+		fixed_mode->vrefresh = 0;
+		fixed_mode->vrefresh = drm_mode_vrefresh(fixed_mode);
+	}
+	if (downclock_mode) {
+		downclock_mode->vrefresh = 0;
+		downclock_mode->vrefresh = drm_mode_vrefresh(downclock_mode);
+	}
+
 	panel->fixed_mode = fixed_mode;
 	panel->downclock_mode = downclock_mode;
 
-- 
2.16.4

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




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

  Powered by Linux