Эх сурвалжийг харах

drm/msm/dsi: bypass dsi clock set during changing mode

Bypass setting clkrate_change_pending flag if the current mode
and the mode to be set has the same preferred clock rate.

Change-Id: Id1f6c45e822492427cf3555beeaa5f0e7ea3243c
Signed-off-by: Vara Reddy <[email protected]>
Vara Reddy 5 жил өмнө
parent
commit
03af5b7083
1 өөрчлөгдсөн 6 нэмэгдсэн , 1 устгасан
  1. 6 1
      msm/dsi/dsi_display.c

+ 6 - 1
msm/dsi/dsi_display.c

@@ -4489,8 +4489,13 @@ static int dsi_display_set_mode_sub(struct dsi_display *display,
 
 	if ((mode->dsi_mode_flags & DSI_MODE_FLAG_DMS) &&
 			(display->panel->panel_mode == DSI_OP_CMD_MODE)) {
+		u64 cur_bitclk = display->panel->cur_mode->timing.clk_rate_hz;
+		u64 to_bitclk = mode->timing.clk_rate_hz;
 		commit_phy_timing = true;
-		atomic_set(&display->clkrate_change_pending, 1);
+
+		/* No need to set clkrate pending flag if clocks are same */
+		if (cur_bitclk != to_bitclk)
+			atomic_set(&display->clkrate_change_pending, 1);
 
 		dsi_display_validate_dms_fps(display->panel->cur_mode, mode);
 	}