Received: by 10.223.176.46 with SMTP id f43csp685879wra; Fri, 26 Jan 2018 05:22:53 -0800 (PST) X-Google-Smtp-Source: AH8x227GaKf3Ilo65A6CPIAF3vKU4gr21DZTOhS4THqSLjQprFfsPJn+RKbuYsnfMCaIIAn5qHtc X-Received: by 10.99.190.76 with SMTP id g12mr16069473pgo.235.1516972973661; Fri, 26 Jan 2018 05:22:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516972973; cv=none; d=google.com; s=arc-20160816; b=Wb3l6dRkAsugoajwLVNPB30NRanPl23kty24nxVQVSefSr1DE+vJaXlzBh3dhM1UjX aZlDadavZAmRV2lW1Fk0SMwnM8ggzLocE98Ia16Ued3gbiU6OR/8fPdIRmKfYD6u1uHC gJtny/z6gp+uTeLgwn8EXqFtQU4lxGAXwZYUge54gwnTcqmzRUVuVeX+qzzvgdv6mN65 PCtwx4AjUCjHHhzeH+ZJQ3PRO0eTFOjjfOxV3ZBGcyX66zpOsLgPHco469Q74BbM6L1O 9oaYaJ5mcbUZmUaL/ZdnhyGUCI4uYqxmZHGKmMuvmY9vLxITPOONQmuA1OVWR0FYgWnl j0cg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfert-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=yeP1Saf8ws6BtsijF/0VYNmVqajBDdNEK9E+iZw5Fqk=; b=gFzgGTC+fVYcSwLCLPdjeICztX0xOJ8Ux2bqLL84k3BLx0YxGHQjD+S6cT5OSO7HSW E3U2hUJ9+/tsux7S+lhc1M5QCMqEecVEVIOM9NyxofPXhuqEqqlsGZXouP14vKNl4moO tURkmyFxxt0BHLM5Ph4TlFCyb/yrdaGSVdJ9yq3JH+MlWpDRjsr2JuGObUOv8vHicZKg FaZrfm92X9PGbE58nHN0+nFxhXnsI4B4X2DD/O9KLB7iU8mXO7H/dT4zlC7kB0bmwBng Bu8QhjOeKmnW6pHP6z7BJLjbVKywGTKwGY+cbEctiw5mOj8+geXxYwfFL9L3LQwQVoEJ kz3w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q10-v6si3830151pli.698.2018.01.26.05.22.39; Fri, 26 Jan 2018 05:22:53 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752415AbeAZNSB (ORCPT + 99 others); Fri, 26 Jan 2018 08:18:01 -0500 Received: from bhuna.collabora.co.uk ([46.235.227.227]:34374 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752310AbeAZNR6 (ORCPT ); Fri, 26 Jan 2018 08:17:58 -0500 Received: from localhost.localdomain (unknown [IPv6:2a01:e35:8a7e:4790:a8d7:ca4:7b4f:7f87]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: tescande) by bhuna.collabora.co.uk (Postfix) with ESMTPSA id 65F32274DD4; Fri, 26 Jan 2018 13:17:56 +0000 (GMT) From: Thierry Escande To: Archit Taneja , Inki Dae , Thierry Reding , Sandy Huang , Sean Paul , David Airlie , Tomasz Figa Cc: Haixia Shi , =?UTF-8?q?=C3=98rjan=20Eide?= , Zain Wang , Yakir Yang , Lin Huang , Douglas Anderson , Mark Yao , linux-kernel@vger.kernel.org, linux-rockchip@lists.infradead.org, dri-devel@lists.freedesktop.org Subject: [PATCH v2 27/43] drm/bridge: analogix_dp: Fix timeout of video streamclk config Date: Fri, 26 Jan 2018 14:16:54 +0100 Message-Id: <20180126131710.7622-28-thierry.escande@collabora.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20180126131710.7622-1-thierry.escande@collabora.com> References: <20180126131710.7622-1-thierry.escande@collabora.com> MIME-Version: 1.0 Content-Type: text/plain; charset = "utf-8" Content-Transfert-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: zain wang The STRM_VALID bit in register ANALOGIX_DP_SYS_CTL_3 may be unstable, so we may hit the error log "Timeout of video streamclk ok" since checked this unstable bit. In fact, we can go continue and the streamclk is ok if we wait enough time, it does no effect on display. Let's change this error to warn. Cc: Douglas Anderson Signed-off-by: zain wang Signed-off-by: Sean Paul Signed-off-by: Thierry Escande Reviewed-by: Andrzej Hajda --- drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/bridge/analogix/analogix_dp_core.c b/drivers/gpu/drm/bridge/analogix/analogix_dp_core.c index b2e369073854..e7ab871e62b5 100644 --- a/drivers/gpu/drm/bridge/analogix/analogix_dp_core.c +++ b/drivers/gpu/drm/bridge/analogix/analogix_dp_core.c @@ -886,9 +886,8 @@ static int analogix_dp_config_video(struct analogix_dp_device *dp) if (analogix_dp_is_slave_video_stream_clock_on(dp) == 0) break; if (timeout_loop > DP_TIMEOUT_LOOP_COUNT) { - dev_warn(dp->dev, - "Ignoring timeout of slave video streamclk ok\n"); - break; + dev_err(dp->dev, "Timeout of slave video streamclk ok\n"); + return -ETIMEDOUT; } usleep_range(1000, 1001); } @@ -920,8 +919,9 @@ static int analogix_dp_config_video(struct analogix_dp_device *dp) done_count = 0; } if (timeout_loop > DP_TIMEOUT_LOOP_COUNT) { - dev_err(dp->dev, "Timeout of video streamclk ok\n"); - return -ETIMEDOUT; + dev_warn(dp->dev, + "Ignoring timeout of video streamclk ok\n"); + break; } usleep_range(1000, 1001); -- 2.14.1