diff options
author | Archit Taneja <architt@codeaurora.org> | 2017-07-28 13:47:02 +0300 |
---|---|---|
committer | Rob Clark <robdclark@gmail.com> | 2017-08-02 14:53:46 +0300 |
commit | 6ed9ed484d04c2f6db0f68b0a31ef24db27d6454 (patch) | |
tree | 4306e7ed7ceab5308b475da564af6e7231ba96b2 /drivers/gpu/drm/msm/hdmi/hdmi_bridge.c | |
parent | d68fe15b1878acf6a88367c360bc98b309a9270e (diff) | |
download | linux-6ed9ed484d04c2f6db0f68b0a31ef24db27d6454.tar.xz |
drm/msm/hdmi: Set up runtime PM for HDMI
Enable rudimentary runtime PM in the HDMI driver. We can't really do
agressive PM toggling at the moment because we need to leave the hpd
clocks enabled all the time. There isn't much benefit of creating
suspend/resume ops to toggle clocks either.
We just make sure that we configure the power domain in the HDMI bridge's
enable/disable paths, and the HDMI connector's detect() op.
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Rob Clark <robdclark@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/msm/hdmi/hdmi_bridge.c')
-rw-r--r-- | drivers/gpu/drm/msm/hdmi/hdmi_bridge.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/msm/hdmi/hdmi_bridge.c b/drivers/gpu/drm/msm/hdmi/hdmi_bridge.c index ae40e7179d4f..e9b5e886e747 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi_bridge.c +++ b/drivers/gpu/drm/msm/hdmi/hdmi_bridge.c @@ -35,6 +35,8 @@ static void msm_hdmi_power_on(struct drm_bridge *bridge) const struct hdmi_platform_config *config = hdmi->config; int i, ret; + pm_runtime_get_sync(&hdmi->pdev->dev); + for (i = 0; i < config->pwr_reg_cnt; i++) { ret = regulator_enable(hdmi->pwr_regs[i]); if (ret) { @@ -84,6 +86,8 @@ static void power_off(struct drm_bridge *bridge) config->pwr_reg_names[i], ret); } } + + pm_runtime_put_autosuspend(&hdmi->pdev->dev); } #define AVI_IFRAME_LINE_NUMBER 1 |