History

drm/tegra: dsi: Enhance runtime power management

The MIPI DSI output on Tegra SoCs requires some external logic to calibrate the MIPI pads before a video signal can be transmitted. This MIPI calibration logic requires to be powered on while the MIPI pads are being used, which is currently done as part of the DSI driver's probe implementation. This is suboptimal because it will leave the MIPI calibration logic powered up even if the DSI output is never used. On Tegra114 and earlier this behaviour also causes the driver to hang while trying to power up the MIPI calibration logic because the power partition that contains the MIPI calibration logic will be powered on by the display controller at output pipeline configuration time. Thus the power up sequence for the MIPI calibration logic happens before it's power partition is guaranteed to be enabled. Fix this by splitting up the API into a request/free pair of functions that manage the runtime dependency between the DSI and the calibration modules (no registers are accessed) and a set of enable, calibrate and disable functions that program the MIPI calibration logic at points in time where the power partition is really enabled. While at it, make sure that the runtime power management also works in ganged mode, which is currently also broken.

Thierry Reding committed 10 years ago

Commit 87904c31 parent 29b48173 files · +69 −39Browse files

Showing the changes to include/linux (1 of 3 files). Show all

Unified · Split

include/linux/host1x.h+2−0
@@ -304,6 +304,8 @@ struct tegra_mipi_device; · 303 unmodified lines
304 304
305struct tegra_mipi_device *tegra_mipi_request(struct device *device);305struct tegra_mipi_device *tegra_mipi_request(struct device *device);
306void tegra_mipi_free(struct tegra_mipi_device *device);306void tegra_mipi_free(struct tegra_mipi_device *device);
307int tegra_mipi_enable(struct tegra_mipi_device *device);
308int tegra_mipi_disable(struct tegra_mipi_device *device);
307int tegra_mipi_calibrate(struct tegra_mipi_device *device);309int tegra_mipi_calibrate(struct tegra_mipi_device *device);
308 310
309#endif311#endif