[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190304123300.GH6325@pendragon.ideasonboard.com>
Date: Mon, 4 Mar 2019 14:33:00 +0200
From: Laurent Pinchart <laurent.pinchart@...asonboard.com>
To: Andrey Smirnov <andrew.smirnov@...il.com>
Cc: dri-devel@...ts.freedesktop.org,
Archit Taneja <architt@...eaurora.org>,
Andrzej Hajda <a.hajda@...sung.com>,
Chris Healy <cphealy@...il.com>,
Lucas Stach <l.stach@...gutronix.de>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 6/9] drm/bridge: tc358767: Simplify error check in
tc_aux_linx_setup()
Hi Andrey,
Thank you for the patch.
On Tue, Feb 26, 2019 at 11:36:06AM -0800, Andrey Smirnov wrote:
> Tc_poll_timeout() can only return -ETIMEDOUT, so checking for other
> errors is not necessary. Drop it. No functional change intended.
Is that true given patch 1/9 in this series ? regmap_read_poll_timeout()
can also return an error from regmap_read().
> Signed-off-by: Andrey Smirnov <andrew.smirnov@...il.com>
> Cc: Archit Taneja <architt@...eaurora.org>
> Cc: Andrzej Hajda <a.hajda@...sung.com>
> Cc: Laurent Pinchart <Laurent.pinchart@...asonboard.com>
> Cc: Chris Healy <cphealy@...il.com>
> Cc: Lucas Stach <l.stach@...gutronix.de>
> Cc: dri-devel@...ts.freedesktop.org
> Cc: linux-kernel@...r.kernel.org
> ---
> drivers/gpu/drm/bridge/tc358767.c | 5 ++---
> 1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/bridge/tc358767.c b/drivers/gpu/drm/bridge/tc358767.c
> index ea30cec4a0c3..54ff95f66e30 100644
> --- a/drivers/gpu/drm/bridge/tc358767.c
> +++ b/drivers/gpu/drm/bridge/tc358767.c
> @@ -569,11 +569,10 @@ static int tc_aux_link_setup(struct tc_data *tc)
>
> ret = tc_poll_timeout(tc->regmap, DP_PHY_CTRL, PHY_RDY, PHY_RDY, 1,
> 1000);
> - if (ret == -ETIMEDOUT) {
> + if (ret) {
> dev_err(tc->dev, "Timeout waiting for PHY to become ready");
> return ret;
> - } else if (ret)
> - goto err;
> + }
>
> /* Setup AUX link */
> tc_write(DP0_AUXCFG1, AUX_RX_FILTER_EN |
--
Regards,
Laurent Pinchart
Powered by blists - more mailing lists