Skip to content

Commit

Permalink
drm/rockchip: Check for fast link training before enabling psr
Browse files Browse the repository at this point in the history
[ Upstream commit ad309284a52be47c8b3126c9376358bf381861bc ]

Once we start shutting off the link during PSR, we're going to want fast
training to work. If the display doesn't support fast training, don't
enable psr.

Changes in v2:
- None
Changes in v3:
- None
Changes in v4:
- None
Changes in v5:
- None

Link to v1: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Link to v2: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Link to v3: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Link to v4: https://patchwork.freedesktop.org/patch/msgid/[email protected]

Cc: Zain Wang <[email protected]>
Cc: Tomasz Figa <[email protected]>
Tested-by: Heiko Stuebner <[email protected]>
Reviewed-by: Heiko Stuebner <[email protected]>
Signed-off-by: Sean Paul <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Signed-off-by: Sasha Levin <[email protected]>
  • Loading branch information
atseanpaul authored and gregkh committed Oct 7, 2019
1 parent f3d6217 commit 441c155
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions drivers/gpu/drm/bridge/analogix/analogix_dp_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1040,16 +1040,17 @@ static int analogix_dp_commit(struct analogix_dp_device *dp)
if (ret)
return ret;

/* Check whether panel supports fast training */
ret = analogix_dp_fast_link_train_detection(dp);
if (ret)
dp->psr_enable = false;

if (dp->psr_enable) {
ret = analogix_dp_enable_sink_psr(dp);
if (ret)
return ret;
}

/* Check whether panel supports fast training */
ret = analogix_dp_fast_link_train_detection(dp);
if (ret)
dp->psr_enable = false;

return ret;
}
Expand Down

0 comments on commit 441c155

Please sign in to comment.