Skip to content
Snippets Groups Projects
Commit 57b290cb authored by Kieran Bingham's avatar Kieran Bingham Committed by Laurent Pinchart
Browse files

drm: rcar-du: crtc: Support external DSI dot clock


On platforms with an external clock, both the group and crtc must be
handled accordingly to correctly pass through the external clock and
configure the DU to use the external rate.

The CRTC support was missed while adding the DSI support on the r8a779a0
which led to the output clocks being incorrectly determined.

Ensure that when a CRTC is routed through the DSI encoder, the external
clock is used without any further divider being applied.

Fixes: b291fdcf ("drm: rcar-du: Add r8a779a0 device support")
Signed-off-by: default avatarKieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Reviewed-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
parent e0e4c64a
No related branches found
No related tags found
No related merge requests found
...@@ -262,12 +262,13 @@ static void rcar_du_crtc_set_display_timing(struct rcar_du_crtc *rcrtc) ...@@ -262,12 +262,13 @@ static void rcar_du_crtc_set_display_timing(struct rcar_du_crtc *rcrtc)
rcar_du_group_write(rcrtc->group, DPLLCR, dpllcr); rcar_du_group_write(rcrtc->group, DPLLCR, dpllcr);
escr = ESCR_DCLKSEL_DCLKIN | div; escr = ESCR_DCLKSEL_DCLKIN | div;
} else if (rcdu->info->lvds_clk_mask & BIT(rcrtc->index)) { } else if (rcdu->info->lvds_clk_mask & BIT(rcrtc->index) ||
rcdu->info->dsi_clk_mask & BIT(rcrtc->index)) {
/* /*
* Use the LVDS PLL output as the dot clock when outputting to * Use the external LVDS or DSI PLL output as the dot clock when
* the LVDS encoder on an SoC that supports this clock routing * outputting to the LVDS or DSI encoder on an SoC that supports
* option. We use the clock directly in that case, without any * this clock routing option. We use the clock directly in that
* additional divider. * case, without any additional divider.
*/ */
escr = ESCR_DCLKSEL_DCLKIN; escr = ESCR_DCLKSEL_DCLKIN;
} else { } else {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment