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=-10.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 D9B33C4727C for ; Tue, 29 Sep 2020 15:04:34 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 55F742075F for ; Tue, 29 Sep 2020 15:04:34 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="0cTn3xl9"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="ffqPonC9" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 55F742075F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Message-ID:Subject:To:From: Date:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References:List-Owner; bh=At6BQU++ub+MWw0Cch5uaDLaZO0aH5ZkM21YKf7hhzA=; b=0cTn3xl9SEkddsofqQ01JEg7a HIgRhOZ7E4D9lhLZX/nNurmClv5mHRo10lMBbTELKBEweFrowswOFxWrLK4+a9tOvz7g91SAUJmyY puNTvcvANOIkxHIgN4OAi4SzLaVhkF6VNbSsgtuU8/p2zshBW35j0tc0tww5pW5JB6uERkB8MZjO6 NyWT1sMi4jRJ/rWHkfBtyBAVJRUTjsDZWmaMandknjmXXThtSw5Nd++EMR0kVCKuNFdRx/xHN+WmA B7Hpp4oCTgHICSgwqnIaPagSXJqwGeV51qy4pt+xM0EZCx2g8tAmLsDId6hSGHUMpdfqsFEBrs+Ig Z+JMaQTJA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kNH9f-0007XS-15; Tue, 29 Sep 2020 15:02:59 +0000 Received: from mail.kernel.org ([198.145.29.99]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kNH9b-0007WX-Gi for linux-arm-kernel@lists.infradead.org; Tue, 29 Sep 2020 15:02:56 +0000 Received: from localhost (52.sub-72-107-123.myvzw.com [72.107.123.52]) (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 42B3C2075F; Tue, 29 Sep 2020 15:02:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1601391774; bh=NXldqJpYGauanSfTEPI04TFDaHThUR0ilLTddf/V0s8=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=ffqPonC9r3hF2Lzzq3xl0JqoVcOpCGe/mkvAwevJ5pIIXmwau4aF7zCutg2qWnEWC 4W12P5AOZEv8gHl3px6WzjtotcSPwF3Kasl4xiobIPt8d/AmtO4WwBJxf3TVVWhGcJ S1rBe+wQagOJUgpVh2pqyRa0CeYajsOpwy49Xs20= Date: Tue, 29 Sep 2020 10:02:52 -0500 From: Bjorn Helgaas To: Zhiqiang Hou Subject: Re: [PATCH] PCI: layerscape: Change back to the default error response behavior Message-ID: <20200929150252.GA2540544@bjorn-Precision-5520> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20200929131328.13779-1-Zhiqiang.Hou@nxp.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200929_110255_704691_CF26062E X-CRM114-Status: GOOD ( 25.85 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: robh@kernel.org, lorenzo.pieralisi@arm.com, roy.zang@nxp.com, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, leoyang.li@nxp.com, minghuan.Lian@nxp.com, mingkai.hu@nxp.com, bhelgaas@google.com, linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, Sep 29, 2020 at 09:13:28PM +0800, Zhiqiang Hou wrote: > From: Hou Zhiqiang > > In the current error response behavior, it will send a SLVERR response > to device's internal AXI slave system interface when the PCIe controller > experiences an erroneous completion (UR, CA and CT) from an external > completer for its outbound non-posted request, which will result in > SError and crash the kernel directly. Possible wording: As currently configured, when the PCIe controller receives a Completion with UR or CA status, or a Completion Timeout occurs, it sends a SLVERR response to the internal AXI slave system interface, which results in SError and a kernel crash. Please add a blank line between paragraphs, and s/This patch change back it/Change it/ below. > This patch change back it to the default behavior to increase the > robustness of the kernel. In the default behavior, it always sends an > OKAY response to the internal AXI slave interface when the controller > gets these erroneous completions. And the AER driver will report and > try to recover these errors. This reverts 84d897d69938 ("PCI: layerscape: Change default error response behavior"), so please mention that in the commit log, probably as: Fixes: 84d897d69938 ("PCI: layerscape: Change default error response behavior") Maybe it also needs a stable tag, e.g., v4.15+? Since this is a pure revert, whatever problem 84d897d69938 fixed must now be fixed in some other way. Otherwise, this revert would just be reintroducing the problem fixed by 84d897d69938. This commit log should mention that what that other fix is. AER is only a reporting mechanism, it is asynchronous to the instruction stream, and it's optional (may not be implemented in the hardware, and may not be supported by the kernel), so I'm not super convinced that it can be the answer to this problem. > Signed-off-by: Hou Zhiqiang > --- > drivers/pci/controller/dwc/pci-layerscape.c | 11 ----------- > 1 file changed, 11 deletions(-) > > diff --git a/drivers/pci/controller/dwc/pci-layerscape.c b/drivers/pci/controller/dwc/pci-layerscape.c > index f24f79a70d9a..e92ab8a77046 100644 > --- a/drivers/pci/controller/dwc/pci-layerscape.c > +++ b/drivers/pci/controller/dwc/pci-layerscape.c > @@ -30,8 +30,6 @@ > > /* PEX Internal Configuration Registers */ > #define PCIE_STRFMR1 0x71c /* Symbol Timer & Filter Mask Register1 */ > -#define PCIE_ABSERR 0x8d0 /* Bridge Slave Error Response Register */ > -#define PCIE_ABSERR_SETTING 0x9401 /* Forward error of non-posted request */ > > #define PCIE_IATU_NUM 6 > > @@ -123,14 +121,6 @@ static int ls_pcie_link_up(struct dw_pcie *pci) > return 1; > } > > -/* Forward error response of outbound non-posted requests */ > -static void ls_pcie_fix_error_response(struct ls_pcie *pcie) > -{ > - struct dw_pcie *pci = pcie->pci; > - > - iowrite32(PCIE_ABSERR_SETTING, pci->dbi_base + PCIE_ABSERR); > -} > - > static int ls_pcie_host_init(struct pcie_port *pp) > { > struct dw_pcie *pci = to_dw_pcie_from_pp(pp); > @@ -142,7 +132,6 @@ static int ls_pcie_host_init(struct pcie_port *pp) > * dw_pcie_setup_rc() will reconfigure the outbound windows. > */ > ls_pcie_disable_outbound_atus(pcie); > - ls_pcie_fix_error_response(pcie); > > dw_pcie_dbi_ro_wr_en(pci); > ls_pcie_clear_multifunction(pcie); > -- > 2.17.1 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel