From patchwork Fri Jul 24 18:51:14 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682859 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9B31A912 for ; Fri, 24 Jul 2020 10:37:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 7E6602074B for ; Fri, 24 Jul 2020 10:37:24 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="GMtHJ9yC" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726987AbgGXKhT (ORCPT ); Fri, 24 Jul 2020 06:37:19 -0400 Received: from mail-eopbgr80079.outbound.protection.outlook.com ([40.107.8.79]:9696 "EHLO EUR04-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726329AbgGXKhS (ORCPT ); Fri, 24 Jul 2020 06:37:18 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KmCy8F0C7o2jKZO2nKEkHTCUwzxlg4HkKv0hxGKDUQvNLafILwpZjM+0hMKzU3z48hSvkuFlujQqak7P1GmQ4v8cxkBi6bx18PZ4bBuDetd4Q1sAcbL2HJ2fRKZ66hp9XNc+5dihk3eYQC1jxxZ/ZYcHTb48u5wriSMDEYpH8uvU9bA2XmJ19QzJv1qvO2myhyOL1LJUajlyroXUheOXNbimYgRrUN0RnB6kgWNJ/yI7rp5XzvNceGcAg/R1RQ1DWzL2koLxPbJC5aDUPcydm49Hi0Avj9oq2L384nnK6h2ojuOHwrIs8apdOjDoz1IkP1yNVjODnJD/6O1QUdTKiA== 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-SenderADCheck; bh=0izcWiIsFhbVumJfO4SdrrpucrmDe3nP9In+ncyqnZw=; b=Dd0FnDmadFViUZng07lS8pLrDQAHlURW0NphXgeHAazLy0O/eyrWwLn5FvfwHd5tNfDuppjguD6jH2BsIh+u1fJaZd3SQ2Lr+B0j3td9qw1RA+alarGJL8wMFoVTP+liwWJuHSiLuqZisis22DActH3Qa1pBUF3DJZyOt/iqUee69m1hvD6toeVObZqZ3Zbw8tSv5sFWbgMf6n4IU1OpmEu/vOGTH0+5+PfI7PHMZJicnHW6vNXYNplwR0ugdAwmbwU6MjvHiMrWsTWdfRbS9eoMqlGO63RCN58CZyHVa6ViaIFNZY/s1qpfBx6HtsekwkQhlqu9rkEnZ+LD1TRzrA== 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=0izcWiIsFhbVumJfO4SdrrpucrmDe3nP9In+ncyqnZw=; b=GMtHJ9yCGrIblEHo9JpgmVxUrDu5hOl+oaJExSrXXbfLqY+9xg2nTp+uzResNx5TZoILZEJLGeOxnJ0b8LxxjrpRb8V03UnT+sefCOeTvsMiNxGJs9KnI3l4cwTwQLC1s6PKPRLakWyWNR6lIBQlJFHXhg9ItszwnCOulpsbY4Q= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:37:15 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:37:15 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 01/12] Revert "ARM: dts: imx6q: Use correct SDMA script for SPI5 core" Date: Sat, 25 Jul 2020 02:51:14 +0800 Message-Id: <1595616685-9987-2-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:37:09 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 252a32a4-daeb-48f7-e291-08d82fbd87c8 X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:660; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 9j1penTa7bvwP8flPQakT618aIQQWC3NqwSuU6Y9sukZanc2bl4bMqE+W3RSoH8wKIe5+SYapLAJUNwbiZyj3if9qclFn/A/keV7DO/3Lojmp7kvdoIdMmh69ss4efixfAwH4s3kirwCI4ag34WfOZE1pSse//Gnl18+eD/U/ELxPwR1T0rXg8v5laXsvGABQtWYHrkwnHG7EG2KIpfhNWkQnbsAQwxQu33oKKTD1tcZxTjaleO9B+9SDkCQFFZzOdnlRL6OwbiSHYuwfjE87yzRgARfK/wFtQEgY87+tWbl8OAIeSs48Vmp8zytR4C/aMLdsPNZcDATV4Vvn5JyGre3reDtr5+S5VPjfrIfzXNKniJNwR7sqx7m/QEfAzxh5xfDBb9lWwCWUA8OFKwwZy0kUM4N84IXExCFzSqoq1qf2bt4lOcBKKBFpW5zAZAbMmdb3GseSFTXM1jMl2RGujYPTogfQJnzSHmSbKB0Be0= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(83380400001)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(32563001)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: GMYROg28qegConl9DtP8vkZgr5gA4shB62xaTQl/NhAOilZbtrEBYWjqFr594wV8shUT//AFhne/VkWUeydINeh+H9s4FiU4kqk8uKyABxm3Tm6r5+9MTIm23sM5teWDj2Fykr6APx8LwZljN6aQs/G7LYoFZiznyKCqWho0Q2TVvElxA2sYzSeyWICTzBNMkH865zGrulJZuFZfxBT6BqjAcND6z8RXx4xchjbhNgLxMvMtDQYtZYuwsU3SQqls4oJ6PwbDFdmIoZ3mnMgM3VA1pKUGoZymzf2VHkNQAyvbRPrPIrqlkZTKUbjtbTyxeScQS1/XwjXr396SyzCSFZuhsgRww4oYbfKxSLLTiRqTdGh+S61eACSv7u0r/M79Vj2R2wuJxc2F4nrL4Eo5KEWqn7S98YqSMwJyAwy15aJcGLmLsfLArtFzmKh+jKW6+irVE9KssY7P7MLwTRti/s8O1QA6usu8twONwgNaDs0= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 252a32a4-daeb-48f7-e291-08d82fbd87c8 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:37:15.1056 (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: bPkegzei+Ihbgxah4LQgR1OyFJ07MgZM5yx0gG5O11DtFVQgRm7K1exLH3/FvwHq1npw8WojpeBtMsrdP5UHag== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org There are two ways for SDMA accessing SPBA devices: one is SDMA->AIPS ->SPBA(masterA port), another is SDMA->SPBA(masterC port). Please refer to the 'Figure 58-1. i.MX 6Dual/6Quad SPBA connectivity' of i.mx6DQ Reference Manual. SDMA provide the corresponding app_2_mcu/mcu_2_app and shp_2_mcu/mcu_2_shp script for such two options. So both AIPS and SPBA scripts should keep the same behaviour, the issue only caught in AIPS script sounds not solide. The issue is more likely as the ecspi errata ERR009165(http://www.nxp.com/docs/en/errata/IMX6DQCE.pdf): eCSPI: TXFIFO empty flag glitch can cause the current FIFO transfer to be sent twice So revert commit 'df07101e1c4a' firstly. Signed-off-by: Robin Gong Acked-by: Sascha Hauer --- arch/arm/boot/dts/imx6q.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/boot/dts/imx6q.dtsi b/arch/arm/boot/dts/imx6q.dtsi index 78a4d64..afdd9eb 100644 --- a/arch/arm/boot/dts/imx6q.dtsi +++ b/arch/arm/boot/dts/imx6q.dtsi @@ -177,7 +177,7 @@ clocks = <&clks IMX6Q_CLK_ECSPI5>, <&clks IMX6Q_CLK_ECSPI5>; clock-names = "ipg", "per"; - dmas = <&sdma 11 8 1>, <&sdma 12 8 2>; + dmas = <&sdma 11 7 1>, <&sdma 12 7 2>; dma-names = "rx", "tx"; status = "disabled"; }; From patchwork Fri Jul 24 18:51:15 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682861 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3EAD7912 for ; Fri, 24 Jul 2020 10:37:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 206ED20768 for ; Fri, 24 Jul 2020 10:37:28 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="HF1zcm/C" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727781AbgGXKh1 (ORCPT ); Fri, 24 Jul 2020 06:37:27 -0400 Received: from mail-eopbgr140045.outbound.protection.outlook.com ([40.107.14.45]:32999 "EHLO EUR01-VE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726329AbgGXKh1 (ORCPT ); Fri, 24 Jul 2020 06:37:27 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=L9UxHnw44h3c9OFzpxccBz3cX62TDEl+dkEk7ujQLBB47i9FEciJKM6SdXnwiz36Se8I5vz3tMmo+lIWtkW6TeBCniSoI95twopK8hJOQS3rM3qt+TDweZYlJH2YBBauSHiDku+x6HzrcQRy0gepuYIZc8ImnsOxMUmhfFe7cZylT0sOkNOkDmxCS4Afrj+jmhWTXP3KU6niSNAPl5oap0bkXHBxSojIPIie0WCmEKuTVFvF0aZAhn6vQQ47h2wK/p90CQtRTy95Q6ZcixE8qGlsOLXyQS1bqDbQkhHW29byYLyHHf9xT9QYngnFKXvXEiRqJMlasm94Hu9FKf98Hw== 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-SenderADCheck; bh=VfdptsqF/BWMVGMcs2QnzmQDQwBwZuTq/BYSygQZL8U=; b=SU2fr/xOzWRXd24Doy8d5QHs5SG1x34MEu4zNQ0vnt0QqE/RKepXo1u93xzh8qpW8YfWrXdZwUCCjDJxotH2sg83ItmYBUHosgbE24Gh06A+32+laeKwEYXeyjYDT8XeI4A5s/KpFRWzSllZgwcbQQVBBllBBACzID/e94i86ccU8zfnWi2xj7TtoZ5I2l/oaUTpEOZOZ5MKRAk8xltecWVIGNMrLMYXnZBNVFla8gJnsK/cOnZRgugDQmhCAt4X5ITQK6JZxWd4LVPLvB15OSo/5ucrM+2rg7kQD8jr+VtLCaw6mpbKzT8xbMW7ueeKVJ76Zs1ulIHaB0vfPGqwVQ== 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=VfdptsqF/BWMVGMcs2QnzmQDQwBwZuTq/BYSygQZL8U=; b=HF1zcm/C3BQex8EN9UNDgiJh2pr+Y3f3uFuSx+YMYaGT1Hzxq/EuGc50Kywrv2zy6Bvu2ikvkqSC9EZ1GnmlZf0fEiUHFkkYMBoXu5A8i1XlW5jUaUmQ19r+HFsc6crco6BpFT7z/r43+OklM7eIWsDkxoysCibN9uokWXUxiSQ= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR04MB6125.eurprd04.prod.outlook.com (2603:10a6:803:f9::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.23; Fri, 24 Jul 2020 10:37:21 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:37:21 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 02/12] Revert "ARM: dts: imx6: Use correct SDMA script for SPI cores" Date: Sat, 25 Jul 2020 02:51:15 +0800 Message-Id: <1595616685-9987-3-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:37:15 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 96fe318e-43a6-4ff2-2e42-08d82fbd8b65 X-MS-TrafficTypeDiagnostic: VI1PR04MB6125: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:660; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: vzbXsT7+zf+ZHjU6zQfKrwho2q7Ed2/yuluu7k51QGi/inXyMa5xHQ6aOT7TOCzUdp0j3cRez/1gVwHR4AreJmBYFO1/6cYbE+vQ63dIl/TdA98I/wVPqzzho3Y+F4uGUGJTi2HCZt9bz0COlAQjBbq92Llw3If9vVggqlOtzvh7eM0TjnDURM07b7g14ftY7PixpS1k+GeVB0bXTwjPdt5m0ExELF1q9T+RU2hOqQQtKZRwYKVFFmJzTSDwDafF2dI86xmIhWijbAimXel1bQvm8ZsbtWOAAZrOo+kdNpLL37jxJSkvhW8G2AWo9OrWkIPX/U0EkVyLpvwA/fpQJGACUHMB3T32hAl6rV6OVjhgGrlUPBJD3ZWfV65GinSOMuMyweOQmtl639dVNjsOG27sbmbFALc2YLJtEUrWMQk/hVhjEzFGk6V0ggT4J3lN7aAAw5BjTRcqftnxykMU5w== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(366004)(396003)(136003)(39860400002)(346002)(376002)(6486002)(478600001)(8676002)(2906002)(8936002)(6506007)(86362001)(2616005)(26005)(956004)(6512007)(83380400001)(316002)(186003)(16526019)(36756003)(4326008)(52116002)(5660300002)(66556008)(66946007)(66476007)(7416002)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: SN60KlTb6l5n9hDKZMDP1JS84gVHoC0Q4Mq2w4G1n3kKHOMo2LQadr4yiuQfgPdAQbVnq+i3LVQwFnesO9Ys9M9Meu9vePJMlrpxcqJMv+16PsO5q622KpVPcS2g81yDUkPwqwqMc4D2FDt7s9LyDIsyUD3hb8x4Zt34eAbDC+NoJD/fXDKsVanq41g5fFTw5iF/VI84Po6+954c5LbiH2uJPLKmQwR7auic1jBcqB5JhsFVXbvLihQiNs0REdSptZz0KxQLMAYEOdSvnFO5rrUkqKl1ph4PJepP49qbMa9m0ary3Lve17jwcoQS4BlZW8WXY0Fg1dfMbrdGe9ZYRW0NpvOeWZzISRoJUUa67H6uakQsF7kQjUMOGl0osN4YvCi0sPhFYf2AegoU/txPHw9emESJ8k9bsKPFKUTpaOcUBeI7ci2/AkruI+8mZ1ZcnRU26CFIA67U4mizv0AA+2HKByUWckpOeh0WG9Nem8U= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 96fe318e-43a6-4ff2-2e42-08d82fbd8b65 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:37:20.8812 (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: 23nonrbiH2KVh8Ba7i6O3Wc4br+b9UaGcy7gokZpBV8M0tIb164EfCcWorjXOylvAtY9iLG26PxfNVkHIWjPbQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB6125 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org There are two ways for SDMA accessing SPBA devices: one is SDMA->AIPS ->SPBA(masterA port), another is SDMA->SPBA(masterC port). Please refer to the 'Figure 58-1. i.MX 6Dual/6Quad SPBA connectivity' of i.mx6DQ Reference Manual. SDMA provide the corresponding app_2_mcu/mcu_2_app and shp_2_mcu/mcu_2_shp script for such two options. So both AIPS and SPBA scripts should keep the same behaviour, the issue only caught in AIPS script sounds not solide. The issue is more likely as the ecspi errata ERR009165(http://www.nxp.com/docs/en/errata/IMX6DQCE.pdf): eCSPI: TXFIFO empty flag glitch can cause the current FIFO transfer to be sent twice So revert commit 'dd4b487b32a3' firstly. Signed-off-by: Robin Gong Acked-by: Sascha Hauer --- arch/arm/boot/dts/imx6qdl.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/arm/boot/dts/imx6qdl.dtsi b/arch/arm/boot/dts/imx6qdl.dtsi index 346a52f..a8dedeb 100644 --- a/arch/arm/boot/dts/imx6qdl.dtsi +++ b/arch/arm/boot/dts/imx6qdl.dtsi @@ -327,7 +327,7 @@ clocks = <&clks IMX6QDL_CLK_ECSPI1>, <&clks IMX6QDL_CLK_ECSPI1>; clock-names = "ipg", "per"; - dmas = <&sdma 3 8 1>, <&sdma 4 8 2>; + dmas = <&sdma 3 7 1>, <&sdma 4 7 2>; dma-names = "rx", "tx"; status = "disabled"; }; @@ -341,7 +341,7 @@ clocks = <&clks IMX6QDL_CLK_ECSPI2>, <&clks IMX6QDL_CLK_ECSPI2>; clock-names = "ipg", "per"; - dmas = <&sdma 5 8 1>, <&sdma 6 8 2>; + dmas = <&sdma 5 7 1>, <&sdma 6 7 2>; dma-names = "rx", "tx"; status = "disabled"; }; @@ -355,7 +355,7 @@ clocks = <&clks IMX6QDL_CLK_ECSPI3>, <&clks IMX6QDL_CLK_ECSPI3>; clock-names = "ipg", "per"; - dmas = <&sdma 7 8 1>, <&sdma 8 8 2>; + dmas = <&sdma 7 7 1>, <&sdma 8 7 2>; dma-names = "rx", "tx"; status = "disabled"; }; @@ -369,7 +369,7 @@ clocks = <&clks IMX6QDL_CLK_ECSPI4>, <&clks IMX6QDL_CLK_ECSPI4>; clock-names = "ipg", "per"; - dmas = <&sdma 9 8 1>, <&sdma 10 8 2>; + dmas = <&sdma 9 7 1>, <&sdma 10 7 2>; dma-names = "rx", "tx"; status = "disabled"; }; From patchwork Fri Jul 24 18:51:16 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682865 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0064D912 for ; Fri, 24 Jul 2020 10:37:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D598A20768 for ; Fri, 24 Jul 2020 10:37:31 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="sAsIRgNm" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727849AbgGXKhb (ORCPT ); Fri, 24 Jul 2020 06:37:31 -0400 Received: from mail-eopbgr80079.outbound.protection.outlook.com ([40.107.8.79]:43491 "EHLO EUR04-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726329AbgGXKhb (ORCPT ); Fri, 24 Jul 2020 06:37:31 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=DjGp9xCgvFnJkWvniYdRcUxgk0N7QaETQdoQkjk+rIV2/qE2kwyEmnY9h3ZH5uwl7Fccuao5mg+hVZ/xrmYWrUC4YKjs1mqwbENY9GjoD8EaLJG37bKo5Z2oBvOFvQEpvfFwsgwCbQh/rQI9m/tI6/eiewq1yab8y3GVJJDgZbq2Xq8vb84Chshj1IH7S0JM41eCkgWyqbhP7OqSMSTFKso9hs5fVaF12WN3/2QzjfKjsiArz7zUHnBZ59/JBKmxoYCESGJUhzp2+LrOwY0VzhywtlRwSfhp3I9PaVxBxx66Ll8WMNyo2aW6A8owXReo6Mms42EKJKH8MzGzX08aWA== 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-SenderADCheck; bh=e/QmptLzISEg8XISPPONCPgPblgFAEAKYoqgWtaOmaQ=; b=FAMviq5Bai87jArbqNTQLLy5B7B2TCPbk4SHQdsMzA563gj4cjPELxbg/+DcLWTBBHCGXDC1g6owb2SNwljqG2H+6gZAfzJVKHOq1J/80wdkdg3jYXOYshCaRh+3lap84yMmmUvCJbTtZdIY/20VnjaDOfxkP2AyvsMqZvzHpaQ2dZIEALCr7CKv1J8ZiZg0QQ40e6Ka4kejJK0k2F3BYvZFbuDkatvWhTBOJbEuG+EwUTMYIksUYBENRFtDVjJv4vZS1eryO4Ei/zoVRta6+93H9L6z+GOxwGibJQzIgj5LQJQe7q7fjZWZDliEMMdR3Y2la/CsuOtzzAbp5UXtLQ== 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=e/QmptLzISEg8XISPPONCPgPblgFAEAKYoqgWtaOmaQ=; b=sAsIRgNmd3+d6BSY29T3BfWdiQbanZRlW7Fl6bf4gI6PZBp0lQddJ9udX/zM4DPiE9u8ZdnCsHXWvnB33cHuA3EY+qpzKSX2fbTEguh35vk3nPUQExFkC3OEXMD/T6hMNiWeG0/vyTB+/69z2xd87+bFsgQFPR6Z24Wb+LMnXOE= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:37:27 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:37:27 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 03/12] Revert "dmaengine: imx-sdma: refine to load context only once" Date: Sat, 25 Jul 2020 02:51:16 +0800 Message-Id: <1595616685-9987-4-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:37:21 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 41482e21-c99f-42e9-6c82-08d82fbd8f07 X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:119; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: xDU1ctRHK3g1BjHnrjKSkm1EYYFhrochFMcdP1LAucmU2lZjNV8dtS46GZqKibgvTbXVMrGkvcSQpfLVNkdPyqoTouZThghxCr0Ud5TMpGlTvJ72wRHNflappNmlKKIR65675jsb5M8a6PR4Tq2mwJZ1higS8hH14Kv1T8jYl6vL3h4ur4WG2O7ViNAh55EAegJAqzkGt+ftDnngpjP7Wmneif4EfQRcMF++r8QLjDP+TW4+aQVBe2Xk9SLvxl/m8mIyo6qfEUAaS9/iGAZEbd5CYgO1RACoO18hNQF/pN4PzaEJ98kgzCs7VN/F2ByRLAetlo/5bJEp6rnzbFzmYl7MIUoEmm7n++KWR6MHEDXtXEluZMczf7CGX6RjyZch X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(83380400001)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: V1CDaTuM3zMycf7Hytx6WJiuUFaFZKa9RO0N3zAb64mYkFn3wFngkSwQZSuitHiPp4Y3nt0Tl7+jrfYmn6mvq3ZPqj1ExVTxhwiv3UMBR/TYz4+FnY0EibyZ9bk60u6mrv5j5y3lOHI+TBU2XgTDw5sFKO/X22vTjffHYUYWxhCl6jJaxfVxhcTsRwvRssIuskEhP4Zh2xT6j1enm10XEs72WomVjcvUDTUbV4RPnr0AtGf8XkSwNrD+pIJkAOObDFh2pXYmDrmfrJxj/5SzbeYNQSA34RGabrhxf1wAzR5GYAXrrjCPsQdgB27AZBAN/G5CT+rE3rT1uPGrM2diC9uwfgWvN21vrwdMq3nhdE+rdNnsMaVWUq4sJOpa32+z53EHgLG/70nwL4//4JWefAuhwefgkPAsUhxnKPmsSgDVGqhCBh5UzD1Wpg5MTz0ZcKGLJAT9CluYxYHTsGRAoomadI/n3bb3t++x2RQ5KXg= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 41482e21-c99f-42e9-6c82-08d82fbd8f07 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:37:26.9477 (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: v05JIuaxW77RugL/ASttVUwoVJC70R8hb8SUb1t2R0c1aN9cJoCLIXjCm+AegWCPzgo+M4mg9Ztu0SQhpVev1g== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org This reverts commit ad0d92d7ba6aecbe2705907c38ff8d8be4da1e9c, because in spi-imx case, burst length may be changed dynamically. Signed-off-by: Robin Gong Acked-by: Sascha Hauer --- drivers/dma/imx-sdma.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/drivers/dma/imx-sdma.c b/drivers/dma/imx-sdma.c index 270992c..d305b80 100644 --- a/drivers/dma/imx-sdma.c +++ b/drivers/dma/imx-sdma.c @@ -377,7 +377,6 @@ struct sdma_channel { unsigned long watermark_level; u32 shp_addr, per_addr; enum dma_status status; - bool context_loaded; struct imx_dma_data data; struct work_struct terminate_worker; }; @@ -984,9 +983,6 @@ static int sdma_load_context(struct sdma_channel *sdmac) int ret; unsigned long flags; - if (sdmac->context_loaded) - return 0; - if (sdmac->direction == DMA_DEV_TO_MEM) load_address = sdmac->pc_from_device; else if (sdmac->direction == DMA_DEV_TO_DEV) @@ -1029,8 +1025,6 @@ static int sdma_load_context(struct sdma_channel *sdmac) spin_unlock_irqrestore(&sdma->channel_0_lock, flags); - sdmac->context_loaded = true; - return ret; } @@ -1069,7 +1063,6 @@ static void sdma_channel_terminate_work(struct work_struct *work) vchan_get_all_descriptors(&sdmac->vc, &head); spin_unlock_irqrestore(&sdmac->vc.lock, flags); vchan_dma_desc_free_list(&sdmac->vc, &head); - sdmac->context_loaded = false; } static int sdma_terminate_all(struct dma_chan *chan) @@ -1337,7 +1330,6 @@ static void sdma_free_chan_resources(struct dma_chan *chan) sdmac->event_id0 = 0; sdmac->event_id1 = 0; - sdmac->context_loaded = false; sdma_set_channel_priority(sdmac, 0); From patchwork Fri Jul 24 18:51:17 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682871 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0DE7D912 for ; Fri, 24 Jul 2020 10:37:42 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E8F0D2074A for ; Fri, 24 Jul 2020 10:37:41 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="ftEdCj7u" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726985AbgGXKhh (ORCPT ); Fri, 24 Jul 2020 06:37:37 -0400 Received: from mail-eopbgr70059.outbound.protection.outlook.com ([40.107.7.59]:51008 "EHLO EUR04-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726329AbgGXKhh (ORCPT ); Fri, 24 Jul 2020 06:37:37 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=GB6jWf5dSlX5Q+I9i9iMRSxBfSTOM3hehfhdcHsQtX1PSP4pDgLqi/bxuJow9auinb3ses77l+VKFNH2VJ1wlueU5a8Z+eRU6J8j+0V2VAMFQWtx/AL65aHV7Sf0qqLhTllVSELx+5khF0NS985dFgdhWryQ+j4hjwRgjlBKrYtzpzbAUdDT8+H7ErwzTFOhvME3IbAcqhQLDn9LLd0oytWUZynD0cnTq9BMJ97kNnJCrVtnbgyG4YUA762taFZuL9rICOy2elyWBVXSEfn0pd2fgziU3CWb6EMdz7VuU0tAD6lVBKccz+CVRjnduyOfaR9tcsaftKPOSHlOcbv9iA== 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-SenderADCheck; bh=IN1fRToEmGvcd3mguKJujHggzOr4K2gVkDIrU6mwPNY=; b=NbO+JuOa1/ZPMEdExc3ayL1+TLBkW3nMXWT8gqzNwV2mBsqwQkeogLqhmzuleH3NMIlf8GNW6h+qZK+I27Awiul/fEvh4jVoDjujvQ93ncL41XgakDURg8rUYT0uVW0/imFGyGPje6kEejRF1TRsKpBLL6LxB9sTe98VhWU5t02Q8CrYwYK/2u4NT9T/xJKk+X3xgIr0oERz3fGaPxZD5pXf+rAVjXwUTeoqsZrJkZ9ORxaHmGokYQjgz2nJZ09dAdxdAD8fGXgUlL1yoZ4krNTzlRsZuu78vzf0CIdw7GkpGAAVsnD6L/KFzPD9UOiUQOgD0j4XGV4D15yoAXPoGg== 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=IN1fRToEmGvcd3mguKJujHggzOr4K2gVkDIrU6mwPNY=; b=ftEdCj7uEd2I1p/eXpinN7idfVX6IfBIi90lFKF7zAFezZEu2b5svheLha3GTZGKXhDvIf3W5+VFXJ92kus8G4BczyIHPdb8/IFynWcDCr6SX5aKlnQg7KsMWlW6Eu35Kw+e72VnRzHOXs+NY13scB3PJF+BT89B6d4q8nqcvzU= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:37:33 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:37:33 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 04/12] dmaengine: imx-sdma: remove duplicated sdma_load_context Date: Sat, 25 Jul 2020 02:51:17 +0800 Message-Id: <1595616685-9987-5-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:37:27 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 98dd6f75-e829-4579-8adc-08d82fbd9283 X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1923; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 7ppS25ZMcLl7lltffqimFBngXQvu7EZYUqcCWScHq16Qx6ysRBUYETkAPcb6g5VV06rQABTMYfG/DQNnkut3hGhy38iLornrluiKJYzKi9G89V8wTtZnzDQOO89FWJ2fT+jWw0qkkwmKFFpeb3CHnqtH+hoBiwUnw5UyErbalqNvsuc/AdySMIabWV0q3F9ea0sUHs7vrTBmAGq3GrUa5YyiybZn5byY3nYSO56JWReedfLxH+y1Rp+xYkXdJYeQWUgrxFGSebcDxBBg+v/lXvHq3Se0sYapyD4o/2uSv/v5EMjNmCad7yfcYZJRHdi4TpgWHwnUCw1Y6YHl441nV6esiymh7m3BiEKU/uqZ0txi3hRrCojwp0IqvfkcC3D2 X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(4744005)(83380400001)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: TsVOVuaTviZl4To/WmmEoI6xDhhPmgFv7vV6ShREi2mSf9hEQAagEBAgdsY/MicBJW1+V3qiOOH9v23uwC21q86gdnh/lHifrLCzgJb9ABJ/jT89fh6XhLcQHoyXl0S0emNiSHoe62N6W3uqU4h9i+CcT1tCe3MBFfFMC44Tnj4aY4IdkkgBHbwSuvhk1cTN+w7VFFVxapnk0FBCs3lOEkX8HVZtSEq2mMNuju7gd10ugBejt/b19Xrh++daZnAFgRNOv7xmgx3td8gdMu+L56QNoe4jkXEJzNoiLi9FLL/g9+6bV2nnrInkqzog2pGgaOs+oaAqr+LqydbrbQ6YUlkwq+5YkihYN1gBogFl1Mea92KUU7T5myzyYHdfmfOvcfa/eeCQsyDyxqL+RzxOo5WyUm8pVangA2c/LjAEP+n3Ikxses7geSKkXS32pnwWA/O23ROTNtC+j8yZpu0+2nfIUb4Y3xcy25R6jJvP0Hk= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 98dd6f75-e829-4579-8adc-08d82fbd9283 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:37:32.9292 (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: Sh6doN2ZdREhAr74gMU0UeTsAx/Smlck9IobOCqek+hiE6NwhMG3NYa7HcEv1jyhteSI2elkg1Y/m4QL1wEE3Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org Since sdma_transfer_init() will do sdma_load_context before any sdma transfer, no need once more in sdma_config_channel(). Signed-off-by: Robin Gong Acked-by: Vinod Koul --- drivers/dma/imx-sdma.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/dma/imx-sdma.c b/drivers/dma/imx-sdma.c index d305b80..5411e01e 100644 --- a/drivers/dma/imx-sdma.c +++ b/drivers/dma/imx-sdma.c @@ -1137,7 +1137,6 @@ static void sdma_set_watermarklevel_for_p2p(struct sdma_channel *sdmac) static int sdma_config_channel(struct dma_chan *chan) { struct sdma_channel *sdmac = to_sdma_chan(chan); - int ret; sdma_disable_channel(chan); @@ -1177,9 +1176,7 @@ static int sdma_config_channel(struct dma_chan *chan) sdmac->watermark_level = 0; /* FIXME: M3_BASE_ADDRESS */ } - ret = sdma_load_context(sdmac); - - return ret; + return 0; } static int sdma_set_channel_priority(struct sdma_channel *sdmac, From patchwork Fri Jul 24 18:51:18 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682875 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9C84613B6 for ; Fri, 24 Jul 2020 10:37:47 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 837F92074B for ; Fri, 24 Jul 2020 10:37:47 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="nRxpNm0T" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727775AbgGXKhn (ORCPT ); Fri, 24 Jul 2020 06:37:43 -0400 Received: from mail-eopbgr80089.outbound.protection.outlook.com ([40.107.8.89]:22003 "EHLO EUR04-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726329AbgGXKhm (ORCPT ); Fri, 24 Jul 2020 06:37:42 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EubkunOEWE/bEcYf6z5Y0mP9XpV4Kip23MAyMnwlp597h4I3c6ZPmdeHZCsQYdef975gREwZexZZ0S/7ar/z2vbeoNcQ9tNk9x2YQB15sRRabaCrGeynu+O9EZtreRPqPaRF2g3LaMz5hFLzwlZLLzLdmi2h3btfB5J1Um4Igbec/5d3c+nFGEJb6GDGB3s/XsMkC7hKWpeOhf1TH7vJu7GeXjOheNaohLTi/Sf6XBkiRbntWD7IZCGctSS8FwT3m0U8IvvM0jnJ3WyBku0wqtnQLSorPs5zar4nLdz8/YPsuwi+lJK0UzeyzgAaLKBml49zCyh7DkHOVKASD5Ivgg== 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-SenderADCheck; bh=zYO4eeCkCaKtyLBE/p41QWBbs0n+/LC0JXhKC1GhFac=; b=j7kLvO6IIFDD4SWodQHhw0zIuGh99iHpcI9E1VeU6rGJ1claqaQjWGCBkanG4/iOr/6WtS0N4pzm9ImH2xKLYYNctjwYn4/c0P7f62/a8qedE605GzuMKhUuFmaoibbXKjg9XjdDW1Av9LY2km0HSocVZFDlPqxz2/TURupOpEtMjKkP+hOQq4q9U62fOtV94hDP75W6YiPX/PBoqOjx33M2sbDkO1VjahR6qlDaqXaPf+2KDYEzRqY4GdRNJ3Y+chqq4w68oIPnNvuKj25fGhQxFWRWqKAqiChqfxUvtqDJWyS0Q/vnbLyn/uRKVktpgGTkwcTZYdgaPdEIKp0hBA== 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=zYO4eeCkCaKtyLBE/p41QWBbs0n+/LC0JXhKC1GhFac=; b=nRxpNm0TlML03Jphmr3grtMKLH62iW1qrsLmxfPeVnUtuzuxum2Yr50ix1bxqydZHju5Gb/cpb4ZJxBQ8DFG1Cu8eXFd25veCPrqm9kspwOASZKMMYP7QbeujYX9LwCJo/cOagv8tLDQlh8D4sEUpm74Jp3bHik9VbWW/xcX2k4= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:37:39 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:37:38 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 05/12] dmaengine: dma: imx-sdma: add fw_loaded and is_ram_script Date: Sat, 25 Jul 2020 02:51:18 +0800 Message-Id: <1595616685-9987-6-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:37:33 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 73733833-2d20-4ab8-2697-08d82fbd9605 X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:7219; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 8A/lFDoBWuGKQ3wV2ksLWXqIok4dZjHyp4Hwm+NyjUV/5Hanmxxd0E2iHLSVrhvk55i2YpZ2bYcbO9YBqbGCYr/BxNlEJvS6SxDvGeuEEH/peiiuc0NlTykfVV/a7fA6geEYlwjCJRYtczG4T6J687EUwETApu/c4a2fgxZO1nGtgvM4Pud7TwX7jPSDK15OQZS9zg7XN5q5Jfg0FL+XpGsvyyX/Ncf4PCaNyj27iqLYIwYxTaUK9TALZ/XRRoNmNAh7C3iAkW0Ih9VzasV+FFaedx6Kc2rKxr5RbXn0qk6tFANY1woWgexmfpeet3EiM4fknvdZoyvNH/hq1kyFJWo3hrBxAnlZRJtSgpaVe1TjTWKV66iFWOulcLznysqf X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(83380400001)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: s4bqsUWyLXAGezzC/IwZtWed1RRnDE62xqJbbZ4MVDUzA5G/AT3uOd5UIkII97Xl1mZJ3zvdHsd2gM7hvWT4EQNYM1piZ36rs9DM5YBKindwVS1jyOvjZl1wRaQeiMXrRIGyWRyxe74YcRWUrRpsfBK7wutNvu+Do8/YbJhmiVYOSlgcY2hgxR1JjdMa4xJ8bU6edXp2+LVGgz6cgUGQBrF+Z7Yf6WRIuSCalHbJgSJVn6yl+8LgEdvzwe4D/+gCUSeuKvz8lGGfxiGu3HfH7dO9T/3AgiD1cE3xndwyvAzQYVhikYGrx3nofCnPHTPX3EsX4EVWAkNyVTah3VBGoe/98sgiIYmSjfZ9oaam0s+tnD7EZ22f44hkX77OUfptYe/9neVg4LC9BB3iS3FKKJwgYb95UWmDiJz/roOskgYpZlLxFiy790AwrOgbanTz5DtTOhu5PVu4pAu/PAGV+muGZEUR6l+hFdpVPgVYEAM= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 73733833-2d20-4ab8-2697-08d82fbd9605 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:37:38.7927 (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: 2Kh3zlLoev6yJpVZsXxGvNbdQq1Jr95yNsO7Om4Mj2TGbUyFJHZKoQxOz0fBHCMxkBL8JV+OGKJbHCaSp8HVTw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org Add 'fw_loaded' and 'is_ram_script' to check if the script used by channel is ram script and it's loaded or not, so that could prevent meaningless following malloc dma descriptor and bd allocate in sdma_transfer_init(), otherwise memory may be consumed out potentially without free in case that spi fallback into pio while dma transfer failed by sdma firmware not ready(next ERR009165 patch depends on sdma RAM scripts/firmware). Signed-off-by: Robin Gong Acked-By: Vinod Koul --- drivers/dma/imx-sdma.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/drivers/dma/imx-sdma.c b/drivers/dma/imx-sdma.c index 5411e01e..cf02c3e 100644 --- a/drivers/dma/imx-sdma.c +++ b/drivers/dma/imx-sdma.c @@ -379,6 +379,7 @@ struct sdma_channel { enum dma_status status; struct imx_dma_data data; struct work_struct terminate_worker; + bool is_ram_script; }; #define IMX_DMA_SG_LOOP BIT(0) @@ -443,6 +444,7 @@ struct sdma_engine { struct sdma_buffer_descriptor *bd0; /* clock ratio for AHB:SDMA core. 1:1 is 1, 2:1 is 0*/ bool clk_ratio; + bool fw_loaded; }; static int sdma_config_write(struct dma_chan *chan, @@ -929,6 +931,7 @@ static void sdma_get_pc(struct sdma_channel *sdmac, case IMX_DMATYPE_SSI_DUAL: per_2_emi = sdma->script_addrs->ssish_2_mcu_addr; emi_2_per = sdma->script_addrs->mcu_2_ssish_addr; + sdmac->is_ram_script = true; break; case IMX_DMATYPE_SSI_SP: case IMX_DMATYPE_MMC: @@ -943,6 +946,7 @@ static void sdma_get_pc(struct sdma_channel *sdmac, per_2_emi = sdma->script_addrs->asrc_2_mcu_addr; emi_2_per = sdma->script_addrs->asrc_2_mcu_addr; per_2_per = sdma->script_addrs->per_2_per_addr; + sdmac->is_ram_script = true; break; case IMX_DMATYPE_ASRC_SP: per_2_emi = sdma->script_addrs->shp_2_mcu_addr; @@ -1339,6 +1343,11 @@ static struct sdma_desc *sdma_transfer_init(struct sdma_channel *sdmac, { struct sdma_desc *desc; + if (!sdmac->sdma->fw_loaded && sdmac->is_ram_script) { + dev_warn_once(sdmac->sdma->dev, "sdma firmware not ready!\n"); + goto err_out; + } + desc = kzalloc((sizeof(*desc)), GFP_NOWAIT); if (!desc) goto err_out; @@ -1589,6 +1598,8 @@ static int sdma_config_write(struct dma_chan *chan, { struct sdma_channel *sdmac = to_sdma_chan(chan); + sdmac->is_ram_script = false; + if (direction == DMA_DEV_TO_MEM) { sdmac->per_address = dmaengine_cfg->src_addr; sdmac->watermark_level = dmaengine_cfg->src_maxburst * @@ -1768,6 +1779,8 @@ static void sdma_load_firmware(const struct firmware *fw, void *context) sdma_add_scripts(sdma, addr); + sdma->fw_loaded = true; + dev_info(sdma->dev, "loaded firmware %d.%d\n", header->version_major, header->version_minor); From patchwork Fri Jul 24 18:51:19 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682879 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id F3784912 for ; Fri, 24 Jul 2020 10:37:53 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D9A9F2074A for ; Fri, 24 Jul 2020 10:37:53 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="Qx0eL06Q" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727975AbgGXKhu (ORCPT ); Fri, 24 Jul 2020 06:37:50 -0400 Received: from mail-eopbgr140085.outbound.protection.outlook.com ([40.107.14.85]:61931 "EHLO EUR01-VE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726329AbgGXKht (ORCPT ); Fri, 24 Jul 2020 06:37:49 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=DKB1PZdNWlTNDquewRfb+VTDIYaLq0borL8l5VaE2YWyetPpeV/fiFxAz2IztTn7s8jukqJY93vXn4dFXiQrbnK18YY9d+/DXZ1ErwaRrGtFTm4EtgsTW/gJcEUbUeRvsb96m7l4lkQB+gaNYj9DRar6N3xkoO3EQ4dLBj/PKlRPXmjie79B5Tw5c1+j9WLgYqIT42NCxVSd2NlTp4oQwpbVfnD3IiQp84/doik3ALiUDvhHX5A0Y8we5CTtJwUkr/jhAR5bBbJUdFuj/QmTWJTFa4bkUYsAmTyGDXWGcnioKWB+zW6Y0P+kvg8MbHDNVUkIWEr5gSqKEh42zzVEzA== 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-SenderADCheck; bh=UZKBPwv3h3QlWAM24YnwpxiPhRgJFyrgSksGB04gjZs=; b=PN0filUqHB8of7DPgLAftHmNnDPxFwlAI4bxzeleJwHNRXavsBkjBA000N6zDbn1yjR39aM48Wtxr1kfcYquL5BRQZXBjtGdT8CKVYEcjRQc9LwP9JIoEn+rCMbIzxynTTE4IHcscVDCoWgnckile0TIFSXbcs8pNjYC8TTEHKhkyxOTW6e6ggRz1lxt52Say3v47mahjljfo95qJ8tldDDViLIVg/bscpbj1XV3J8TvQhfld+rhuCj+b2ysoFEV/mukzuROeeK8YjLQeNRBvF0UfStnprEgjRZJGAjronMv9ay+QAX7gjGgsCi+r4EQC8hfogTsaHa2RTWA6t2I/Q== 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=UZKBPwv3h3QlWAM24YnwpxiPhRgJFyrgSksGB04gjZs=; b=Qx0eL06QTpcxMCue9PnwEZU7eV8m4EPJkQPwbGQrewVLZqew7yEEWrE5y3ELppraODe2lrf+v7cAlr6iNuhLEG9JqRZdph7oo4RScTG8sAcJq83Ho7ZqxnTiCvXxvu23wU2qrynkqpVU2EW4XeExZA7EXaeRRQCzOz7TGyzy6w0= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR04MB6125.eurprd04.prod.outlook.com (2603:10a6:803:f9::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.23; Fri, 24 Jul 2020 10:37:44 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:37:44 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 06/12] dmaengine: imx-sdma: add mcu_2_ecspi script Date: Sat, 25 Jul 2020 02:51:19 +0800 Message-Id: <1595616685-9987-7-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:37:39 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: e9e41508-7e9e-48b2-5e83-08d82fbd9987 X-MS-TrafficTypeDiagnostic: VI1PR04MB6125: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:361; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Z+0mTTPTSOCVvUQwM1vvr2DDLWUag/vvoXXBqlZ/QuF0mZ7PR+zFMHnL+Drb8qc9FUswt4UxjdhllgGekE/4eFwWaDmZzjsmrVUxfeedIUcKGmk72wdkeFWuMEoprjmEoHRfj1SFL1Rz25J/XmbNbdnIPokh1TIs6TKTYDeY7yWm0OP3EViUiUD8ftsGfYlzjgoXSLktlWB2ldjhqMolWV/3fSLsam/ItK2OCVxvJab4HfBifgaap7a+R39A/e5R/su560vT613SzNZ0ZBrePa2JDGvq2jATHUZ7/GZzPgntNdiv/52NqXRnZjdZ7aO0iWncTSkNy9YQMspW9446OVap+gV1LmRiw+WjB2n/UgFXTKtl52FAaUDMd9IixY3l X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(366004)(396003)(136003)(39860400002)(346002)(376002)(6486002)(478600001)(8676002)(2906002)(8936002)(6506007)(86362001)(2616005)(26005)(956004)(6512007)(316002)(186003)(16526019)(36756003)(4744005)(4326008)(6666004)(52116002)(5660300002)(66556008)(66946007)(66476007)(7416002)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: 2QKqR/n45kf7Q4VIf8uaiW1W6YUQeUTzrfJyonTROmwgJORDTcYqgzk4rOC/U39UqtSjG0wFDcU2XPx+LqiOe8t4lqJt5wg8imtgHSr9d6+Y/lL58a1VBRNRpnKNB9JL+DxuVOtmjqsWn9bRtt/Qo1ngZpduiBPYbhrMWeKV6FWttd16Hwxd/+YSp30KlhOogSTQz1+fR7n6icgV0gCABrioIB8KsJQ/nkNfDVaF74Bf+WNZoZsw2eWUxZdYp7Eo9208kO/T7Dprh4zSYGEnj0xiOve0wGam9H/LDWzV90gHy6YCL93s/rzr0sTwBgnt/4134MSI2yQmU95lZA4lJTUnXPNcTFjfpGqgSlaAtiHrLY8cevDmTrerD0BxjFfw+LpTOW/gwpq4clb76bftPea5RHy0mdClEXMVSlaI2xOmduCG8GLfWTYdkuYXyz+9EmmdNOYmz82cE4meGlTLHybwk4fQvcnSWexX6G1jdvk= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: e9e41508-7e9e-48b2-5e83-08d82fbd9987 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:37:44.7293 (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: dhPqkxxt8SKAC9dq+Ji2tFieF33SgY30PjTLEMubfW0xw6ShdoMaro6PBO9xXdQSNIv1Uql4knb+5q6sVaxp8w== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB6125 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org Add mcu_2_ecspi script to fix ecspi errata ERR009165. Signed-off-by: Robin Gong Acked-by: Vinod Koul --- drivers/dma/imx-sdma.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/dma/imx-sdma.c b/drivers/dma/imx-sdma.c index cf02c3e..d5d5d40 100644 --- a/drivers/dma/imx-sdma.c +++ b/drivers/dma/imx-sdma.c @@ -922,6 +922,10 @@ static void sdma_get_pc(struct sdma_channel *sdmac, emi_2_per = sdma->script_addrs->mcu_2_ata_addr; break; case IMX_DMATYPE_CSPI: + per_2_emi = sdma->script_addrs->app_2_mcu_addr; + emi_2_per = sdma->script_addrs->mcu_2_ecspi_addr; + sdmac->is_ram_script = true; + break; case IMX_DMATYPE_EXT: case IMX_DMATYPE_SSI: case IMX_DMATYPE_SAI: From patchwork Fri Jul 24 18:51:20 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682881 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 54DB4912 for ; Fri, 24 Jul 2020 10:37:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 3A0812074F for ; Fri, 24 Jul 2020 10:37:55 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="Az15bJ6E" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728001AbgGXKhz (ORCPT ); Fri, 24 Jul 2020 06:37:55 -0400 Received: from mail-eopbgr80048.outbound.protection.outlook.com ([40.107.8.48]:45959 "EHLO EUR04-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726329AbgGXKhy (ORCPT ); Fri, 24 Jul 2020 06:37:54 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=nqIUTQ8zgs+iWQatEx596VHTRiKuW9Xhhh4PpEH93UgI9PNcj3NPUeEXBDCWiW42POaxqnm/C50ykIu/+TR/YY5OL5SNGpFPEszYwLGSAyefDnXMNbzSZXnOU4iNJFO72q+o3nnQuhyozJ7BWM5AlnqAEg37PvSH9TLK45eyzMzAdwfFcUM+DDt+K0gC9fzZRucgEB8W9aEHXG3Pp6/nO4t0iFSOCLSRrhfPG4pMJt600IVjEQp21+vJKf8MOsoE28ZxcpGsBNB4cFxanrlHFFCCyVhTx7itJVxKvMRJ21YYSrqgZkBB5WDFn7nMBAcCHGqjPcGIKts+0qKO73dO4w== 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-SenderADCheck; bh=+7wglQdCBx4vybuSP0CcjtoW8ZOV8IUohKb+Ye4yy8I=; b=Kst2wlcsSEsnPjmQ4da+xdeu9M8EsmolCKV3oxSy1ovh4JdFniWDUMEhMPfKfPUj+1Fvc/mJ0Zj/11Kyj/nb/6vJYrZOvUcdK9yKa1CWlvEzzfM7Q4uuM1OQbohsBjhjz82x+1EgO5WDapVZQmnqFwHUiOlR0++8m0gh5hf4/rf6ZrwHUZsoEftXKEB93vI1brlqCJmPwWLsgYohvP8yQR0H5bHNaSOHJY90bFkqvL7nVSgMjnDkaE4TiWVmzRgMvH0axcUV687x/cavj5MSz875FVmJHuF6iblPogExtycJIbTarzBr3lo0cvhuHKe1UrgZaCSTL1HymViz21ymKw== 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=+7wglQdCBx4vybuSP0CcjtoW8ZOV8IUohKb+Ye4yy8I=; b=Az15bJ6E7VRO7rlmBO+RNWq2K3XXGIV/NORhCbwIp7MGQRUR/tafhu2+fXOL0tkKs6tLJ08JApnRGbSI1HrV/HwWSeb2l1E+a1WlgZHawd2psgHwSXZu7Pj36HoBYWX+OTrUADofh6TusG4/ny7qPuMc6uo1AQYjkAEpbOF5Ghc= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:37:50 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:37:50 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 07/12] spi: imx: fix ERR009165 Date: Sat, 25 Jul 2020 02:51:20 +0800 Message-Id: <1595616685-9987-8-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:37:45 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 2d18e24b-59c3-4515-252a-08d82fbd9d10 X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5236; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: J80uLbY8wpukHXDlrkLDzIdTXG4rkule6UbuSq6XV4WExbrobqi0F4k0jC5O1z8E8qjKjhhc/5qD8z0i5x8ZD50+MnxNhNnFQLVGIZxvmxl0bwDqjVZhaXeiw2p37jWg7MLbcjQZRWrFX+beyX47c0tGFbfWiVbBc0wG9q+tpSo5mzIzgjin7MrVi8Nb7DCoS+Q+092jpea26aiJc5om1KDTjZ6fb116XZMEaRr7jnmmYTFN47N6UVyjZ8wpIMeH+hc9xVvJ1nA7W2OTx1MKMcQTyahStkWp8qp0WL5lr5IPa84vONk0aNzGXEFw8NdoSXpNLOtjR/ovviffWKI58hjpiVbqnFoMNinOB4G50J0CWZeOez6tVKqV72YMzN0OM31+ZCMlJtAXArcgr6HdAe0CnceMCS0QvFkZSJdZlM5TgOd3CHeWnoKu+Y2voH1s2xvUn1xter+T4xY41o0RHg== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(83380400001)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(966005)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: NrgwD4i+eN4BtJqd/ISYMoQc/nYD6tJF0wrd78E5+Qr1vtsIL1RNJSLTXiU0qtctIY8PzbHJDdZ8alVoSSczkBSpllOlXtQ/IthI9L/WQAj7MVJVANDMiWgJEUO26KHETNgYA7dbmpaSrw77NUoTrDEqGGHJ6E1gN4nDeRDASLpG5Flm1Z755MAPoSsSz4eXJRO+UVs2qeai1ALDU1WuX/Fr1EXKtTYlE4rZmViiLAxbOfLe5hPqiuAOs0k/sFSpa30A3eOxMgO8mKmNVCGZzLSbQVZDsAWqu2fGmdqXip/MTSLn9QlJDsQbeuDOC4kwqhrENXcOjiTZs8Kf1OvIMYiKicG5Xj+NcmNcbUNCHBoQiE2r5Zj4pQT2rLEY3jPMzRp/1ZB00MU8mZCfLXUbxIIhJyo2ExZ7OYLuv43Frk4sz0Rl3o6iPG6KP9IyRfs5IXqd+9baTNGGKCKjiK83NHqTbmsWdLeESJSMcscSnfE= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2d18e24b-59c3-4515-252a-08d82fbd9d10 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:37:50.5179 (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: ISIjb4YRrJER3zmSgH9Q5QUlHudJwH7KFsvp0P5+vPawZHsZlKmZNkWsyzRj6NZy/KJsZlL6AP/4oRjjcI78bg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org Change to XCH mode even in dma mode, please refer to the below errata: https://www.nxp.com/docs/en/errata/IMX6DQCE.pdf Signed-off-by: Robin Gong Acked-by: Mark Brown --- drivers/spi/spi-imx.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/drivers/spi/spi-imx.c b/drivers/spi/spi-imx.c index 2b8d339..873be5e 100644 --- a/drivers/spi/spi-imx.c +++ b/drivers/spi/spi-imx.c @@ -591,8 +591,8 @@ static int mx51_ecspi_prepare_transfer(struct spi_imx_data *spi_imx, ctrl |= mx51_ecspi_clkdiv(spi_imx, t->speed_hz, &clk); spi_imx->spi_bus_clk = clk; - if (spi_imx->usedma) - ctrl |= MX51_ECSPI_CTRL_SMC; + /* ERR009165: work in XHC mode as PIO */ + ctrl &= ~MX51_ECSPI_CTRL_SMC; writel(ctrl, spi_imx->base + MX51_ECSPI_CTRL); @@ -623,7 +623,7 @@ static void mx51_setup_wml(struct spi_imx_data *spi_imx) * and enable DMA request. */ writel(MX51_ECSPI_DMA_RX_WML(spi_imx->wml - 1) | - MX51_ECSPI_DMA_TX_WML(spi_imx->wml) | + MX51_ECSPI_DMA_TX_WML(0) | MX51_ECSPI_DMA_RXT_WML(spi_imx->wml) | MX51_ECSPI_DMA_TEDEN | MX51_ECSPI_DMA_RXDEN | MX51_ECSPI_DMA_RXTDEN, spi_imx->base + MX51_ECSPI_DMA); @@ -1273,10 +1273,6 @@ static int spi_imx_sdma_init(struct device *dev, struct spi_imx_data *spi_imx, { int ret; - /* use pio mode for i.mx6dl chip TKT238285 */ - if (of_machine_is_compatible("fsl,imx6dl")) - return 0; - spi_imx->wml = spi_imx->devtype_data->fifo_size / 2; /* Prepare for TX DMA: */ From patchwork Fri Jul 24 18:51:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682885 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DDC99159A for ; Fri, 24 Jul 2020 10:38:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id BBB9F2074B for ; Fri, 24 Jul 2020 10:38:01 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="gqA/u8o6" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728033AbgGXKiB (ORCPT ); Fri, 24 Jul 2020 06:38:01 -0400 Received: from mail-eopbgr80049.outbound.protection.outlook.com ([40.107.8.49]:2439 "EHLO EUR04-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726329AbgGXKiA (ORCPT ); Fri, 24 Jul 2020 06:38:00 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=OUaNlLDTzAx4SJtMq5hcv6Q8XIRRJXzFKZquRrX0KnmVuf1LTQ9X4FhuJ70iLNGd6I9OMQP3lXjzenQGrXKdimMTMfY2QWxTbGW3/iL4SxFyKycCX7Lkk9HSSlxr0mJOtmeVDnDJu8M89FpZz33XyWI5I2XZqy/2IfJPq3PUbXa1Tz8uXEDC5R8+rfq60G6APont98aAgoaLXalM5YKa2HByUz6p+iKGpN1yhv9bQLTi+1He1BNn+Z+rBczoXM0ztwwNU9dKRdEYZhmCJXV+pbEzf8WQMMhyNP9lXVnXBVrpVsCaONkCPXRZYO/PKutT1nFV4k/hKs2DWWocTCH0Fg== 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-SenderADCheck; bh=UIdg0TAYR1sjIrLOlt2s+rn1Vm6gjVIRKwp3FX6c2sQ=; b=munOfOM2kfdUhG13Ft908spltp5mzmc4Mz+223CPMgobfMIoYO3Iir9l8g+XHFarxP9EgcnkcAsp9ev4BYR23J73CXM27wOWxaaBLnIp9McjRiYOluWfv1Bl4HqccCwuBt4bPCEnmWMjyIvNXhQMDU+6DD+0rt2ehCJhiqtqVZD0rNoQaehc9A3mwRIFLFqMCe+LEZIr45zDWZhJGOPec/DzKoldqy28ohALiPW7U72Ln3W/PX+a/SgEhOmBIWA2IkN/8+l3TSO82RDN5Zmh1tM38VRCOrSh2URzM+1wPqN6Er3wTmOalKgG91cTIkj2YWXjCwHN2qS/adK3VCyxBQ== 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=UIdg0TAYR1sjIrLOlt2s+rn1Vm6gjVIRKwp3FX6c2sQ=; b=gqA/u8o6oQ6NiGIYNjvwG4adFY/f/ILwF9ZJ+EDovX6cwqsx+UVUBgMCvmRsXaQOchbqJB2rauDrbrjS2qWXHZiK5WDG6PvEbTQorkb7XWx7TFgWXueIdo2R8wuqXhN6B3TYUBs4G76X6z86ft5CRS3EB3JRiQhTDIUOGq3Uy4I= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:37:56 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:37:56 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 08/12] spi: imx: remove ERR009165 workaround on i.mx6ul Date: Sat, 25 Jul 2020 02:51:21 +0800 Message-Id: <1595616685-9987-9-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:37:50 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 9df96878-2f28-4e2a-48a2-08d82fbda081 X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:6430; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: uwjHA/wR0F7j20ctiESpt1kY+z3BZkcvPuH1f2wLRzSYI8pGycSsC4/6wvA4ucZefLJzX7Tok/k8Ts3o0mHw2gAdAWoALX2/YRxAniwfhzXeQeNueo9+gqx2qzgW3sZDN7qsEk3E/uuDp9aqKEYzVKLDrLPcqxAdunkOJFpMm3YgfqDtAX7Zfmg6Ce38ix8QgdQAymYtaNfzhYjdaAGc3jVQyktiu9s9cCcegcDJsTTcXkfRLkpNe5tbyN1j2x3oQPRC5FeXY74jT1f6ZpzG6F0efpahBaYHmlHWOlhhE96NsGqF6qj6Swjc2yt39OAI+xu0nI9siOrNxPl1bhtm0cGvUEYaUv6AVWGpeA5YlsjZDghG2LAO8BKBp6TKfRYuhaWCfGQR2iGidBBiZfcj7vJw0IUng0fe3tLJJ4O5O8UBnLfnaWecYBW4xyHe+Fou9u7edj0PjlfDLn97HhYIEg== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(83380400001)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(966005)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: VpeR18JlS0ykWvSaV4aD78PyQaZalR8gUjZRufl471CZSBRprUjxrCnXF9LgaA6pLtK7SHDzUr3NJ7aJt8MPfRbNIL/iq2R4fEuTpLz8F5r1chYLGiL6V9MoVGJmaQZgI5R8V82hIQ1SyW9DkhubwWdRe7JC4mU+YLX/TylaHEZKv6iq5qo3NSoii0IzQVWEPJ7T/WhiAOmRBwrOnMkaGJiWNBtDXiptNBY/QBeNtdbRvSTqCVPSRoQTTE0WfQoQ4pMKcWam0tZUQJLe/XXjmXJ29HwIPdhj16CaYWcSD3OLvnqD7xpW5v27yjhcsYxKcDhtJ2eAaewNFLGeceCBPubzbvSRxGtlwMOyFpPsEmjMXqPSs9FiB/WFnSZa1AefAq5efXUJDIU6GC8Mzh23S4jxXLSSCR8WkVtQ0H4DZM38Mo+W/KEQ/3xM1N8FdlNHm4jEBUa0MjS7LZnBO6VJAmoA6u6lWqMQFwuZNaoJ9/0= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9df96878-2f28-4e2a-48a2-08d82fbda081 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:37:56.2625 (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: 3wt3MKRcDfHcZ70z5QqNKe1b/vhsRd7Zu/VsZ8VkSfHsTau/NF4UO6HKOpel0PJotFgizWN8kpUS5J0tklvJPg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org ERR009165 fixed on i.mx6ul/6ull/6sll. All other i.mx6/7 and i.mx8m/8mm still need this errata. Please refer to nxp official errata document from https://www.nxp.com/ . For removing workaround on those chips. Add new i.mx6ul type. Signed-off-by: Robin Gong Acked-by: Mark Brown --- drivers/spi/spi-imx.c | 50 ++++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 46 insertions(+), 4 deletions(-) diff --git a/drivers/spi/spi-imx.c b/drivers/spi/spi-imx.c index 873be5e..f3049c7 100644 --- a/drivers/spi/spi-imx.c +++ b/drivers/spi/spi-imx.c @@ -57,6 +57,7 @@ enum spi_imx_devtype { IMX35_CSPI, /* CSPI on all i.mx except above */ IMX51_ECSPI, /* ECSPI on i.mx51 */ IMX53_ECSPI, /* ECSPI on i.mx53 and later */ + IMX6UL_ECSPI, /* ERR009165 fix from i.mx6ul */ }; struct spi_imx_data; @@ -76,6 +77,11 @@ struct spi_imx_devtype_data { bool has_slavemode; unsigned int fifo_size; bool dynamic_burst; + /* + * ERR009165 fixed or not: + * https://www.nxp.com/docs/en/errata/IMX6DQCE.pdf + */ + bool tx_glitch_fixed; enum spi_imx_devtype devtype; }; @@ -132,6 +138,11 @@ static inline int is_imx51_ecspi(struct spi_imx_data *d) return d->devtype_data->devtype == IMX51_ECSPI; } +static inline int is_imx6ul_ecspi(struct spi_imx_data *d) +{ + return d->devtype_data->devtype == IMX6UL_ECSPI; +} + static inline int is_imx53_ecspi(struct spi_imx_data *d) { return d->devtype_data->devtype == IMX53_ECSPI; @@ -591,8 +602,14 @@ static int mx51_ecspi_prepare_transfer(struct spi_imx_data *spi_imx, ctrl |= mx51_ecspi_clkdiv(spi_imx, t->speed_hz, &clk); spi_imx->spi_bus_clk = clk; - /* ERR009165: work in XHC mode as PIO */ - ctrl &= ~MX51_ECSPI_CTRL_SMC; + /* + * ERR009165: work in XHC mode instead of SMC as PIO on the chips + * before i.mx6ul. + */ + if (spi_imx->usedma && spi_imx->devtype_data->tx_glitch_fixed) + ctrl |= MX51_ECSPI_CTRL_SMC; + else + ctrl &= ~MX51_ECSPI_CTRL_SMC; writel(ctrl, spi_imx->base + MX51_ECSPI_CTRL); @@ -618,12 +635,16 @@ static int mx51_ecspi_prepare_transfer(struct spi_imx_data *spi_imx, static void mx51_setup_wml(struct spi_imx_data *spi_imx) { + u32 tx_wml = 0; + + if (spi_imx->devtype_data->tx_glitch_fixed) + tx_wml = spi_imx->wml; /* * Configure the DMA register: setup the watermark * and enable DMA request. */ writel(MX51_ECSPI_DMA_RX_WML(spi_imx->wml - 1) | - MX51_ECSPI_DMA_TX_WML(0) | + MX51_ECSPI_DMA_TX_WML(tx_wml) | MX51_ECSPI_DMA_RXT_WML(spi_imx->wml) | MX51_ECSPI_DMA_TEDEN | MX51_ECSPI_DMA_RXDEN | MX51_ECSPI_DMA_RXTDEN, spi_imx->base + MX51_ECSPI_DMA); @@ -1017,6 +1038,23 @@ static struct spi_imx_devtype_data imx53_ecspi_devtype_data = { .devtype = IMX53_ECSPI, }; +static struct spi_imx_devtype_data imx6ul_ecspi_devtype_data = { + .intctrl = mx51_ecspi_intctrl, + .prepare_message = mx51_ecspi_prepare_message, + .prepare_transfer = mx51_ecspi_prepare_transfer, + .trigger = mx51_ecspi_trigger, + .rx_available = mx51_ecspi_rx_available, + .reset = mx51_ecspi_reset, + .setup_wml = mx51_setup_wml, + .fifo_size = 64, + .has_dmamode = true, + .dynamic_burst = true, + .has_slavemode = true, + .tx_glitch_fixed = true, + .disable = mx51_ecspi_disable, + .devtype = IMX6UL_ECSPI, +}; + static const struct platform_device_id spi_imx_devtype[] = { { .name = "imx1-cspi", @@ -1040,6 +1078,9 @@ static const struct platform_device_id spi_imx_devtype[] = { .name = "imx53-ecspi", .driver_data = (kernel_ulong_t) &imx53_ecspi_devtype_data, }, { + .name = "imx6ul-ecspi", + .driver_data = (kernel_ulong_t) &imx6ul_ecspi_devtype_data, + }, { /* sentinel */ } }; @@ -1052,6 +1093,7 @@ static const struct of_device_id spi_imx_dt_ids[] = { { .compatible = "fsl,imx35-cspi", .data = &imx35_cspi_devtype_data, }, { .compatible = "fsl,imx51-ecspi", .data = &imx51_ecspi_devtype_data, }, { .compatible = "fsl,imx53-ecspi", .data = &imx53_ecspi_devtype_data, }, + { .compatible = "fsl,imx6ul-ecspi", .data = &imx6ul_ecspi_devtype_data, }, { /* sentinel */ } }; MODULE_DEVICE_TABLE(of, spi_imx_dt_ids); @@ -1671,7 +1713,7 @@ static int spi_imx_probe(struct platform_device *pdev) spi_imx->bitbang.master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH \ | SPI_NO_CS; if (is_imx35_cspi(spi_imx) || is_imx51_ecspi(spi_imx) || - is_imx53_ecspi(spi_imx)) + is_imx53_ecspi(spi_imx) || is_imx6ul_ecspi(spi_imx)) spi_imx->bitbang.master->mode_bits |= SPI_LOOP | SPI_READY; spi_imx->spi_drctl = spi_drctl; From patchwork Fri Jul 24 18:51:22 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682889 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id E3FB0912 for ; Fri, 24 Jul 2020 10:38:08 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C4EB320768 for ; Fri, 24 Jul 2020 10:38:08 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="h1iuMYx4" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728060AbgGXKiI (ORCPT ); Fri, 24 Jul 2020 06:38:08 -0400 Received: from mail-eopbgr80042.outbound.protection.outlook.com ([40.107.8.42]:43040 "EHLO EUR04-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726329AbgGXKiF (ORCPT ); Fri, 24 Jul 2020 06:38:05 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=MmtYcIS7vuwckIDTIv/cm6pGCXy4tGN7lGoXrtfej3jVB0kWAPHkvdzoLEAABGlOquwlwonJQ2h7UDJpqihf0CYrZRjq+gzkgKu3oQYqzpgS9dvSwBunRuYHzJSyVGFTCyU3ECZiIyj1cke7YMXvPTw4D0TMkr/r+WLK4QQx2zk87vsToDiRjqpNYzaRfdns6Ing+vjEuDSwCdbA7A78YTAg58zeLndm70LmHpycscm78xfsT8vWl/SNxNjAUuCd0U9p3UEEk0xiLE5KKt0VZTlUls9SA8jbO2/44SV+MHR9IPgxSFLwyx+MboJnYgEM5NyVYJEtUwv8k2QaJzrvnA== 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-SenderADCheck; bh=5jxJdGqHBF995O2koMhPVubVtg1S3gV8z8tbdE75gTs=; b=aKwueF9pKwSeTDiMRszGlUM5AX5gDBQKqEnVy3PkxcygJg/Lo2D4TVMFKgT5js5m2r8iXGtJRQLTG4VAqZOapnMsXCpDv7oAF6ocJ5ImYGrWyvXIeL0b2ykXKAl5OiRLto8oygtN45Ykcl5O7KRQPAGmGV8jTAwaWWZbdQhtkYUh/XoURRmSoFMJKhL/dUEwKgErVhHjvAu5LzrDF0Diiagbp1f9nbwOEhokLJnHl69POjjFQCS5PJVfG3uZor0GDaXbVYKtlYYSmW3Yj6mjhhTKWo22qExfpql2s8D0iX+iFotRlPJn1MJ1V2ON9ku3WVGjuPhVa7LPTWF2Bra5/w== 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=5jxJdGqHBF995O2koMhPVubVtg1S3gV8z8tbdE75gTs=; b=h1iuMYx4o5K/wSMzSMrhx56bQtq34xuwWbUbUvJycdmxmhmZuS0zeNISCEC0Zm9dWMxiWzOaUTvZF9GwOse0iQzqSKE6QkKxgHqohFL9WAQdfaL4C5elJBrFfrImZPX/R4wgj0/f4Ab5QA1qat69kzcGD3rwqp28VXaEqSdjvsQ= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:38:02 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:38:02 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 09/12] spi: imx: add new i.mx6ul compatible name in binding doc Date: Sat, 25 Jul 2020 02:51:22 +0800 Message-Id: <1595616685-9987-10-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:37:56 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 68b3ede5-2c55-4563-cc1c-08d82fbda3ea X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:3276; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: zhi5bks/3eYhSIO7gqEMhsO8PN22ZvqykxLH4O3rcz4YXdMQFmAD/ZCHKUnhszikKb1BG3vzPxQp7/NTiI1qMnJ7iv0WmDPEfFzXHTZqmAp3EK46WKpIZyDMFCYSmToKGhjAn7fiCc8kddLopK9QOeBaP59sY9kmnQPSO/6oGklCwdnL0vBiD6HVDoN99TUbbWvz+sFh8TaoW9GZPyMmbj19O9b0HrlBk0QoJ8M860pNVKlVKA2Ukinqgio2Iln+yI2KzGuvlHOIp+BzeLwL4FAtkwCEFkyR/iUodga5QVNirPDR16UZ4lrUzP30RoSyQAFr42qip5Q4OiwowDa5OKlWdyGzcsGiVFjshc6H2ttnndk6Owzgh0VsOWPnoeyd X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: GE90Q4JivHq58MK8uTolV9PKBY49+ypSI7FNE1+TWOCo/QkxDuqiIMZVT4NXaQCJEojzuqNlTw3DEZRq2SStkTeVpRs9A7EULd9BD4IAljY1gfVgU/xZVC1zKYopl8svbKMHFavnCZP5AQRQzRvnqmMlZPWccJIB7a242HtQH00O1n8DXD9ephlq9CS6FxptJvKAlAk0ElOXK1gqXQu1T0F9cH3G24l445Rg+JWcUH4WNe1rZ0I0pFP268GwPE0SgTmxXD9x19F14ue4pOVE1UiOycKjtdrse9JW0cPt4RrsDxI2pDdb7L8rdc4HymfJ8D6W6Yn8fj6O/4rEtir81opi4w1/xpJaH4lwdRjcDsOXmJthjTrb4O/0oJoo50aFb0GgCUh2XGD7WFpQ0dBCfahhikT4YkyFxIAYtS2zl574X64+YUJaarnkSmKAtymHH60zGJmVvK3eTIIHvUuBlbwXfunT5MtbceKP7AAEMqE= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 68b3ede5-2c55-4563-cc1c-08d82fbda3ea X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:38:02.1381 (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: AQexJS8eK11zeRehthypu8CnP4x/9F1Iq7IgP66wXrpaAQYwNsXAwg8lwR8Tw8wP9/b5T2CpvnGImuI8W7gIpw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org ERR009165 fixed from i.mx6ul, add its compatible name in binding doc. Signed-off-by: Robin Gong Acked-by: Mark Brown Reviewed-by: Rob Herring --- Documentation/devicetree/bindings/spi/fsl-imx-cspi.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/spi/fsl-imx-cspi.txt b/Documentation/devicetree/bindings/spi/fsl-imx-cspi.txt index 33bc58f..0a529ba 100644 --- a/Documentation/devicetree/bindings/spi/fsl-imx-cspi.txt +++ b/Documentation/devicetree/bindings/spi/fsl-imx-cspi.txt @@ -10,6 +10,7 @@ Required properties: - "fsl,imx35-cspi" for SPI compatible with the one integrated on i.MX35 - "fsl,imx51-ecspi" for SPI compatible with the one integrated on i.MX51 - "fsl,imx53-ecspi" for SPI compatible with the one integrated on i.MX53 and later Soc + - "fsl,imx6ul-ecspi" for SPI compatible with the one integrated on i.MX6UL and later Soc - "fsl,imx8mq-ecspi" for SPI compatible with the one integrated on i.MX8MQ - "fsl,imx8mm-ecspi" for SPI compatible with the one integrated on i.MX8MM - "fsl,imx8mn-ecspi" for SPI compatible with the one integrated on i.MX8MN From patchwork Fri Jul 24 18:51:23 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682893 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AE48F912 for ; Fri, 24 Jul 2020 10:38:13 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8FE1C20786 for ; Fri, 24 Jul 2020 10:38:13 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="QI9g3CSi" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728087AbgGXKiM (ORCPT ); Fri, 24 Jul 2020 06:38:12 -0400 Received: from mail-eopbgr80080.outbound.protection.outlook.com ([40.107.8.80]:5348 "EHLO EUR04-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727991AbgGXKiL (ORCPT ); Fri, 24 Jul 2020 06:38:11 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=OSCIyl813a74wFwaaqc0mf3M75BTdcXYL/gcpu0jVzqLDwbpILgfg/x4cdn7HAbQbpuo0HOFgWpnq3puvmnPgX0VBLoTtDDlcvsoeAd7/06hx87/VRFFSDDdbfdHjffhXQuj5Lid64eErBPiVcdowcoD1CY2kVoyChCTTiXzyG6uo/TgY8AYk4VKXqpwG9S5Cud7EL02or+Y3kSu1WhcoZMKA0UCCPtTPGFKJKFOT2WpC8N7ifTwacMzW8dN5DwDJT/58xkZ/ACL8BMhLK7j2RUv8NeYai6ot1H8O9pM/xJsAp7G9Fu9cG3zT0aCMgEJuVbyQhazFkN7JhhE9eXGMw== 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-SenderADCheck; bh=uNKNXEEdPeOOlP0E3WJENUitoaKeApNIO0w0G7TvIl8=; b=aybCTO6FSJLBoG/GlOTMmO6c54ZW0c7HMJaa+ab6eKr3QjXoCA2UqPLX6IqWIYy0U6r8fG/9rm7s5FrYbG6PgLK4/iBNHJ7tdp+xk43hZFkaWCPKxW/4uEDg7d5Q7EFpxrFPgjm6E+BleZAid8gXfDJ4Fr9GkLVB54wG5sLmCNKITwA7Cm4CahmDLahMydkMXjdOcZC2+/bHHwTmKaMBVVLpwR4Kq6YhPNVCnphIadwaEGGe5eDuicvdSBP8a9eIbi51VlVxIt5CWK0KO0wUnnGqcu4StZvmcxqRV3Z1Y/SX4Dz8QdIKfaDeEslC355Q8YUvwRpPxW2AF50lgiMYAA== 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=uNKNXEEdPeOOlP0E3WJENUitoaKeApNIO0w0G7TvIl8=; b=QI9g3CSi9XG1nSMhfDHIxE7JG1qecYqu1EJCla7vDjqkphhE5JRRx0M2G3LqCI+Y0RkOTtf8YoaCEPxkmpLHkDDBeWO78JgnBFC8jW4UG2UPTxlxiv0rBw2vJHIzl9yEmmNlGetAbeIVG1CAJqQeKKAL97S+QLGKlTA43XGZGKE= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:38:08 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:38:08 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 10/12] dmaengine: imx-sdma: remove ERR009165 on i.mx6ul Date: Sat, 25 Jul 2020 02:51:23 +0800 Message-Id: <1595616685-9987-11-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:38:02 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: ef12247e-02ba-4fd8-7936-08d82fbda76d X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8273; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: MJ5kzJHt89xpQpfmmyTIfkn/OtlQPB5VqI7zd8Ex46NR/c39FTrC0VJstQRNJppLH7yzLSyuohcOcT0pTr/wIRD905p/vNE9FQBsRcPs+mg/Gs/5O3yKhtUaxmSJa3HqTXzOjepL0mvDuDvQauPvWgQd8M3TuyNHLxpM4DdwVPnCy6pEFrCNqPX3KdkRNA51xBV/1BeCy76qmnDawdcSkjtk6Z9quBDGf3Xm2THPfYltznDwHIDD/X1A51sfR7X7ozC5aPqdyb0fiV99e4X4Lvk2Yp61nyZoFeNttw+AvwCNORpPQCm5bJSkqJ2Lop9BCMc+sCBU3K5WP57rTxGBhw5oqdhOEsll6ofaprRsRFOqTPP5X6wo6iMj8VjyJXKEUTKG+KogJoqFXtSB/s13mOm53iMSjqTquZLDD3vt9OSCmc6smk5hK99qiYUI2dU4 X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(83380400001)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(966005)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: 8FemPzLvIK0dobVhE853b29kLMLcmXX0+Bi06rOzIQZcZ1GYs4Nwbjnsy6eXc1Wuf+0Dgx0ckl/yjlURctq4AX1vzmSWvrnXEWYXKkciExpy88bFpsr1ogDiBFKb6qJnRNCggp+L1lX0I4No/yCINU4E0pn5oNDidJrQ8ORAUBkmyVg2TPG5Xg9Nlu5s5V0xf88C+8X3HaGVaBrFrLhZxjfCwcIeQhuf5coPcRD+LgO2lzOBpY81VL9tGO5liNnNrsp2tuhBZgkah+Xd29k5rxlCKcUhYI8k9ohwgUdsonPXAr1+yPN1saDdd5mydhKQ7fCIobdGl6qQ2dwjtE/MBhfpCbaTZS4ERYitViVTtOmcwvOsKG/1hGhfq47uXV2adNw7y1oSooI2sCdHZ8ezdEsTYCjLMBH4eOIMBDdTN/6ozS/bbvSEmb4A47ifgsLzEo7DmKxNW/h3IPekvgjXrC0G6jGGuOEdrSvjdSuIRGc= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: ef12247e-02ba-4fd8-7936-08d82fbda76d X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:38:07.8878 (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: PUEeBECkHH0wi/MqdWLB1fUMaD+cZWqda/T/DO62fmRP9HeB8OZtWjN4GTaL4sws+rJyi4eFgalzgNAn9u9sxw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org ECSPI issue fixed from i.mx6ul at hardware level, no need ERR009165 anymore on those chips such as i.mx8mq. Signed-off-by: Robin Gong Acked-by: Vinod Koul --- drivers/dma/imx-sdma.c | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/drivers/dma/imx-sdma.c b/drivers/dma/imx-sdma.c index d5d5d40..8735606 100644 --- a/drivers/dma/imx-sdma.c +++ b/drivers/dma/imx-sdma.c @@ -420,6 +420,13 @@ struct sdma_driver_data { int num_events; struct sdma_script_start_addrs *script_addrs; bool check_ratio; + /* + * ecspi ERR009165 fixed should be done in sdma script + * and it has been fixed in soc from i.mx6ul. + * please get more information from the below link: + * https://www.nxp.com/docs/en/errata/IMX6DQCE.pdf + */ + bool ecspi_fixed; }; struct sdma_engine { @@ -541,6 +548,13 @@ static struct sdma_driver_data sdma_imx6q = { .script_addrs = &sdma_script_imx6q, }; +static struct sdma_driver_data sdma_imx6ul = { + .chnenbl0 = SDMA_CHNENBL0_IMX35, + .num_events = 48, + .script_addrs = &sdma_script_imx6q, + .ecspi_fixed = true, +}; + static struct sdma_script_start_addrs sdma_script_imx7d = { .ap_2_ap_addr = 644, .uart_2_mcu_addr = 819, @@ -589,6 +603,9 @@ static const struct platform_device_id sdma_devtypes[] = { .name = "imx7d-sdma", .driver_data = (unsigned long)&sdma_imx7d, }, { + .name = "imx6ul-sdma", + .driver_data = (unsigned long)&sdma_imx6ul, + }, { .name = "imx8mq-sdma", .driver_data = (unsigned long)&sdma_imx8mq, }, { @@ -605,6 +622,7 @@ static const struct of_device_id sdma_dt_ids[] = { { .compatible = "fsl,imx31-sdma", .data = &sdma_imx31, }, { .compatible = "fsl,imx25-sdma", .data = &sdma_imx25, }, { .compatible = "fsl,imx7d-sdma", .data = &sdma_imx7d, }, + { .compatible = "fsl,imx6ul-sdma", .data = &sdma_imx6ul, }, { .compatible = "fsl,imx8mq-sdma", .data = &sdma_imx8mq, }, { /* sentinel */ } }; @@ -1174,8 +1192,17 @@ static int sdma_config_channel(struct dma_chan *chan) if (sdmac->peripheral_type == IMX_DMATYPE_ASRC_SP || sdmac->peripheral_type == IMX_DMATYPE_ASRC) sdma_set_watermarklevel_for_p2p(sdmac); - } else + } else { + /* + * ERR009165 fixed from i.mx6ul, no errata need, + * set bit31 to let sdma script skip the errata. + */ + if (sdmac->peripheral_type == IMX_DMATYPE_CSPI && + sdmac->direction == DMA_MEM_TO_DEV && + sdmac->sdma->drvdata->ecspi_fixed) + __set_bit(31, &sdmac->watermark_level); __set_bit(sdmac->event_id0, sdmac->event_mask); + } /* Address */ sdmac->shp_addr = sdmac->per_address; From patchwork Fri Jul 24 18:51:24 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682899 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 402C513B6 for ; Fri, 24 Jul 2020 10:38:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 245DB20748 for ; Fri, 24 Jul 2020 10:38:24 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="pk5bIdGa" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726520AbgGXKiU (ORCPT ); Fri, 24 Jul 2020 06:38:20 -0400 Received: from mail-eopbgr70089.outbound.protection.outlook.com ([40.107.7.89]:49672 "EHLO EUR04-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727991AbgGXKiS (ORCPT ); Fri, 24 Jul 2020 06:38:18 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=BmVY5MITVKgmkwgZGma3xTZPKY0fcum7lVaOXENzVykM2b7UWb/8os3KNR0EQIp0+JsaDEZYM0lGxLFjaUyIjGYBn5J5iULEOiavC0NqCYDKjMaZkeB3FoWRi02n8Kiyic7XLQ+yqD4QHWto1bRZjdCZaYtDLiAe1KVLrGLNbCoaK73neaCD/s9HdlHJ2WPUnrev2wfx3xlCo4+xtO8CtQFblkSQqm9pf7wSCAwIrcLtVlFk0cG9aro8kckI9sfHrvell+iS1dkNLUgV/V4qeshVkWg3rkDUQCsBNppMh73Lw/Jz2p3iS6XYzwMJNyjxhwQVucNEDs+1vxxCPjb4AQ== 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-SenderADCheck; bh=sZvU3VGhVcTeYxe4fB6geATT0prKN/x1vEpROhK8pVc=; b=HMXiciakCylmHSRRFqzK8nqkhsQiwdG6K6a8ovcLdl7fkGpR74BCjAmC6xcnMk1cdsleeS0gstyi5dBY3/OsxE+3cl53I5kXhbGj+yVnuGgCmThtKtcETAkEF02My2v+7T9TCW2pXdwikxXGV7h4kxgXw6F2IsXvmkWBPuv9JYLIbGXZbG52ULqOyQ60LSy9Vgof6sBCOf2nRWAYW4dbT5bjmC+eKlsTs0GBy8jPeFaD2XFsHDMZn6XRIXNE2tvNATTknHmy06sJoRplvDHMwtBVNVGDQTFPjgTr1gKW+8QqsH6PAK41mpR0HF8f6aGlKh/E2M5oORwdTc82usntIg== 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=sZvU3VGhVcTeYxe4fB6geATT0prKN/x1vEpROhK8pVc=; b=pk5bIdGaPvpvJpL3YGPFLXpPXSxCFUFDALwxMdGxlVr5Kw8vxOzIk/9ksda/jVmkROWR5y2Jez43/cuos3PAoM8L0QjN4ZN9xQMFRUU2xdBHK+W6lcCkedF4Qr6l8FxE0O7F2+BOk2Vt6vKBelDzfgLN9T356BYzRGgNcx3g6NE= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:38:13 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:38:13 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 11/12] dma: imx-sdma: add i.mx6ul compatible name Date: Sat, 25 Jul 2020 02:51:24 +0800 Message-Id: <1595616685-9987-12-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:38:08 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 68d5d591-b89d-4994-1acb-08d82fbdaadb X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:632; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: bsM3bMuEreoOVGTbH0uU68lUb7meg3r/Pt9JhagGUEvFVbmOj1ecWBuJeHLp8CoeUVtZxo73xEJlSUIGsKMCI1yUSMesx5p+bg8yKB0UBsahlLD76RED0b84Iq47LJuViIyyHNd4wyjhqDBN0XVwUKoEw/6q3NhA0UXItyz7OLBEjdVIz8Uo7zfaytLj3QWSgMfmdjvi+APfW22mAO7Hnkx6VKVGLW2fT2wkVwV14l8o41wT9r9BDzp/pIYEyz3io9ic0pVRg8VsUuNXK3BIBxu2/fXE7eUwoDnXcbRvzDVrg5UVE7T8YEqvYtqsTE1Xj0o+23lvYyWXxmHSuc7Vrz9PulOB5SWCeU2H1/4jkkI= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(4744005)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: 6blbqbqVOi+TkpW1uzYZ9pECg98Sz70RsA12fYCnsdhcXtEOekt+H+jsnO8eex6hAV1DSAukiHTVMPSyENUsFJ2mSWGfKkQ1LHsAOlBEh361l7m6ZVvTLvMW5ndGjLgYxToriFWswnSo6yuOcfHxXfn8IrDyudPHHwHeCVcRaSA51lBtUw9T6UOVSUc1f+Zi2cRzGqWnw3VYgBBpOD7XvCOxtvzNuImnk7wDI5D5f7tX8F2DrBk4nqrdfIXCJ7vm7nP3oHFUAiSl+drW26oW2x+iRoF2XC0EoyKOMoaeL1bULQekroDdW/8OdYYGozHgBT+WigMp89L4GM5alC0bwdIXUD5Tk8/Yo3AFD+YxRxvQWxAKJdTpO/Py1yfuNjrPKmd8CC9jDq4VPgWRgMMdc/84zR+XicIexC2d7jNRJq1DxwqfDxw9L1VRTcNgLQwLvSyK2oFt2PSfIpFWMIhjyXGCjXQVA6D3QhSpcy5Z8Yc= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 68d5d591-b89d-4994-1acb-08d82fbdaadb X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:38:13.7703 (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: QaJIkXN5ecx+nUUTwSW0hZUCiE4Xnqkc5+CWEQ/P7XQUnwKDwQeofPsSLBrt33j6Z82/07Sv8Y5s/rzEdNGKjQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org Add i.mx6ul compatible name in binding doc. Signed-off-by: Robin Gong Reviewed-by: Rob Herring --- Documentation/devicetree/bindings/dma/fsl-imx-sdma.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/dma/fsl-imx-sdma.txt b/Documentation/devicetree/bindings/dma/fsl-imx-sdma.txt index c9e9740..12c316f 100644 --- a/Documentation/devicetree/bindings/dma/fsl-imx-sdma.txt +++ b/Documentation/devicetree/bindings/dma/fsl-imx-sdma.txt @@ -9,6 +9,7 @@ Required properties: "fsl,imx53-sdma" "fsl,imx6q-sdma" "fsl,imx7d-sdma" + "fsl,imx6ul-sdma" "fsl,imx8mq-sdma" "fsl,imx8mm-sdma" "fsl,imx8mn-sdma" From patchwork Fri Jul 24 18:51:25 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11682903 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C3BB0912 for ; Fri, 24 Jul 2020 10:38:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id A5A9A20767 for ; Fri, 24 Jul 2020 10:38:28 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="bzXYWz+U" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728135AbgGXKiY (ORCPT ); Fri, 24 Jul 2020 06:38:24 -0400 Received: from mail-eopbgr80044.outbound.protection.outlook.com ([40.107.8.44]:26390 "EHLO EUR04-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728121AbgGXKiX (ORCPT ); Fri, 24 Jul 2020 06:38:23 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JfQ0aN9hEDk1gCZDCbCrDisjP+Kdx5OTioxy8+4dTNhdl/U0RQ2a34XNY2Q7kLE07krg90fojP7ZsTwZ09QZgyWF83iWnxbESp8GOsq/id/1P2828V+z05TZ+nZSbc8f58vYvnn6Dq1K0Oox2Q8pAVSLenXEwokdyKRPddNGl6TQxs5ATwuZ5tsTaOeXf7PVqi51dK5V6zmuUmX87ra3RCn9WvlNJxFzOaBfbsu0TQm4mtZTcH6HQpWYo8V2GPjuFynhQNmehpIzwQ7sxBn+AHdogGJivjNucZWYPWlgQwFnfD9s41rmUOUcfoPBaGVVyusnSnchaGal1Q+I8hBWKQ== 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-SenderADCheck; bh=XBIPq6OiaZoFybaiM/oj4EKt1yY0a1UUP3wLjjdf/lk=; b=LyV18mbLo6nRy1JoGc11IP0jD2q3vmmrwoNUmNQn3m4jNKl3KIz0b3f7KlnmjtqTWbAkTOUbuc2pImZL7mID+GmHysXnCF7Y9Spjt93pZ3Y4OpaoM3km6OqB+5he9kRJ3DcqBfltmqN4zdCZ0TKx6nb17XNVDmN0m3PfBt0t8QGTjzkGppUow3FuIEFwmKjfXCCa2vZg8+oEMHGhczFncQMI6XSMzFwM3z7CLl0Oi7FWa40YZ6NDUHXbDLNdJGW2NJQ01Z0eu92D9g/thJ1YO2C4zVtimJnqm/OehmqkomFvfQ9vO+XTfhEjbUCo2r+9W1tcHSIXkWr5SikPDUy1mw== 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=XBIPq6OiaZoFybaiM/oj4EKt1yY0a1UUP3wLjjdf/lk=; b=bzXYWz+Uf9QGbt6x9VMqEhsz7/LYrTCpZ5IWYNpqYlRPL/kR+6t+QDi0M4fH7uMCPUen0KiliravpCKLDqN74v1mDyFBVfETzIzXEbldLEjwVbQpddwwz9Z31lKuUeGfMGR0SApBzZGIxg4MiRC8L+Hj2kLtF2pJE8CRquSbdrk= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=nxp.com; Received: from VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) by VI1PR0402MB3710.eurprd04.prod.outlook.com (2603:10a6:803:25::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3216.24; Fri, 24 Jul 2020 10:38:19 +0000 Received: from VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d]) by VE1PR04MB6638.eurprd04.prod.outlook.com ([fe80::5cc4:23a5:ca17:da7d%6]) with mapi id 15.20.3195.028; Fri, 24 Jul 2020 10:38:19 +0000 From: Robin Gong To: mark.rutland@arm.com, broonie@kernel.org, robh+dt@kernel.org, catalin.marinas@arm.com, vkoul@kernel.org, will.deacon@arm.com, shawnguo@kernel.org, festevam@gmail.com, s.hauer@pengutronix.de, martin.fuzzey@flowbird.group, u.kleine-koenig@pengutronix.de, dan.j.williams@intel.com, matthias.schiffer@ew.tq-group.com, frieder.schrempf@kontron.de Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, dmaengine@vger.kernel.org, linux-imx@nxp.com Subject: [PATCH v11 12/12] dmaengine: imx-sdma: add uart rom script Date: Sat, 25 Jul 2020 02:51:25 +0800 Message-Id: <1595616685-9987-13-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> References: <1595616685-9987-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) To VE1PR04MB6638.eurprd04.prod.outlook.com (2603:10a6:803:119::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from robin-OptiPlex-790.ap.freescale.net (119.31.174.67) by SG2PR02CA0046.apcprd02.prod.outlook.com (2603:1096:3:18::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3216.20 via Frontend Transport; Fri, 24 Jul 2020 10:38:14 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [119.31.174.67] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: f8184ba9-3b6b-4e67-a54e-08d82fbdae5b X-MS-TrafficTypeDiagnostic: VI1PR0402MB3710: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5236; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 40iTtDX0VfalWJkdiF/LCDsuh1HIUPosZBagUAMPnc5dAZMKT7mFOZ7ddTzuxRmalAmeLFX0qz2ZLBDupvLdFCh+TSYkiTKLOY1Q3HUT7OvOOeZzW/shKY4+TvspO9X0YM7is/8bAwbLABlp0UPE9TvUii5SKpSxfPcXXTA79KVqT4vJllNQ90We4BWsDMqZkPTqsC4U9z67NmID7PJsG/vx33WMSZPHnY2DWJShKEIM3RnVQ87pIPLfujIoBGwNLAPbkiCNWVGr7tqVb/69y3p2a6Mxn4vcL4vt9OJ3uTIXkV7wk7jELwlMQYv3gkNyOrZ3uoiNh5eKLqPZcPY/ioL1D/23bxQi7nmLniU3pPtPv+c9NdvjEd0baYMp/rdI77HqKSj42/LfAO979/tbV0TZRL3wUUNoewHMdkeNBG0JGsGHqYhBrGoLD6ujK0T9ux3HT7W2u+IpfbflSp9aDQ== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6638.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(16526019)(186003)(66476007)(2906002)(8936002)(83380400001)(66556008)(478600001)(5660300002)(7416002)(52116002)(6512007)(36756003)(316002)(2616005)(6486002)(8676002)(26005)(6666004)(86362001)(4326008)(66946007)(956004)(6506007)(966005)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: 4mlP6SQzB9Y/Ds7L0Wwf0IsKxoXAZfEFflkkEojcbYjoOYpsGfIwLSo3w9VVg8cz8E/yUrVg2XWbJvzwNyP/aglcO5MHvBohRSMiK4DZgwv9SUgBjqpAEmGU5nSCuAXQNzqu5Fp06K0WhV7yOz5Cv6try42vqwIVAlLm1bgYK3vvs1eI/nf8G+UKUU2oVbnVxEHAmiCVqIOa92e3Y38Vt/EjRomL4n1HApBWq8tZOD4doMQUe29Nfejlob8nzvmTncE2SvKQZKpvGnjjt/bTmHsf86M5TdaXN9l5DjoOxWSf3zeTEacfDsaqOYDaXGWBRwS+8xwK+kWQa9Hi4ma2zyFcMQTMtMCb5yTlY4SK4P8BhR5t/I1bz4m06i7+f+VWPVYyDCMg1lmxY0UNpY/QxFf39rmFuQNhffuNMHnx+JS5An6sHrXqlkXGvTYj/aWRpjbjmNj+4B3JXe02eDiftDTBRYjoEnKi2eMZaBiI4gg= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: f8184ba9-3b6b-4e67-a54e-08d82fbdae5b X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jul 2020 10:38:19.5320 (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: wKZtvEhK4VcFNbtYMiZyPmYaWiAMTatR2+5V6FwMYyCheahmsY6FQ4ZHF01Se1F1s7HPQr0bRohAeUHgOk4fMw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0402MB3710 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org For the compatibility of NXP internal legacy kernel before 4.19 which is based on uart ram script and upstreaming kernel based on uart rom script, add both uart ram/rom script in latest sdma firmware. By default uart rom script used. Besides, add two multi-fifo scripts for SAI/PDM on i.mx8m/8mm and add back qspi script miss for v4(i.mx7d/8m/8mm family, but v3 is for i.mx6). rom script: uart_2_mcu_addr uartsh_2_mcu_addr /* through spba bus */ am script: uart_2_mcu_ram_addr uartsh_2_mcu_ram_addr /* through spba bus */ Please get latest sdma firmware from the below and put them into the path (/lib/firmware/imx/sdma/): https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git /tree/imx/sdma Signed-off-by: Robin Gong Acked-by: Vinod Koul --- drivers/dma/imx-sdma.c | 4 ++-- include/linux/platform_data/dma-imx-sdma.h | 8 ++++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/drivers/dma/imx-sdma.c b/drivers/dma/imx-sdma.c index 8735606..5900e32 100644 --- a/drivers/dma/imx-sdma.c +++ b/drivers/dma/imx-sdma.c @@ -1729,8 +1729,8 @@ static void sdma_issue_pending(struct dma_chan *chan) #define SDMA_SCRIPT_ADDRS_ARRAY_SIZE_V1 34 #define SDMA_SCRIPT_ADDRS_ARRAY_SIZE_V2 38 -#define SDMA_SCRIPT_ADDRS_ARRAY_SIZE_V3 41 -#define SDMA_SCRIPT_ADDRS_ARRAY_SIZE_V4 42 +#define SDMA_SCRIPT_ADDRS_ARRAY_SIZE_V3 45 +#define SDMA_SCRIPT_ADDRS_ARRAY_SIZE_V4 46 static void sdma_add_scripts(struct sdma_engine *sdma, const struct sdma_script_start_addrs *addr) diff --git a/include/linux/platform_data/dma-imx-sdma.h b/include/linux/platform_data/dma-imx-sdma.h index 30e676b..e12d2e8 100644 --- a/include/linux/platform_data/dma-imx-sdma.h +++ b/include/linux/platform_data/dma-imx-sdma.h @@ -20,12 +20,12 @@ struct sdma_script_start_addrs { s32 per_2_firi_addr; s32 mcu_2_firi_addr; s32 uart_2_per_addr; - s32 uart_2_mcu_addr; + s32 uart_2_mcu_ram_addr; s32 per_2_app_addr; s32 mcu_2_app_addr; s32 per_2_per_addr; s32 uartsh_2_per_addr; - s32 uartsh_2_mcu_addr; + s32 uartsh_2_mcu_ram_addr; s32 per_2_shp_addr; s32 mcu_2_shp_addr; s32 ata_2_mcu_addr; @@ -52,6 +52,10 @@ struct sdma_script_start_addrs { s32 zcanfd_2_mcu_addr; s32 zqspi_2_mcu_addr; s32 mcu_2_ecspi_addr; + s32 mcu_2_sai_addr; + s32 sai_2_mcu_addr; + s32 uart_2_mcu_addr; + s32 uartsh_2_mcu_addr; /* End of v3 array */ s32 mcu_2_zqspi_addr; /* End of v4 array */