forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
drm: rcar-du: Fix DSI enable & disable sequence
The rcar crtc depends on the clock provided from the rcar DSI bridge. When the DSI bridge is disabled, the clock is stopped, which causes the crtc disable to timeout. Also, while I have no issue with the enable, the documentation suggests to enable the DSI before the crtc so that the crtc has its clock enabled at enable time. This is also not done by the current driver. To fix this, we need to keep the DSI bridge enabled until the crtc has disabled itself, and enable the DSI bridge before crtc enables itself. Add functions rcar_mipi_dsi_pclk_enable and rcar_mipi_dsi_pclk_disable to the rcar DSI bridge driver which the rcar driver can use to enable/disable the DSI clock when needed. This is similar to what is already done with the rcar LVDS bridge. Signed-off-by: Tomi Valkeinen <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Signed-off-by: Laurent Pinchart <[email protected]>
- Loading branch information
Showing
5 changed files
with
83 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/* SPDX-License-Identifier: GPL-2.0 */ | ||
/* | ||
* R-Car DSI Encoder | ||
* | ||
* Copyright (C) 2022 Renesas Electronics Corporation | ||
* | ||
* Contact: Tomi Valkeinen <[email protected]> | ||
*/ | ||
|
||
#ifndef __RCAR_MIPI_DSI_H__ | ||
#define __RCAR_MIPI_DSI_H__ | ||
|
||
struct drm_atomic_state; | ||
struct drm_bridge; | ||
|
||
#if IS_ENABLED(CONFIG_DRM_RCAR_MIPI_DSI) | ||
void rcar_mipi_dsi_pclk_enable(struct drm_bridge *bridge, | ||
struct drm_atomic_state *state); | ||
void rcar_mipi_dsi_pclk_disable(struct drm_bridge *bridge); | ||
#else | ||
static inline void rcar_mipi_dsi_pclk_enable(struct drm_bridge *bridge, | ||
struct drm_atomic_state *state) | ||
{ | ||
} | ||
|
||
static inline void rcar_mipi_dsi_pclk_disable(struct drm_bridge *bridge) | ||
{ | ||
} | ||
#endif /* CONFIG_DRM_RCAR_MIPI_DSI */ | ||
|
||
#endif /* __RCAR_MIPI_DSI_H__ */ |