From patchwork Tue May 7 18:45:44 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Frank Li X-Patchwork-Id: 13657573 Received: from EUR04-VI1-obe.outbound.protection.outlook.com (mail-vi1eur04on2044.outbound.protection.outlook.com [40.107.8.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 39F7816F0E3; Tue, 7 May 2024 18:46:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.8.44 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715107619; cv=fail; b=F5tFo0YHnB6QXy0Y/5Ukg9lH97Z8ZNfa/3XWUAaGIt+lskRa4ABYpe696EmmwNef8akJhV7DhFvdyEWJ6yxZmAJ1TLnbFhqi1BfEmA8NlAJVcz7+qYV7CvoZkcj691RqaLlHd7fH6nRHlei1bMlHTYjUxHnD1rH/HJwtIBHIN0U= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715107619; c=relaxed/simple; bh=6PxVWHNhAUXVQqBSArIaUpWHawAqcbFt/BL4vN7KTrw=; h=From:Date:Subject:Content-Type:Message-Id:References:In-Reply-To: To:Cc:MIME-Version; b=gZLYIG8qG/xX/wmMWQw1zxdBMGfN62vTVs29hbAwdVRsyrQQ9r5L6SK8143ONdp32RYWLhnaT0+IaylazKhnQKqMlfNwbzAqaWva0Flc5I+ZlqJWMwzq0OUO+8pi5ZiauDYS1eAtiIN0l2fQ7aUOjrTNARFIx+KCEPYlqCXYptY= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=WEB15Wy+; arc=fail smtp.client-ip=40.107.8.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="WEB15Wy+" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=U4MX9g+jjk9C+QMTTHZ5xww+LblaKFr7hpLrTJmerUEbhSNtV/1AMH/v50a/Rc2nHAY7wk2UGkfe00QzqOmn9JrGhCeihYtqsGpkypFIZe5b9KpMoJejMEM+H1r67JwEIJJf2alg3IuReJ7eACnE2EqWmN5G6Ni8xTF8JfhmVwhVoDXFHuGyAdFVmAoQK+S+av6hZclT06FjRSxexsuBoem2qQq48sPlJmnTu6/CGiqyLs/ep40Q477B3xchYMWM6xZk/Hsr0FeJieCpyOfTizxyhGTQHzNOAYSfkqKicBqfGEBHnGEs1envvp5C1tkrxUtQxQP/l+xqZ27XLKKzbg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=No1e6ggxcaWM6w5fhc2pL0xcstqCy/cseH/nZ7iA8to=; b=aqqeCNyumq6CPqj9pUE3L73D1ci7/D06Lln1rZTL5V47E7ynk63mKG0IbaAEaIUjEQlR0Fh07rHdSfncUuAM+IMT9Ms+ee9eo4C9U9G5o+OpyXntLeuAtJq/6WD0714wLCwj56pAsbEl5ecVUzvPX6FrrDQ6+gBvVXrV1ib4HeNyI7CKD8R5//FGHI0w47P1b8DGwG7OSLL0SF2Ay+YRPiCHM+ZwiHi08CEfWewn7fSu1njXNrHUqB0byGxXzehp851deDD1Em4hcv2weDZvsVsnyklqS425xlF2FznmuPwzoYoOE28mHqLA0ixLrV50NqQ1uFS5pqJhy5TZXct0gA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=No1e6ggxcaWM6w5fhc2pL0xcstqCy/cseH/nZ7iA8to=; b=WEB15Wy+argoIz62i/qYWNa6CbiwqKMHlQyZ8XXOfBYDIu8rRkUSsV/kqUS7TzQQdl0YSbh2zjk1ReWqJTAch2EvGUTtCbsTkCsSpGOpRPTEMgcPpqZykK/5tnZWOR8coOnWOPDi3Cx4oy1MtdqJsdxb6YIU1TXFjMl15uScl2U= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) by DU0PR04MB9636.eurprd04.prod.outlook.com (2603:10a6:10:320::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7544.41; Tue, 7 May 2024 18:46:54 +0000 Received: from PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::1e67:dfc9:d0c1:fe58]) by PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::1e67:dfc9:d0c1:fe58%7]) with mapi id 15.20.7544.041; Tue, 7 May 2024 18:46:54 +0000 From: Frank Li Date: Tue, 07 May 2024 14:45:44 -0400 Subject: [PATCH v4 06/12] PCI: imx6: Improve comment for workaround ERR010728 Message-Id: <20240507-pci2_upstream-v4-6-e8c80d874057@nxp.com> References: <20240507-pci2_upstream-v4-0-e8c80d874057@nxp.com> In-Reply-To: <20240507-pci2_upstream-v4-0-e8c80d874057@nxp.com> To: Richard Zhu , Lucas Stach , Lorenzo Pieralisi , =?utf-8?q?Krzysztof_Wilczy?= =?utf-8?q?=C5=84ski?= , Rob Herring , Bjorn Helgaas , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Philipp Zabel , Liam Girdwood , Mark Brown , Manivannan Sadhasivam , Krzysztof Kozlowski , Conor Dooley Cc: linux-pci@vger.kernel.org, imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, bpf@vger.kernel.org, devicetree@vger.kernel.org, Frank Li X-Mailer: b4 0.13-dev-e586c X-Developer-Signature: v=1; a=ed25519-sha256; t=1715107574; l=1779; i=Frank.Li@nxp.com; s=20240130; h=from:subject:message-id; bh=6PxVWHNhAUXVQqBSArIaUpWHawAqcbFt/BL4vN7KTrw=; b=dpNV5b7Bcq3i+CJaFrMuFzOmeJ6VpzfhNg34d2e3wRjWnU0GZTkhcGKtpAUhtZZx45/Bkr5Ol WJicUuCTpvxBJsXNiunlXbJq7f8T69owYCw67y5cKdixklWYeoW+KGg X-Developer-Key: i=Frank.Li@nxp.com; a=ed25519; pk=I0L1sDUfPxpAkRvPKy7MdauTuSENRq+DnA+G4qcS94Q= X-ClientProxiedBy: BY5PR17CA0026.namprd17.prod.outlook.com (2603:10b6:a03:1b8::39) To PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) Precedence: bulk X-Mailing-List: bpf@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PAXPR04MB9642:EE_|DU0PR04MB9636:EE_ X-MS-Office365-Filtering-Correlation-Id: 6cfba788-ca66-41e4-9ab7-08dc6ec610a6 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230031|1800799015|376005|7416005|52116005|366007|921011|38350700005; X-Microsoft-Antispam-Message-Info: =?utf-8?q?wfW7UHugsY80yA2WUgebMYR/I/2hV18?= =?utf-8?q?Kb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jqbCHGiJlPCnH1/rJ9qvlSW1op4NzvGn84fZV0WcVbeHESl/IaG+SX?= =?utf-8?q?U4RtvF/U+NX66/xUzZD6JmJIxit2NFPfkulE3ppY5nb2CVpA7KWvhhYJBdFXBMh4n?= =?utf-8?q?kSRVC1NaOIoPYJ0GG+cSMRNqOW6duCf47SqejkfpVj/cCZJIqZYk/fIWmm4LWVuoh?= =?utf-8?q?7Bb70JwULWTicpqrj2StIms10E+rdw23rYlVcm/q2B/+4rBeoCy5NaG6SfTVuuxCU?= =?utf-8?q?ahmghuYPlcf/8eW+nc5qlqb/go0tgg2SFE80zKiV3JLdBnae+dQ5RjS5L2UGrb6VA?= =?utf-8?q?q1d6OFK6LcrIDCKSAgqHV7RKbEzwphDv9Ud73/DI9UgAkyav+OUqjKILD302BWbNd?= =?utf-8?q?d6QRD0C5H6Ax01sGhSntw609WR8alYBOdhA=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PAXPR04MB9642.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(1800799015)(376005)(7416005)(52116005)(366007)(921011)(38350700005);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?AdQG/V+pfeM1VPQr+jI1SV3RIx7Q?= =?utf-8?q?UKOq1OKRkhPXRzYVDDxUW/haAeUNbd8NCZYm49EGpedBI0GEuHKUtMeIR1Og8VLOx?= =?utf-8?q?qO/tWtOGnnOB1lfxzCsYNeGuZW+4HAYZKpVhinWhpzN95FwAsCPs9ishe2KR7661W?= =?utf-8?q?UCu7e301tyX+KimN+sHcRk/IV8wIMfxW6RGRLEpdbOPZqKpT8BIQLrxtKUvCSkHOc?= =?utf-8?q?VPmUcp2AzygznGmz+42s/2RpcKnMQFEr79ReO8C5oMxS6rjDXZ9u7ghecwlSiNxIH?= =?utf-8?q?c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8?q?N8ZO+L6s/X9aVLoJpI5ec1d/2CK3/2cba6ufa23prXeb75MJjkdaZ20RtcfLl1QD0?= =?utf-8?q?jvhwRIpnSaDgpU9k8EnB3rNEBgExtpvWUDuxmqdNj2p+PhaHXyv8oHZkiHtHF0tCj?= =?utf-8?q?2oE+1633N8m38AH8MPDYn5AE1WctYFCdJzhdE4f+4bBpPuaZSsrNZllLKQOHooxBu?= =?utf-8?q?OvceuzDPyq9Qiv4oCLmYGrWCk0Vy0VlBPr1/lpyhYZBkPDBxfgofwx0rDu0Yj9O/u?= =?utf-8?q?Fd37vjBXvj52fSEpNhFlRIuP/IsBNbAvpRhuiw6fzRfBg9Lk+fVpGwpJkqVypQroF?= =?utf-8?q?F6Xn0E8mOUvuP97wlwxmhL8gEYq/Mq4xZD/Z7W78DYkdpHReDefhKp9kxfaDcO3c5?= =?utf-8?q?hzc6rhimj7zN?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 6cfba788-ca66-41e4-9ab7-08dc6ec610a6 X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB9642.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 May 2024 18:46:54.2410 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 9Ur58RFRXbUWyNqOIZIDMk+veh+BF0b3gVqfX5l4fG30qrzrZ4kRFvYV0YEKB3d24eN3WfpZaEQxHpKnzsG84A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU0PR04MB9636 Improve comment about workaround ERR010727 by using official errata document content. Signed-off-by: Frank Li --- drivers/pci/controller/dwc/pci-imx6.c | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/drivers/pci/controller/dwc/pci-imx6.c b/drivers/pci/controller/dwc/pci-imx6.c index 7396f0d51119a..d074bcc34d7a7 100644 --- a/drivers/pci/controller/dwc/pci-imx6.c +++ b/drivers/pci/controller/dwc/pci-imx6.c @@ -715,9 +715,25 @@ static int imx7d_pcie_core_reset(struct imx_pcie *imx_pcie, bool assert) return 0; /* - * Workaround for ERR010728, failure of PCI-e PLL VCO to - * oscillate, especially when cold. This turns off "Duty-cycle - * Corrector" and other mysterious undocumented things. + * Workaround for ERR010728 (IMX7DS_2N09P, Rev. 1.1, 4/2023): + * + * PCIe: PLL may fail to lock under corner conditions Initial VCO + * oscillation may fail under corner conditions such as cold + * temperature which will cause the PCIe PLL fail to lock in the + * initialization phase. + * + * The Duty-cycle Corrector calibration must be disabled. + * + * 1. De-assert the G_RST signal by clearing + * SRC_PCIEPHY_RCR[PCIEPHY_G_RST]. + * 2. De-assert DCC_FB_EN by writing data “0x29” to the register + * address 0x306d0014 (PCIE_PHY_CMN_REG4). + * 3. Assert RX_EQS, RX_EQ_SEL by writing data “0x48” to the register + * address 0x306d0090 (PCIE_PHY_CMN_REG24). + * 4. Assert ATT_MODE by writing data “0xbc” to the register + * address 0x306d0098 (PCIE_PHY_CMN_REG26). + * 5. De-assert the CMN_RST signal by clearing register bit + * SRC_PCIEPHY_RCR[PCIEPHY_BTN] */ if (likely(imx_pcie->phy_base)) {