From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D76BFC2BA83 for ; Thu, 13 Feb 2020 16:07:12 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id AFA92206ED for ; Thu, 13 Feb 2020 16:07:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581610032; bh=h1jvcIZdjodHYjLypghcVkFJ+zkW2H7PdFtEX+iSY20=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=Euw0/DZvMBgRBta48FZCSGWEdd3ScZz/PEiCQue3gZqSG4NVthtIgSn8k6IgqOl09 JYHElwIVQ/yxqguaIHQvjSy1txyHReK5vxPlVTtMYuelJ/wLP+8P7pEFRoo8GcKBVF zqdl/E+SuGn635TnyDX3F/bG8TTBTHQ4dW5UG318= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728393AbgBMPX2 (ORCPT ); Thu, 13 Feb 2020 10:23:28 -0500 Received: from mail.kernel.org ([198.145.29.99]:34670 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728388AbgBMPX2 (ORCPT ); Thu, 13 Feb 2020 10:23:28 -0500 Received: from localhost (unknown [104.132.1.104]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 7ED2F2469A; Thu, 13 Feb 2020 15:23:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581607407; bh=h1jvcIZdjodHYjLypghcVkFJ+zkW2H7PdFtEX+iSY20=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=2rG0zJjwmX26fT/yBsZezx9owal79C6Zhf6GNdyy7+TkULLTFFoxpaAuTPRwlh7sO ozv6Jcvi603QF2FTr9pK+1uMfpueMqdDT6s3adJNNu9H6R4SECx/L7Dm0AcMAKCk2z xZAZbMEViRqFwhAHiwYvAEnSNFZlCyTx4o5KB8nI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Yurii Monakov , Lorenzo Pieralisi , Andrew Murray , Sasha Levin Subject: [PATCH 4.9 027/116] PCI: keystone: Fix link training retries initiation Date: Thu, 13 Feb 2020 07:19:31 -0800 Message-Id: <20200213151853.493272633@linuxfoundation.org> X-Mailer: git-send-email 2.25.0 In-Reply-To: <20200213151842.259660170@linuxfoundation.org> References: <20200213151842.259660170@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Yurii Monakov [ Upstream commit 6df19872d881641e6394f93ef2938cffcbdae5bb ] ks_pcie_stop_link() function does not clear LTSSM_EN_VAL bit so link training was not triggered more than once after startup. In configurations where link can be unstable during early boot, for example, under low temperature, it will never be established. Fixes: 0c4ffcfe1fbc ("PCI: keystone: Add TI Keystone PCIe driver") Signed-off-by: Yurii Monakov Signed-off-by: Lorenzo Pieralisi Acked-by: Andrew Murray Cc: stable@vger.kernel.org Signed-off-by: Sasha Levin --- drivers/pci/host/pci-keystone-dw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pci/host/pci-keystone-dw.c b/drivers/pci/host/pci-keystone-dw.c index 9397c46671062..f011a8780ff53 100644 --- a/drivers/pci/host/pci-keystone-dw.c +++ b/drivers/pci/host/pci-keystone-dw.c @@ -502,7 +502,7 @@ void ks_dw_pcie_initiate_link_train(struct keystone_pcie *ks_pcie) /* Disable Link training */ val = ks_dw_app_readl(ks_pcie, CMD_STATUS); val &= ~LTSSM_EN_VAL; - ks_dw_app_writel(ks_pcie, CMD_STATUS, LTSSM_EN_VAL | val); + ks_dw_app_writel(ks_pcie, CMD_STATUS, val); /* Initiate Link Training */ val = ks_dw_app_readl(ks_pcie, CMD_STATUS); -- 2.20.1