From: Lucas Stach Date: Wed, 6 Jul 2022 13:28:12 +0000 (+0200) Subject: drm/bridge: tc358767: disable main link PHYs on main link disable X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=8759464d7b6309e23df95f12064a120422d6f780;p=linux.git drm/bridge: tc358767: disable main link PHYs on main link disable Disable the main link PHYs and put them into reset when the main link is disabled. When the PHYs stay enabled while the rest of the DP link circuits are disabled there is some noise on the data lanes, which some displays try to lock onto, waking them up from their low power state. Signed-off-by: Lucas Stach Reviewed-by: Robert Foss Reviewed-by: Marek Vasut Tested-by: Marek Vasut Signed-off-by: Marek Vasut Link: https://patchwork.freedesktop.org/patch/msgid/20220706132812.2171250-3-l.stach@pengutronix.de --- diff --git a/drivers/gpu/drm/bridge/tc358767.c b/drivers/gpu/drm/bridge/tc358767.c index 2f6cb0c6902f5..baaed4d379119 100644 --- a/drivers/gpu/drm/bridge/tc358767.c +++ b/drivers/gpu/drm/bridge/tc358767.c @@ -1250,7 +1250,13 @@ static int tc_main_link_disable(struct tc_data *tc) if (ret) return ret; - return regmap_write(tc->regmap, DP0CTL, 0); + ret = regmap_write(tc->regmap, DP0CTL, 0); + if (ret) + return ret; + + return regmap_update_bits(tc->regmap, DP_PHY_CTRL, + PHY_M0_RST | PHY_M1_RST | PHY_M0_EN, + PHY_M0_RST | PHY_M1_RST); } static int tc_dsi_rx_enable(struct tc_data *tc)