Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp770673pxb; Tue, 5 Apr 2022 22:35:59 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzvwlgn2ReHWq1N7kdlBEnACM/3LO7G8nTtEbof0gEhVvC+u/xOi3fwUsDiUxea+UhwVsxR X-Received: by 2002:a17:90a:380d:b0:1c9:d9bb:7602 with SMTP id w13-20020a17090a380d00b001c9d9bb7602mr7863951pjb.216.1649223359199; Tue, 05 Apr 2022 22:35:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649223359; cv=none; d=google.com; s=arc-20160816; b=LkGQYtxNA8LqeBKl6pCi4zOEsBA6YfrMSSA79URMXd3f5HyL5ZvZm3F9V4HiF+aD3L yqka0ml4KsPHcQ0xTsQNX+S6oMbs3gim7UXRYrljneqaWD/u7eTzr6UeQmYAzStG9w4S CP7qVNVkzKv8vRB/+dSZ8ECkRtGIa5eMAx05jHaajrD19FLMaPE2HE9IUMYqGOQLz1Z7 lYBEkEMvrnI0FR7NhV14d1Wup+hK8Li4r1c4e3DS8sVEjzViB39zHVr9CYd9jYDERUnV 7jbhZG6vzRdM7lpfvdhyNUvqUCp2ZwVMJ8/k/jLRuTkEpyF8LEzZ4GmHWMevxAsk0Llv SQOQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=HJeULbTzAE7BYd7u5VJkHSoZfJ60fVPg15039KfFTQc=; b=QY/JmfC0IaPWWo7BhXxm55ISuBMX8wgBVZ3sDYGjoVtFNnBD+5fHC1rcSf2Pw10YWx R8Fmhihb33Sw0EoF/CZh3VyllAa5ewvP0OtU30DhNz1QCVc46D3EDyrpdlnCNwmyGPDd NBK2G/DNP6re7/5NbCNJIq5LXdZfUoY1jfVo4O2s6E1cZ3GIlvjcQxHHuYiN4DO2Vd5E n7LCtr0T+ac8fF9jfDkLCO9Vj7oSps6lcs0mCYLf4mUVOJL168HwNw0sW2lNP7FXyKwe 5ITmNrnQxHdMMPFYDxi9eyc67CITALHvhcNSmun+GbLIksjUX8Oc4sXm2pArH1Ruby4C ZmjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=2Rm32ttE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id bm21-20020a656e95000000b0039958468eccsi4851253pgb.100.2022.04.05.22.35.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Apr 2022 22:35:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=2Rm32ttE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 0A4FB305B3D; Tue, 5 Apr 2022 21:25:15 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1839978AbiDFBGi (ORCPT + 99 others); Tue, 5 Apr 2022 21:06:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47556 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1349069AbiDEJtD (ORCPT ); Tue, 5 Apr 2022 05:49:03 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 10345A94F7; Tue, 5 Apr 2022 02:39:48 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id A3A31615E5; Tue, 5 Apr 2022 09:39:47 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B852EC385A2; Tue, 5 Apr 2022 09:39:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1649151587; bh=D9X4N7CjniGGLjHiUlduDQRYx7n6Zjs8euUw2wDCyR0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=2Rm32ttEIbYYPiaEsX4YQUeoW0a8uBb9Y8YqSScfYGOedQEWc9VrCoBag+JU6gGsj rKtIs03XexKrQ43z6eO2c58H+7YsEYJdsMzYDnHpk5EzjA6/DORu2xTbfBGKazj7Lz f7ZdFTtaDj4ome4CYeIDrovGr49sN1n4pyutkjHo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Kuogee Hsieh , Stephen Boyd , Dmitry Baryshkov , Sasha Levin Subject: [PATCH 5.15 470/913] drm/msm/dp: stop link training after link training 2 failed Date: Tue, 5 Apr 2022 09:25:32 +0200 Message-Id: <20220405070353.943570972@linuxfoundation.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220405070339.801210740@linuxfoundation.org> References: <20220405070339.801210740@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Kuogee Hsieh [ Upstream commit 9051d629dbf7a998a40f7eac65a9512b01bc3bb8 ] Each DP link training contains link training 1 followed by link training 2. There is maximum of 5 retries of DP link training before declared link training failed. It is required to stop link training at end of link training 2 if it is failed so that next link training 1 can start freshly. This patch fixes link compliance test case 4.3.1.13 (Source Device Link Training EQ Fallback Test). Changes in v10: -- group into one series Changes in v11: -- drop drm/msm/dp: dp_link_parse_sink_count() return immediately if aux read Fixes: 2e0adc765d88 ("drm/msm/dp: do not end dp link training until video is ready") Signed-off-by: Kuogee Hsieh Reviewed-by: Stephen Boyd Link: https://lore.kernel.org/r/1642531648-8448-5-git-send-email-quic_khsieh@quicinc.com Signed-off-by: Dmitry Baryshkov Signed-off-by: Sasha Levin --- drivers/gpu/drm/msm/dp/dp_ctrl.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/msm/dp/dp_ctrl.c b/drivers/gpu/drm/msm/dp/dp_ctrl.c index 62e75dc8afc6..4af281d97493 100644 --- a/drivers/gpu/drm/msm/dp/dp_ctrl.c +++ b/drivers/gpu/drm/msm/dp/dp_ctrl.c @@ -1744,6 +1744,9 @@ int dp_ctrl_on_link(struct dp_ctrl *dp_ctrl) /* end with failure */ break; /* lane == 1 already */ } + + /* stop link training before start re training */ + dp_ctrl_clear_training_pattern(ctrl); } } -- 2.34.1