From patchwork Tue Jun 30 13:31:05 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11633127 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 D035B13B4 for ; Tue, 30 Jun 2020 05:24:45 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id B1AF3207F5 for ; Tue, 30 Jun 2020 05:24:45 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="V4jFSlqx" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729296AbgF3FYk (ORCPT ); Tue, 30 Jun 2020 01:24:40 -0400 Received: from mail-am6eur05on2054.outbound.protection.outlook.com ([40.107.22.54]:35649 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726311AbgF3FYi (ORCPT ); Tue, 30 Jun 2020 01:24:38 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=mpeyZu21t3YjJ9v7QHv6XWQDJToxxGeP8EA2SKW+LlljiuysfLiXVyaUbdkHvKF4AUyi94LvRvolgqLzJy5pvGqFI6QhL/6hu32/FD6w5lweAG8cjNd43FmOvqTQd5u4L/l5Mi9qMNL2FLfSielGMh2iPVsihOxlocws9fbP0pk0e5szc0j1w2Q3Nl/aBBQA/Uj+ps46YQUqoIIXGT6IMVsVsFJYD2fZty1eRnTsibQ1Y7N+eHULn7whNVGosH0tSdfvs+R9C2S0rQZo9ux6f40xJagmH7PIq2hO15uoVf09di10cCOQDJY47a9kMyYwCXoMws5VpCN5IVKzXXoA0A== 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=jfHDnQ0NHIZJgphQWpYXAf0nx7QUOaN2ydSyukLNfTe9VZFGFxCYzr+LV3YAbFJ2sICS9wdfgrANp6HAsvg2d6cCvVlXXph4dPV8Yp7HoikDHq9h+7vRn66ynSdAUUXXGal87m4EotkV93ZjLv3jhmrHFuQFj+ktKqbiSXMz1XRH/rA4sgWYXh4JjYer5eMPJ4aMfIjKxVUS2xe99RqwmfqYfbseFCaI9RJ71L7idvElwXSwxA559W+15MnhpRlEXHKA76n160xKnJHdtD1y7AFofDV82sAlxf3R4xhuZlyZ/A1iDmhc7ogVVj+XDBkOvaI8iazlZVxbmiQiW0lNDw== 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=V4jFSlqxnhOAgaVE8u51+DbJYQOPo5m49s2TyXQkm7kttFWzKo3Rhv6OGrHzxkROsH2LujSGJFiPU5OnP+66xg+9/V4mDag4YONJSCMFFJXV8pgF39EtugAHCfFj8AaHTDzY+bxXlE9K6RA5YiGzrX+oZP7EnvwkvilsepWACsk= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:24:32 +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.3131.028; Tue, 30 Jun 2020 05:24:32 +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 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 v10 01/12] Revert "ARM: dts: imx6q: Use correct SDMA script for SPI5 core" Date: Tue, 30 Jun 2020 21:31:05 +0800 Message-Id: <1593523876-22387-2-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:24: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: f98a71fc-f7af-4818-702a-08d81cb5deac X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:660; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: DuikhDMDFjR9J5Z8QHfDvQRkE8Q3sgDfmLINSAvcyFyzrksWRZehexrBxd88papUntoDUUcRKUvBgrhKOEwu3hFONGoxi2u2ALcy0nSvTMyXwqj7dPd+7d1OGBlpQlTZfH3l8VWz9/FRSEr8pbpqmapeT3YMOVYFvouC0LdTflGKIEWptvDjug3VVIiELZA++hxeIGZLle8xK44qUkS2dtXvJwE3bivi7NANbrpeLdKQyUeDNjt/8MmrNZNlD12psKXqqS6jUVJqz/a/bFAOoA6jZDGKGs1qC7lVe1sfKH3A7UcPwcs9ZqONpKY2a58IQpdKswncrHGXhpHRGuXCW9kSN2U+4OEnmJuGP1odw9RQuUwgozQIw2wxRbkKYsTS/xhXwC6I1Kvl0olInBDVDp66bltILSCGGCGe0BN8cOeOUhXk3ZDz81Qpkib/yWDV1+D6ONRMzn7mdhblTu9bT9KEBNIxu6kjsEkaiG0fClw= 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(478600001)(316002)(83380400001)(66946007)(66476007)(6512007)(8936002)(66556008)(921003)(32563001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: 5luLhOCNC3d1HKoGBGVrHETJlFU4Ol8M22oKeU4qDFrP4pBkRzvbALFUNlk63NdOndXdXxKcZIGwI6PZKhknuiOAbQLyijSV5QOZMIGUAf3URjVsv+RgJX0LtqXbHyaIwVV1OswUV9GHM6fTw/ByMc3UDnUNTYJpgqe2YA+iSc8vmM2RGx1V7+yE1bOJbRSG4ncPYWgxVVcZ9raxwe60AfEVDiHEoCL12yNTqQHad7ygs8jA2SEOhl6myj1y0MjCRJ26V92H6p8oCqKZ/gZQWQIwkszE/mpv6sKFHB+SFB+aa0eOHUeayi+d7iMuhKwH+2d+u1eXTftAWIHfKK6YARz1llqLQh+djKJOMSBvuq3kt+UG1/iM/ymRLgoMveL/mbut6K6dL4oRxORD0TXqZXlr5D2+mh5HU0eBnvN8sjWKzbaFPY6CG8xN3G2pSNBvjzk30sSnwcdVFgVld7JdyQe3YFTt9NmWls97op+XoY8= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: f98a71fc-f7af-4818-702a-08d81cb5deac X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:24:32.6844 (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: hu9RHoGorCdkQTlnqM2zwzl8uAha484clxXFYFfXShvM6DcmKwPYIRICf97ePO0hGROtDiKY2p/7/TxbbcPYdg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 Tue Jun 30 13:31:06 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11633129 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 284A7138C for ; Tue, 30 Jun 2020 05:24:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 06554207F9 for ; Tue, 30 Jun 2020 05:24:46 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="kNrhqiD6" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729418AbgF3FYp (ORCPT ); Tue, 30 Jun 2020 01:24:45 -0400 Received: from mail-am6eur05on2054.outbound.protection.outlook.com ([40.107.22.54]:35649 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726117AbgF3FYm (ORCPT ); Tue, 30 Jun 2020 01:24:42 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=MuohOX7msN/wn1O9mX5ikubqdlH1vtst1L7s4fb1dnEDyIxzrYeBhdLMLQmneEe8xrLPSNn21hh6aPt9dUiBmlPbu/7wss64HqpT16gIV30r9cWLCB7hm/YGufGSd37AqtGVu1UNWzyiPUlU5VkZ024J8OzJtnkWadwhqG4/Spe3QZaOWyB5dk4pIxtMyLDmnMxdCaw8LDfKTbR1Ub4gYovUv7WvloSMjj0qBSBc+MIuz11frAzKOZF08H+UlNPSM/2KXMdmo75F9/t1A+kQOealYTQ4d0RqCYdYaWH0b5fYFh9gRkdHev9mbd9KU49nF/3fTYdFK6i27pBcIO4FDg== 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=JeFjuX0Jh4XqYNC5bBhfvjMOs8el0zRZOpgotlbvzpRzy6SbZ9eWO9qIqJUp2ghopJQIHoj2qnivEw3VypBoWoQiIms57zNu4b1rkOULEDLrDJSbcdgUlJFAMzV1rJ912X7dxTknzgW79htkaC2ZN7cQIG9TzyTl6cQqFUBPgc8jpF4wdWqwuPguPgZ9CsetSjbvA6qDd/Vi2Ub0Zya1+u2y7kU2vwenM4E1KzW6y5C2ApcYmh/mzimSVI6rm26EDy4nBS8jo75LvrPSOBq+4MBLkNsuX1Q9exWa2tFx3QQnjbqhj0RqiXvtIPzIS5xRf/tlIzcEvmdquWVNpPhgxg== 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=kNrhqiD6Xspc3wxHQq8z0RTsUrfQe5ZHU3WSsvx0Pk7C6nyZKqvcBEOgeLHdb60OVgxm/pNzjdPb1tDNXUZTZSiRyyS3glWYFgegP+j1NlsfOFV5SpM3crIVzij3gDZq2WSfFOoVVPtuJPSNM7VUKZPOrlA719zw7AvPxMyoFeQ= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:24:38 +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.3131.028; Tue, 30 Jun 2020 05:24: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 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 v10 02/12] Revert "ARM: dts: imx6: Use correct SDMA script for SPI cores" Date: Tue, 30 Jun 2020 21:31:06 +0800 Message-Id: <1593523876-22387-3-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:24: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: 9cb7d8e5-0ac0-4854-6e55-08d81cb5e20b X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:660; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: GeZqEsW2OJVgSWbYf+g/ecP0cRLJ5k3CcmQ+ztWd6qNqBLJFOcxnrdEueg8X3AJfMt9/ZiFc5BY54BiDsMOJseGSArACOXmvpaAOnNrxk1XayOvzP9VeCBnDPui7CZbUMCYGssKe0Z2JKWoreubGh2cRelKis+rCihrn+cU/i0T4xr2NnkE0BBDJ6iWixF2p1wkXrU5urPQ3yYNxxe+qiX3+8Cn9ZYmClO90v1H4rkxgH4ZEU3aKyAseegd1lAUM5UV7UtD+/RIoWIlubECbWUk8UkO0p7dT5kAxGJ7+Tg9sOtyY3kydJGoDkisPtxS9ogo0xbh7nF7Ksm5b8hI5n3Fk0jLInkWT534VlnLTIH3xGqjwY04EO+lZEirw/Aigtae4OSnJrKjxE07ignDq6sBmgoyni3o6n+4hRUcMOYslC+bOgO709v2Ptlgsr35PwRCuaUP1xSG3RyY6fS5B7w== 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(478600001)(316002)(83380400001)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: 7XYxF5Grt+yVzbYiNi1rylqO4K7w11L91/ZzN4FR4U52HXIVNEKsvA9Hxy4lgtlPjbHJa4FJSIR8T0d+QI8LgVobUgGW0ml9rbCLZEOx4CMehXQZSQ+21XQ8TqMEFPky50u/WfsQTTScrCvPufPXdRgSqUknihzLEYed/E3SX/uUjpJ6qal3uzJZ5NyZT58G5DsN+05m0jMFZ+6jukGsv1bBrKytx9xHMLFe1ytNPKwLOk733Zhp0fkSv4/6EoR8rZq3eApCH1Vqshc21CJB6IXgUbpnNnyNcHiiLlzjCZgIXCJnfkp1dQ6UHt0J9n2ngj9cjFmBwHrCLz36xZWHJ+oPQaivlOtbUssfiOsg0mh3D+H9wz3MAHbc6uBTFz7T1/G/24QMk2IbpCN8JQwKhH+oc+/tkPRp2UI/XWAQebCfkoTzkdQECFctokOADt1qZg8wXyLF7BFEDLxm/rnNn7i9qs2rGavTX1WyDQB9rfY= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9cb7d8e5-0ac0-4854-6e55-08d81cb5e20b X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:24:38.2172 (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: nDF2aYHsyAW/8e62KD+brBDB6WI7I507Uc6eNbyp8kN9R9petDXuL4gmIoENi1zyE1IlCdCxokd6Mxuv2zNFLQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 Tue Jun 30 13:31:07 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11633133 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 40760138C for ; Tue, 30 Jun 2020 05:24:54 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 1D77420775 for ; Tue, 30 Jun 2020 05:24:54 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="jYrxVPKx" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726117AbgF3FYt (ORCPT ); Tue, 30 Jun 2020 01:24:49 -0400 Received: from mail-am6eur05on2073.outbound.protection.outlook.com ([40.107.22.73]:27808 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729429AbgF3FYr (ORCPT ); Tue, 30 Jun 2020 01:24:47 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hKOUzcaAm0Hbk+XCidhjPYU93ALuGqMSEPibYsESKsgXWX/ppHd/VyC1+tELlOwPj52MSn+pfSJPUXgOfcZzbU2NVV1pUxIDHVPottEvzYibkHbK5C4tgycmopZnJdzeh5I0m7LyQU7YhOCr9RD/qD2TWewLoUdRFgECWPEkXO5pTsejOp1JttOiKkwC2Q98cJEWDnXaUmLLksaPGkWUG8MC3sf8NCI6dmR1TfsmvPw/mmVbi/jnhB8rhAuyU1FcsROzPn/9ph3bMXk2QIt6zaB7R+J6VDZABAFRB+YP5GyFZ4zzrwIWPm25LlkUExTVdo0gtXi86eQTDWhO9H/f/A== 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=G1eSCJQLTLYrVJ7C6XqMakw1cK+5XFRkl6fhJ0ipWtFFWDd8CrZ+qjpCa8w+IGTRWRdtmCOHp21ubSosdn/Xlj84TbN4wJggTvjEcG3Y1g8XGFTywjn9ve99TmiMltx1nJJV/65uW6wTvJiR637HJil6AZCb8bEjOIQ7QwT5goiGMlPi38ouhgFIAPqE8ic26qixHS5FwVirDWka/MEtX4bk17A6PJ55sCi8tAi95GehQZ7jN35hqXq8Q0y+bzrySyx6A3Yz5l9IS0O3XdZ9Gcl9O8hltwV6o0m3k34mBpct4SXOsA9ro4SUtf7rHc8kRu9IslwnPFGe9wXjsQU3QQ== 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=jYrxVPKx1whSk79TUnbfKlK0qzQgUMP43Y2CFyPMSEKIeFI9xAJxTHANqffw0R7U+LabdfSoqWVvmLHNPUafm0c5Qy69kiGchktDCVJSNrj5JXjMnX9I/d+1dHAWEokOBdCDspeXkpL3HxJFUoLJ5sHl+KuBheVc4t2O+JeDNJI= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:24: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.3131.028; Tue, 30 Jun 2020 05:24:43 +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 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 v10 03/12] Revert "dmaengine: imx-sdma: refine to load context only once" Date: Tue, 30 Jun 2020 21:31:07 +0800 Message-Id: <1593523876-22387-4-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:24:38 +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: dc80ae24-7547-47f3-f42d-08d81cb5e559 X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:119; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: PMu9+mQBRNx8yC5/nVDcs/itvaRg1ksj1kmZR15S/8DG2EwtJKvkEO5DkE+zGeUIwkO6Sb/TAnhO3A41Dre6ComUhTibwWllX2xfxMpK1wXtvBcRgM30G0wcBuz6nBYea4rOVRqko25L5cKkv2pRM1PfPQzS4LK0jSFBX3pQQ8KnDL7ApE7dloJ0/mCY3aeROpv8PfNbTKczlKe8/HFXOdYWqSt+qcZHcdoRweHYlFhc+MjErd+RKoWbhVJxN80TIGMMXZGa4ky7XFLcAgc3QwVppNfU2UZeWn4kgjZP9/MSRsP865QaODscA1KP6ffILmXFpvRJKFmQO4mnVfVPlJoLSDIPGvC3+uFdgISPFYeADVgh/h7niwIVMwgkibsV 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(478600001)(316002)(83380400001)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: +/XH65o/mOhYD5+trLY0On4cN/32lFGPhZF5kD3Gz5ct+ZHfz2Bkuiop6Hf575eOupcRb5kTeSL5dNfUyoS/g2fuHn7ZBga6bvEsM6EQHQjBNDhvxFbFi/QjpOMybneuH4Zbpd1g9+HjlvmOHxxu0RbxNa+8KaHOoaUpH2mpS80PCCSMo0BCduqdP67c8wZJgEZBnRunx2LVQaYtkYoi51fT6JmtCf9t68+fuudi7LoSHcdzF05zvvYCI5/EuoCMfpQcmZJSGxGPLJXhnoUQAj1/obkOeyPwU7n0J84K7NVu8r1mlVESCWdNT3SJMUsAAsHI4md5e9JaPjREPxC6VR5fr0cKaMuuSXySIRZivlBinfemCeE7ocRkbxUJmVyx9F7eIkAclX3rNybKWeckK1TB3tpwTrMpCdscDg9x/AEW0qz2AsJe1V68V9t60hwySMdv/483hL3EkKq5TU9wcv2W5y1x3z5mlzPC29iKeC4= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: dc80ae24-7547-47f3-f42d-08d81cb5e559 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:24:43.7709 (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: +qIQ96zN+MBGlSdhEM68R622cue7qgol2+WQO5q5Oc7HE4nbTErJx+Zh8o0Lxmnj4bs9OoNJkzk1emMr6NN0ow== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 Tue Jun 30 13:31:08 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11633139 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 87C7313BD for ; Tue, 30 Jun 2020 05:24:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 6E88C207D0 for ; Tue, 30 Jun 2020 05:24:55 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="lRY3lzEX" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729557AbgF3FYy (ORCPT ); Tue, 30 Jun 2020 01:24:54 -0400 Received: from mail-am6eur05on2061.outbound.protection.outlook.com ([40.107.22.61]:39840 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729538AbgF3FYx (ORCPT ); Tue, 30 Jun 2020 01:24:53 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=X0I4p4mwE1Au/ACq6Nkp16IQ2sbIzSLV1Kh6HBx+UD2tlkaQvVcNdmGynAHqepU3YXkvNgUweX4PFE3RsschvexyJvJZrXmfyA35xV/nSbkLNUR2YY9J0tDTbMLyQvUboa5UuxXFcppUf2wC9y8KCMRQi2MCSAZdM3rmb35yNjUlz4lfgrCmmbE/GgSO5zVGSRqTwQk12HevWJ+Eswlcfz80aCsvDXZjiiZ4Zg+KgOSAMPAl8J9YhwFWnIxONRIRm8jUlsL11qhj9clUl7r6EpehdW19O19Hj37Sm93OseDFIxlOnlI89KGhSvfWRBtSxXYUIY/j6U2+tWvIwUVUdw== 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=FAQ4GqUI54xU5srFjgeZt7tc9Y6AVGTSD6VfveHOD0KqLXJwHgOrozexykBKnD3fwMAyqdsEh6b/33bGK3Ok1CKDcbumU4r7u/XPQyfHaK9fDRRElgdnviPslZY+DXNSSij2QHr3hTxIaETZNdT8vGrEcNNvk0CjMdwDtNQmnGsf3tzV4Tij43f5zUvGSoOkJkns7TvSUAMlNgQHbAhGFa+jML3WbK3tLRkeSOl5FlwLB5nxdg2UDXXOR069ad0lv4luuDnm9KgG/F+nWDylgFHS2wGasOD2QH2+P0mkBON/YBblGobaL0Apuxzy8Ko4VxJXCFjKpJp80e/4veSWXQ== 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=lRY3lzEXNqM73NAVfgWATpyUCMGUaBtQ7sU3uuuKCesL1sGCt17dbTkhNVu4vrptcbx5IKN98ZdxKLd3fPoYUsivCiEC6v3tvbGvIp8WpbuSH+dH/ApupzQ0wJmsaQmZLqIQbA4lmk7yKHEYdwOPxKkoRVTVsMM76N/mao+h6cA= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:24:49 +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.3131.028; Tue, 30 Jun 2020 05:24:49 +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 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 v10 04/12] dmaengine: imx-sdma: remove duplicated sdma_load_context Date: Tue, 30 Jun 2020 21:31:08 +0800 Message-Id: <1593523876-22387-5-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:24:44 +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: 1ad5f176-21e6-4493-6c95-08d81cb5e8ae X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1923; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 0Docbno7St/5j7AdczpFnfDGZoCMmxworl1QFYzF+TvyeX+Gfym0jwNSJ1zAlsGrZ5zMiSW5BVEb9m+HSM3wQNLN6B00a2bK8mmSFTez76881ROOQkkABUINANl+RJLScNdEwWwZYZjZuu5jlwqdgQu2wvIIQeNW0yGFVZyeM4YtE0GKS11WsrZbZvQybkHOJ4N0S5hwUYG0skTskP9O3/ViPAAbrN3NoOqIb1GjxFbGj58kxEXEGbsWs3GYsftFnjGlBYwhzjU95FEsZC/bsoEJwrfBpRq2mRu+hGVQ2yYTCH3LliK8r2WJ9Szb+YocIQcf/EfaLymlRNDpMkRsfO5PCymFpxpIqOGRAMnFjJg/olKrPtHiBrfyrWt7xIAQ 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(4744005)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(478600001)(316002)(83380400001)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: eIEpCtfuEb5JctSF6kkDFf9mM0poq3UfPfQce4M8jlGDp2HE3du5ckriDKIjW2HiohfQ/4aMVeP4J9fqhTfV9CnF4zgQnSrK1LmQEIZXw/uAlif3jevBTkGngLyWRauvqdemi4xN+9CeftkYBwfewTyzqyEkqcipH7VO/MQajUuoVa0cwS3b11fdx6L5VAdeNrritMuJicZDewGpN71YqIGlApWjsEPR102cQ1goPXM8CFfVwmtT3WcjVF4AyQa4nvWPnr+tXO9gOZ4zAiszxzCQ0OzJ4rTuwmq64/XPpYYNwF55j3qei57rIHuePve5jzogtMOy0t/pDCOOREI3DaaRml3cQP519u00cMToNiCoODGgtXxKTFPIT9yjNF9rs2/E8GJ7HP7f0YWsizIrU+QzCMlC2VH1uWTRORTwQmxReVQJgfrigaPM7i+7Byz9QTHW0j5LK1//LlxJlmwFS3cdNkzU2EFERmR2dupS/54= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1ad5f176-21e6-4493-6c95-08d81cb5e8ae X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:24:49.4616 (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: tPs8N/F+svlGlx7OTpK2t7MLvJIW84T7wVBz7pvmENP9HXivILeTyNpFjiGUHLgx5TW+AwTbLNKQ9wwThI8JPA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 Tue Jun 30 13:31:09 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11633141 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 E241513B4 for ; Tue, 30 Jun 2020 05:25:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C4FA0207E8 for ; Tue, 30 Jun 2020 05:25:01 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="mK9/EDFq" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729564AbgF3FZA (ORCPT ); Tue, 30 Jun 2020 01:25:00 -0400 Received: from mail-am6eur05on2049.outbound.protection.outlook.com ([40.107.22.49]:6067 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729538AbgF3FY7 (ORCPT ); Tue, 30 Jun 2020 01:24:59 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IC8Lqz1W9RB++eD8fci7n32F7DKAljnGQu1zSt8//RmqFIrbKNIm2an5VqNBbeiNwC48VOG2RHihcKpQTVvPgvL9MQPlU9KebE4ejdNIm9Oc49nZXTDCHGrgP+YWa3UGbaNG9N0Q3h2hNLHsCutsvBT1PMazXOqtpJ/7bpHASfkWNBMuBQb6x3gKj0WAMFXFDCkA9q0snu+4IOieeLGhW7MFXi1TMuwfOtmXdpK5j58qCO+YUn0u95aPv6XPY9euNxIX4Q8NtoYsPz/pTAiDF4IzBIxmP9bLbSWDXlOCp/NUiOL9sbHhB7P+IHdqD5P2BFBM/X24UVx4rrDJ8Bv2kg== 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=MStpk4EPJXtNTPeV6Oa7h4ua/aLJgdJ4RdpWjegnnjs=; b=dfPZLD9uPe91EgQGuJ9DHnhn1JJ5X2kIjLAm0rF3C15HYfR+TJyqrveXyT0BL//7y2k2D8NfQfh73NcWKKRgf4XHDZRSXXGyayecujLJz5K43L1RtMjR7U4tl3gpLfmSrvWGlhURreVP+Aw1VG+r0UrX/n9pay3ivsy1SRSNi7w2YPH3OEFFF86xPb8ayaYCGeUxLwozbJy0jwl6hfx7dxa7JpTFQPpfMm09zJmxp+uG7RxhtMjSDJmrFgAilVodqbymM97DLAf766BiRl9MiqtaulLcHSapkDrQRxz78Lqbu0CTZGL1F6CvrzfDzYjSqTefMmTxcOaQV3JZAGQP2A== 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=MStpk4EPJXtNTPeV6Oa7h4ua/aLJgdJ4RdpWjegnnjs=; b=mK9/EDFqroe+PbUzFkAkPNxPXiKjUhYq5OKkLkx5CT4WN36/EAitKaKrB4e9ytOsANaptYdcMUdax3p7fuwmgGr11HmCw0sHYnDIMlfqrdbqYSLj7c+jhztRIcT9l+tSXQQy6bu0i3fb1gYmaQGlLdxArJ3K9fKmpVcbzoUoeD0= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:24:55 +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.3131.028; Tue, 30 Jun 2020 05:24:55 +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 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 v10 05/12] dmaengine: dma: imx-sdma: add fw_loaded and is_ram_script Date: Tue, 30 Jun 2020 21:31:09 +0800 Message-Id: <1593523876-22387-6-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:24:49 +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: c5afe2f0-209b-4fb3-3f31-08d81cb5ec0f X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:7219; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: SpTuIJK2kzPpHVn/EX48qMH5vFsxzgv7ZoSyQsT5usNnwxQWs6RYour1YAF6zcSvml5Hg883ea/UswJnne6dLPk1LfP9uUlGFariLIKSSO2FroF3zQ8Vc5oFLVmeAQNuzC/R61/qw9rTCILfkhJq5peoJ8t2EDKfRp3zBZvCTMy8/gfnTc8Kw3BiIMyBda+dPFbYRyznbjdsmukq99vb/RoyBuIxEkwgYesWqeDhSYDs5uKaORLLOZQzvhDuk8me8jSam7he0eNsYNC5J7ZHzg/K1CbYiPHryJ0DgMYuxFYz03uhml9eU7Rf4cq/6dMqClrph82C5xmFEi8DHpKxWf+tA+nJAthXKoD+9ME8/oRQ4IFC3oDt2MGeaZS0i4FZ 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(478600001)(316002)(83380400001)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: MHzUkd5E5I5opHL0tS7/LkPeE9qpIn5z1Y3fHBDpzLaYwTYvJ6t0IqHnWW7zTPrJsHVz/HSv/aJf+prz9g3nNCAOp3NRFOVeUBZEdkArr4sq6Gvk2A0LrBvEAtlQwsFjuy7+MMBCFsREfVyn5XApQCe2VkA9kFiZmcWM6GnwfFYJzL2tjh22D2mhzLAsyzPiZ25P4LIPU6KTSlhVbF4RsBTmy3b+J8iIl7OwXmPWALSJG+26Mya8CPdzFsWsSKaU6U3yKIpaiBAaPOac3EwF2+bSB+/tiQiSlSxlo0YAe0ddCoDdAMz57I2ixr1RN3HUR4Chydq2oQteFyTODxw6feKwylFMzYUluKwvkMo9WV/mZGXq42umytpnaLMUM/T/OUo70RWC38ibw0Spn+I4zmvr5UdHtDpv25HGVql3+VvbelepwO73L4EHvn00ryEEvXdxJidSM5H3QZyvU3XaX/lVuLqcMSyTlFYVEBL/R/g= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: c5afe2f0-209b-4fb3-3f31-08d81cb5ec0f X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:24:55.1573 (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: EIV6TWgmqA3XZHpLSt5PZ6Rv0SuWkQwUBzEAoHVbVVuh89DFS1BaTmZucU+zw5n7xRJ6jxNV9/lD1rVqGPMgaQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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..ce1c83e 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_err(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 Tue Jun 30 13:31:10 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11633147 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 CA8B113BD for ; Tue, 30 Jun 2020 05:25:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id B128020722 for ; Tue, 30 Jun 2020 05:25:11 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="dJck81qb" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729633AbgF3FZF (ORCPT ); Tue, 30 Jun 2020 01:25:05 -0400 Received: from mail-eopbgr60088.outbound.protection.outlook.com ([40.107.6.88]:60291 "EHLO EUR04-DB3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729609AbgF3FZE (ORCPT ); Tue, 30 Jun 2020 01:25:04 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=inLlc378h9cfnYUPHGO8pRu8Wk4/bEoMvmd47f4UvuKLbwU2Ia7NFYGZIGcrJPCmpSntzyiovRntlLV1PHGJMpoYe/oWjXTXf8p1B3spMHtn/r62DPrxfi+814lW3xAGpfv5mJgxK4j4KsT7xDCH8N2q6eSwJeB6iwjCkdJtGXYCo66bM8nPXV9lZ9PB8hia7P48htt0bYkeXfMpaW2v1w2/AIgU1+2sP/6fw28l1jwEflD1dCeOBcBh1ptkguI8d+SW5C112lMCus/bHB2knuBc/K6fvEy4sCjNaKQU5OPBvI8sd1Y6aTXFB1oYlYk2sWJqrlt87+F/lSjQs+uZIQ== 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=ET2xDtbbKlaDJICOQJqFSKVvEea+SYs1lteSLtp+Aa4=; b=ZNDsfeLQVlo7te0oA6D8ITtAnTBXgtYffRuKyT7Rz6RgabhjQkvlWFSVlMGfqhvz4Wc0TsUYx2CALe39fGvZ7z84VzUQipIpvdKh4VcScWKWFXrGwxnXneia1epMdtp52+YhPOVPOQoMTtZWgiEwWjwgh93xYlpYgHhn3cECCNzsKMT2L4IUIkpFgb7claK1sLPFlDVFqEZvjdKGIT7C7TCmIOEkWz5W/sOrJZI2Ek2l764rxs54cMcVWFZTP3XaaauiyssGLYk+GMF/0j5l1TJ7y472u+aXvmgWtl4khOm6TWfQwZGAJYq/l/nGPX4ZcRu1wAli6qIn7ZnCjFlC9Q== 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=ET2xDtbbKlaDJICOQJqFSKVvEea+SYs1lteSLtp+Aa4=; b=dJck81qb4Yzew0hSRTmRKShCAlLSw5ikzm2/UuFFmvzGhrSWfw+dbdOZzip7l2owbc+ZXjaW9Hka4r6fHuBTQgvLhVs0cKLU8157U3Bb9TPY7NA6ZDyCX5cEncXqxz2ZBqUtImuhRFX3vWP6sbOyEeVOKhs3Jl9M4m4gnHu7hxA= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:25:01 +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.3131.028; Tue, 30 Jun 2020 05:25:00 +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 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 v10 06/12] dmaengine: imx-sdma: add mcu_2_ecspi script Date: Tue, 30 Jun 2020 21:31:10 +0800 Message-Id: <1593523876-22387-7-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:24:55 +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: f5ced484-eeed-416b-ed56-08d81cb5ef74 X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:361; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: SWmL12QcL6lkt1hn3PMwNejlX0l+CPvmwDk5HLdZjTZs8I5Whyxwyt7V0fv49wEqVkpPdKwYeLGiU5lGpfeNH17CIVPDzl/lGbwiplEcjUWjwl9FdpSztjy9636taMBVgd+ZfHlENzInHtrTXx8n6JaY2kDY5wT6FepsCBo2lTCzc/9RyNdEhZKCQO76CLNEPSGHDc/XyFdj7b2XEsMhUmx5pooc520KPBscxglekOryskt0mKRmRTh0qLORutUOWkcWV1UqgfYWvz3s27Hrn8VR0MGL+a2gnSBXty3AJuEUpuLbcxkTTBQLjwAjenxemBfI4/7WnI5aCA0i/bA2n1zzkMbAqabm/yluCsupZQ4U2WRBsO5HDNytMB5Fg6JS 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(4744005)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(478600001)(316002)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: zQyxg1fWPfQ0QwQpXGA88RWiVyIu3ewUMcYGK75IB9pSbOK9ynaT1+aD0RhbnWp/5oFQPSBq4FbvNeUnK2yHe9kV96qU6TL2NL0cqAjnf9auLU7F7FA959no4JjFhwfFO8XHzN6/0jFVdx9hkxXiU0ufV6Fn2AJqxXts1Nxg9ctkQBaLCLt3EzIwCkZUj+MhXmW09oeXNOeznX61vLojDsDsp1VPZ9lVI2i5WmDj9rfGA7++g7gHeISuV1I37ZFDHTi8cpF7aFD8x3kOUj4eMJjsUKksMKKNkPa+ZzzJohoypglmd/devIMrRjtmPsJOgpJfhrUxMKma28dMaxv5KzEEBe1KectpBB1P+6Mq4seE4yh61iLeVxoCmOAqaOcRUjHv/4u1hWTwDXsRCMj6MY9Vj5B2niLAD6udTofhhyFfMusiL6R8jLNIJd0bK8qMxFAMnYxisYNLIoYjU1t+YbNbQqtlNJeNEFYf/te4S0Q= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: f5ced484-eeed-416b-ed56-08d81cb5ef74 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:25:00.8268 (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: naGkyod4iZs5TMnzzBQ0wiR9R7cwbCuVYFubrgO10k/QAIQvyU1Rx9RwEjfEQrBQze4T4XBvCk0Egm7fb3FhXw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 ce1c83e..337143f 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 Tue Jun 30 13:31:11 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11633149 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 C92D2138C for ; Tue, 30 Jun 2020 05:25:18 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id ACED6207D0 for ; Tue, 30 Jun 2020 05:25:18 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="QytV1BsE" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729716AbgF3FZM (ORCPT ); Tue, 30 Jun 2020 01:25:12 -0400 Received: from mail-am6eur05on2049.outbound.protection.outlook.com ([40.107.22.49]:9761 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729677AbgF3FZK (ORCPT ); Tue, 30 Jun 2020 01:25:10 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Of5Sq+40LBh2/4BUbG22IcGXC8NKgk++u84z7YQGU64TEIEYWXCNytKQnE1wX1zCOXTg3H/aBdYA/Qn1d3Ju3i5/0BBnA4Q/eEXX4YQq+NGXB4W/3UcV2DUjDgDonyCifqy0Inz7/0v20hvQAP59ndtalocajPD1fmUtrtwhKmNwOYpKO2haa2WHlwC3s5p2qD5ZIEb7EdG+0jvVfytV9i4zNP4eMzY1v61fCItioDaLMQpSZLsa+misprwfMPg+L8cYxn1EXPEGeqwvQuIYhCAKLZKERzkbpZDT298Ss7mjbcteObcwm6FOSsgqDhYgJBpROyD8diqlo47LVyahgg== 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=WWNStUA2RAKyjDFWykLikBzNqXz8x4qFoyPlGga9NNLlypl5qs5BFx1kjHfM+TGDzBgHjL/SDlsBL/hZ1mzxQYUjsamFMyDOZpl2VSxKmMVrft5vHhkZMBcoGaufjAQnYF1RFHi0g5ARF0h+iRh4uwWzQLwDIxi8H/s4tnWesGrlmG8U++opjBZ2uoGAMXj6m+bnQaL0JmoPIM4Ncg2QIVu+bweenFTc53jNqdDOBIhR1y6RvjeGOkNwWv3I1ivQpoNnNIWb9lyQtvc6I0sYWdTbovBDwIl21EuYGYEWHqXKCTJg6f3DQyRBwnXDtz81BfFb+lK8jyvebMohkXBV1w== 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=QytV1BsEI29GBoP0vEu0zUsLMRGa5D3oR3kvmywHaBdbS/BIAqfEnV3iGKK+8ktusw14ukgm+J8GIhP7SOmlWdvgfXMiczn+pR6KyvGyoJY4YRMb5pMfhWCpiW3qsjeKtYpWVS/BhJQaW95eeQQy7MEUCdhbSAi2UUbAUP5UpKc= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:25:06 +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.3131.028; Tue, 30 Jun 2020 05:25:06 +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 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 v10 07/12] spi: imx: fix ERR009165 Date: Tue, 30 Jun 2020 21:31:11 +0800 Message-Id: <1593523876-22387-8-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:25:01 +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: 840cd8b7-c5b0-48c9-7339-08d81cb5f2cf X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5236; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: zyTe2g5ijPrA6OQo11BngqhKwidXqdiBq0Ry9C0PxouEbxW8qAFUAMP5/nlr8bggW9x2cqgkRf+if5TnfnmsdNjmMBOsve6fkMO0uo6mynNGxq2Xn7M6fbOR1IuTxyRqfn4Su5tK2AU9/3ksqVDPfsS885TTpNrpK/QBpyu4f//AUZjUlw3RZDvUY/LvjY2XW4BtS2vxuflcJgiG/iCiDq+yillgiHiqGkPMMxC49LjB8kI/J9BBZNNUFmXAP2nAjFtri7uWyvVPq7IOfynMx6ZBEos/4wvU3D3sM+lS5OfCv+cJGhMukLx3CldyujjRTwgJ0Sx8oaZsOskJpwljiGkS3wmiFtoocF2wRJNrUGeTrjGPA9AhQYCnQfQW6gOUvEgOP7bG1wrOPSJLKE199VpcxC0iTNc1EB6Mr8AKXWgBqAk/cMSRrawYvKVTTk/KWBJoZh3w5k/HGnyWYv9FiQ== 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(966005)(478600001)(316002)(83380400001)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: jETdR/b5t+lrSn3urVeDLMtPN5yrJhM6TkCkzyAu3pZYOx5lMttqYnqPZ3ljuoNq6L4+tiRR0dCq2NV6JTCWLh34Zs9O+sfaPXsdr9IEYd/aaTZG7nmKbx7UcTRb+fyFkKRBNQUVHdlDU58KJKLt+t9DLzuVclzR6oSQYCEwBV8TjjIMBy6lkI54WghWaqQt86OHSxeUqevPM68C8p1QCBktZtMo4GIxkBpSdcRK7a7+vTmEES5ASr38BpLtCIufVQJaqX8WAtWqjT52dNhUDr4Bivnwx+a0Z/7y309q2M4GyCk6ZIOxMkHkyTs3yQqJL7v3jUuc7GN/YzQAAWs+PJKEVUMV73ttJflyzP+2bctrutcYi1h15Ip6AsCNEbTkmu4FkF+9Mz1Zfi7aw6eO0E3Nq+sDsl7QP4z61mVPQArWFhuKQGBlto1RbrRgUEZl9vSHgbERfIq+ypuSeVyglFHKRb9D30ysQY8f47kgr08= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 840cd8b7-c5b0-48c9-7339-08d81cb5f2cf X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:25:06.3723 (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: uVG/Q4oBP9u8RegbihvlB4/KcTdIi9D5Vr5N09V8Pc//8NkA/2luUwtuUg+TlNA6DRxEoNFZCgDhNCRZzvnPHA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 Tue Jun 30 13:31:12 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11633153 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 8DFD013B4 for ; Tue, 30 Jun 2020 05:25:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 6C09A20702 for ; Tue, 30 Jun 2020 05:25:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="BLwOXQEr" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729774AbgF3FZU (ORCPT ); Tue, 30 Jun 2020 01:25:20 -0400 Received: from mail-am6eur05on2040.outbound.protection.outlook.com ([40.107.22.40]:63552 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729753AbgF3FZQ (ORCPT ); Tue, 30 Jun 2020 01:25:16 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZzhZHlmQ9+iAR6hD+MqII3ro+5iSahKlE7socZM6V9OWa+raVxhhXbxcSEA/eT7Y7CNpCvxkLvGFQZ9FGw1L6aPoA5lKrQcG4eS28IRZxWJB7fmX2/oqvnQGv6fVAt5wIoWUQZwsSiQ802QzpuvQwzerh0689ljqNC3/Shzp35F/xZ5Osb9HTuV2F5ZaMMhJZz1lTAtVHsNY4IyO+qgdFr9jlK7C2HoC+TWaETO/meqGcyNX6n2CRtg6oEwmFZazP9fuTBdeZzLK+ulbF2/9yp0AfERAsqyVTdkGMZQ//1qxqg1aF0shLB+ziTuop/3UaHtGtXyF+Jqucv9OfFTqtg== 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=gaa7hyo9CibFRsdIYrgo9CdzGj9DVA7jA3lOz7ugCT22NkBo5fL1ATwTyx0MRUoGl8MTk7rDHGu5VFOIUfVkGpY3rIeUQyxChchjKk/RSWftuj4kuCXWmBkqbjJg3kTJZirPKqBCbA8AJR6urPPSZAaafb6cC27iEfW+e9kNWwYNQSfPDDU2H/OlB44R7EfssSNIQ0EOTghE5KlkW+gZ3qV2V6ZVCihzbN3yKVriO9Wl/GckI9dSCQXQE+LxcM4+YJcwjzJ+bZWOPjgnV4pZorULvMxSgSEHq+3kdX7Qbbdj1+h935PST4CUI4PbmOuxwDuYnONZO1KHt4/7eL+ISg== 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=BLwOXQEruW3+Co5qm13DSSb6cm4WPHISm3S7+IezUj2CBc30R2ZJ6Jta210NiK3T1Tx5M0IbQToYmVtX9ciefQuxbvvfDVQ88PkSxrRPLYwR9lt4bjZRtfDDJZ1x/0YCRGHSEDt7vDNEj8u3HETC6ZGXhxZc+GtV1XDkyYSDMAw= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:25:12 +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.3131.028; Tue, 30 Jun 2020 05:25:12 +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 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 v10 08/12] spi: imx: remove ERR009165 workaround on i.mx6ul Date: Tue, 30 Jun 2020 21:31:12 +0800 Message-Id: <1593523876-22387-9-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:25:06 +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: 256c0629-9deb-41e1-bd57-08d81cb5f621 X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:6430; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: lNfJfl0utKGZiHqXiybLHBAA4phJdDpdcJbVNTdX6jtNjjXyV9E42IP7X+V1hz7LtW84jdhFgAV0mYJ4Jz8zSXjoIhO5iCtgjyQwIoZQhbAqShbHXkDUuJTn00MWE01q036jhkmdR7vHUccUYSQMxnS1Ot0V5s6IsLrUmxtZ8jpHE8ir0xjY2XW4Ujw8QYuf96J4Eg7F6KfRzNWStTZJtmAY0XrpL/ACzwoDjy/POzo+BtNpQUcsv7yyWAl3uPT60C7vx4t4EfiDGBEkGSFiV1L5ZewMB0fnw2kEyFksPq1OsAArUOnebGRt1soekVmtZB5JC+hdFu+HlF5E+wVB/nFTaxjTkjw4S9YmJXktWxVG/K5JN4ftD4vYQVHN1AerawzZ+PDA3UrcVWWFfomhrBmqrKuE3kFBv6kW1GE/mCpgFE4qGBgFvfZ3ndebfxPrvpSzA7Mkir2u0QmY4N3DWQ== 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(966005)(478600001)(316002)(83380400001)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: NrhAGK5YQE0/ccKb/6cNrQKFNk6DUTHG4ZWMGVZ4z4adnXXixAd+vM5qSm8NT1+JKwiVsjzA69wNXlSM364/lm0qVZnbdIM1jQOoU6ZQOVdfwfDT1jpYoillkto3oaRR8jf7tR3N8Ii2JhAFLVX1p3vvlMXePRUrkHQnMqXcdthxQr/90MTc6OV5Y9Tvm8eJnklTzbJ1KEXPneymj/NzsgDsTcU6/rmmD433mJatilk42+qTJOcIooynjxyBXe/OJZMmkk1icwilBVTq2es7pjfnBKNCJDCYE/JLJn5oBXEiQlcOLx/G3ZAAYYJ+PSs6s/KA3zFysuVyXfgAuHnezKLddo50q402nEWoDqbiM5GTdJtcqBdn3QmasvNclulfgl2LeiKstyyEg3ifsSvIZuMaWRuR3rTyPu3i7iQLMSbWnzqiXprt+1Rnzova/KV9Lut+T1pjN8/uMMfLSk/PWNPKvt4a1DPOKTU5kKpqoHg= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 256c0629-9deb-41e1-bd57-08d81cb5f621 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:25:11.9258 (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: CbZ84XrAPnZOgwzdj85jwBorzSYf5VY0JFyzRZu9+Qvz1aOsVqeM7B358et2FinA6iBWOic2Y6kn9ItcHIvq5A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 Tue Jun 30 13:31:13 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Gong X-Patchwork-Id: 11633157 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 A936C13B4 for ; Tue, 30 Jun 2020 05:25:27 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8FAE5206CB for ; Tue, 30 Jun 2020 05:25:27 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="aKluv4vO" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729768AbgF3FZ0 (ORCPT ); Tue, 30 Jun 2020 01:25:26 -0400 Received: from mail-am6eur05on2040.outbound.protection.outlook.com ([40.107.22.40]:63552 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729771AbgF3FZ0 (ORCPT ); Tue, 30 Jun 2020 01:25:26 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=dgloDc/kq/Nhgm73zaBMo2C3aQaeAQ6JV+8ejrb6QnGDY40QqTWiOErdPaNe3t1bfwvCZCpeL6TxpM965piJMV6bh1m6ZU0G/JW7aydEds2WfUwf2BXMZX89mdoykQwCoAd1Jbbs9oSo2hYnpEYpBdsESnijBDkDPYs+rh64err6a4YzyyQZgYxv7XIIs+gNL6rKWl98auk0gIpFh8ETLiFT7nS80TzUU0lek/peBCfeWCfM/TJfmMyBlPxwtUprkxHUxDBwoDI2oQRgpjKuCxidlF7oigv1HbCuI91JFB1CRKbFVs59VWotxweYk19MlWEsowZh/sNH5EIE6QRo8w== 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=nkIItSGmeFEDpLhng4zanv8M5F4+vJb5T99swQ+qG+bmvHsukIFsV4xBNXJJTAdHsZn7K4DUhVGzX7mqs3DpAMEVmK38D6dr2UvlE3Vkf+xd2SDCbNKjK/1nLzjKMLu7//D5fuUW4zb0VeP8lMaUh+LjTXFOtZYyY/YBVsrgPdScNVYf1FpT4An6eXuNxPAKA0oU7a7Lk1/R7QFohGaST9qBtz1NUAsJrm0yRhp8/m16ORzh40fspaj2kOPFmkUMF4zlSoNY+HHRBOUSfs05ba6WFnehh3uPlrax6vrkNPFbCunRppuWSWNn+juRqx3HuCs0sPazxeYdf4Qh1n5Wbw== 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=aKluv4vO4GY8xGloBrfADifCbiKC7EVnI/Eg3HnKNDVmITz9aP9xgajbHNv5bSWvj60ke7Tyik7LDNanMxpGwBYiVgysRKI5RORnHe52jcRZWtDUO9kSGhyyZbj5CbdbR6/IdnDrt9Q3ZWH+ZHD3c5xEW/YYK9R7DR71S5oKE5k= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:25: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.3131.028; Tue, 30 Jun 2020 05:25: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 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 v10 09/12] spi: imx: add new i.mx6ul compatible name in binding doc Date: Tue, 30 Jun 2020 21:31:13 +0800 Message-Id: <1593523876-22387-10-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:25:12 +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: fd94ad4e-177f-49c8-6f92-08d81cb5fa41 X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:3276; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: rS71ymX8QOnF1zx6mit8v81MTQJH8rVTVomB+J9DonwiZlUkvlcsq0w3Jd3wHhYrHjtGurcMuAvVDRQIuuocnraiWSOu1tCUMIXb4DDegH6PK9fTBULDE9UxoS2hmusjx9950RjuYS6nbh7br7i6xoq8xhN/AQ/L4AyBWBtOBquzfHNNEo8fKfc+TXsGh6EltVrhVXAKx3nQ753PS9zXxCCOcducsJ+5tCkwSK3EKN5f2F6xGRwP0wNk6bYCOiEWg2THkcURiYaN1ytFEz8BgIfhyqI2Ui+7eWpnndWQpMenHsCF/kI3oU5Vf007+5cVcQ9LItrpv1YHknPM3kDN6u5o47GYvcNJa0q9HZBiNeBjcaJxzoAem1wPYz8vXAEv 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(478600001)(316002)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: bMaIAet3i8cL0cMNpLJGJ9dV0jK0bX1446ylf3q5vTeH0dZWQUqjRlitIrZh+H27cCTQ6PbqAUWHDs8HOkDcbpzMPG2JWa1xQmOVr2FR5GDjeGGggf3K2C7TQIteaSqrh+6hcaGSbRTScx6H1NBUnbvikavOlQ3c/pZsKRRpJLFB9IAKint8AFn1brD83gwxgVn/3ooQcXhfs7ulHPVMnX3I6g1nNogDThxavAJ2eBYisI9BJ21DlxPPRHWozm+LY/GBK8BCw8SxGuXf/G29PwWTvV7PFGtzf6+MGA35rNitxWhGhPkGWe00vT+E/JgGGM2CvMHDq8WIEjCJW5Uthv4xK1wST5e+tkLQlD3FbILcgCTQwtm6u1mHuGaA1aB796WKuwPNbvWvIRNj5eB3Pz33k5Sh7ET3eBWdAVGdE2239AQEhlZzQhWJt6eliuEKq+Nxe5qCaruM4xPQnMyjZMRpSauekfXSsivc3HGeO90= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: fd94ad4e-177f-49c8-6f92-08d81cb5fa41 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:25:18.9583 (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: uUjbvqnqvoamJLLtCgo2Zvy1JsMJNQqZ5/3UUjMp6YJh0DfoTpZ6Kl5u+MEU9Rvg7E4Bj3qJqoHgwYgxUYnJyA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 Tue Jun 30 13:31: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: 11633161 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 A7BAE138C for ; Tue, 30 Jun 2020 05:25:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8090F207F9 for ; Tue, 30 Jun 2020 05:25:32 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="Ewoi0Fj4" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729799AbgF3FZb (ORCPT ); Tue, 30 Jun 2020 01:25:31 -0400 Received: from mail-am6eur05on2040.outbound.protection.outlook.com ([40.107.22.40]:63552 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729753AbgF3FZa (ORCPT ); Tue, 30 Jun 2020 01:25:30 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=TZ/DxqoxGKv64246wZRCpSZZoBvsvKNldZdGOJYA+bR1zrsoF0qWelZ5UpsPxGA3pq7JhgzOPuoR19YeyuePRH6fMT++TtfXXvht6Zww5wnZ1HLEsC+k2ls0B8xxLrMWRSJRJv1sFRaiDgDSCbv6SaPT3KYqQhpsojihUipDDJgxs1hw4EoBvg4MK8Q6LcGRPSCWa6lzm+lQh+QBULdmNDyYvgjdP0wdozfqrc+M4Y/JEVOmVUej3qUFcP0B3308I5b3BZSs7mdkw0jY3+bOsvz6m/wqdlz70wU0C/NitN92/lVvDOehY75SB2VErBS3Br+gQWf3Pdy5vncIEgJmmg== 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=gPvhGd9cKIQVy20dHzs7vXDHIb1HIKaMjLjlAe3QYgc=; b=ZP11bQTJf9Q250ClcyExZh01NDZobBQshskyJSl5PWhb+20W1pjfFdDTuqzDnr5B5rciPQasCElKRaNAKMzpkXm8Wryq5bvc96AFz5C9hXBtXSUQ2LkmOW4xCczohIokCyxc2jv5uefk5v24FjFzSFtsPqcYqYxgBPMhymfVxHEmYJ2xzXETFY3r4n+e6YIi3xXv+0iP6R0qykEJHCFm6Sh7wHTvrm9NOg+h8YAa8lRueVX0V8sDtMgClc+wNRbOa4/YRbO/3k38/R9AlLF5wwdsDRr6IDROISRuLBbjTbNZ7uakWZGqj7iKbYh7vzisufGXCJ0iSnNV5wD1ZxsgaA== 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=gPvhGd9cKIQVy20dHzs7vXDHIb1HIKaMjLjlAe3QYgc=; b=Ewoi0Fj4QjiHKRDGjO7rozowhYkwWLOBOqy+HT+Jse4tUbuxgY8dVBtacboz01CqcgWlZroTJlWBRLQS0C57p0g9gs5MmuWdUDXzX/Nmsf3mEcQexvUYaeg/lVSg8cXQcGIpS4S8NtalUxD/qfLPfYHCej+C01hOj1v0w8WTCvE= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:25:24 +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.3131.028; Tue, 30 Jun 2020 05:25:24 +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 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 v10 10/12] dmaengine: imx-sdma: remove ERR009165 on i.mx6ul Date: Tue, 30 Jun 2020 21:31:14 +0800 Message-Id: <1593523876-22387-11-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:25:19 +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: d6f3b00f-6315-4b26-0fc7-08d81cb5fda2 X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8273; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: vzrTI+Mja6j5haNHrLKkU8T9S1qZrNXgrqzozv70xKjCXiKiev/QqENr50V+1Cppawcm1EuODIXUAciewRVwXWggh/BhMGy0cI63iwh4w8/4KJvet2jlK0lNPvJ7ITmVfVsriwZmtr+BIcSmneM2nDLiItC0KQ5KpRFSlKaaYGbedcxyKkqSbTZrsxWneiBfIzzFY+cWT3kD1/tLZypKm48Iut7oR6CPo7bv+hcL63VY6Jg7tRePHp1kJJC3XwTL9LS9Bl3gGRf2HTF59PwXxWrsRucWWMGlA2Zo9+vXPn/fxz3qr7eoGEP9a3J71nzJr0lfMr+UwOo3dTZ/97cfHGUL9jBk/bBCeAJs9TM8qT2ao6W1NTsuZqaQZb94/DUjzFn7J5+5UZIiQSHnx60HX3WlOCKhft9IPRyQ+dJkEqN7y2QAjWh7ga7qjmqhVfuu 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(966005)(478600001)(316002)(83380400001)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: 7W6tiC7BbgmpvRp38OfEKoDdjvkDONM61eEqHCU1ZaQHm6G75RZCbDU2dnrLUx04TARkbZdEHLVUVIXzP/fJesO8ZbJiI0acFpw4B7Hax1bRqbPAG7PB4MBEGrVtKDKViaslU1PKJBtY0SSHIpy2V/IaxXUnPRVEMagZh6QCeTdsaZ4N5OS9RE4xCMuQJtE2zQmY+whHYpQhp1eTdSInJoGsgxfC4PbX8CzVhm9M+EyMcbrskiWiE2Cn8dehzTA373QXExe5GmV/8oNKYiBIHzDWMwa/qYQlraicIPqHBZaL9Ufl1wEGoCBL/UUEOgJ4UuL1eAvVi8NaiU3vWa0O1Qp83GI1OGfN58C1y8dvV01rGj7/xfJJJ9qqESt1rVRXLfPAYGDSWM8yErs+zbGYuZpaTWkQHwjgTYJYSROsHoyRBydc8qCTTwxloaz+CPAgSLLvadKzHMFFfDU3vR/Lc51JAcvdWiZDw/ncb04YdAg= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: d6f3b00f-6315-4b26-0fc7-08d81cb5fda2 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:25:24.5128 (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: dDYSvRfRgWjWd8X06f8uw33zX1FcZoouCE+6mPKRph20NgMKSW7FXYerkSyxtvTGRaG6pJbhWZA76qTQliRPrg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 337143f..3058c78 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 Tue Jun 30 13:31: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: 11633167 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 D16B413B4 for ; Tue, 30 Jun 2020 05:25:40 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id AED78206E2 for ; Tue, 30 Jun 2020 05:25:40 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="JEO2UxQE" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729753AbgF3FZf (ORCPT ); Tue, 30 Jun 2020 01:25:35 -0400 Received: from mail-am6eur05on2040.outbound.protection.outlook.com ([40.107.22.40]:63552 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728232AbgF3FZd (ORCPT ); Tue, 30 Jun 2020 01:25:33 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Nh4VfNVDH6cj47CrwOETcrKGuOJEdxecRURp/EW5ZDEQKuwRt1qkXWnPGsUhCLt508GJBAGX1qtTfetQz0jQBX7BA1vSb+0aMN3EUBNEroIoSV0PRfPiY7M04Ptmv5dzNCwAp0J+Q+LPDhLgd5oj5tTf+Xq9vgJ7Lv5gc6pJSkRLBguRwceRktimad0Iyup0hpjg25UwoLlxVqv0GqOGqG3lU35hpLkEwZ85X+i41E2k1nF7LGq/ITXS0Qvhx4fOWNYxudDEou/IMG3Gi6xhaudNnj6SG30AldYPwOs+IE24yEWbf4v6NUpFcdub0kmNzzofiWNtdL7CxBarWYb4yQ== 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=Y/Yv5DWfu6vDHa5fd1LGnCgJdMrFXlYO+UA/ZjM17PSQd1xEEGEz1PEOIslCFosOtUDpgrAQlG838I1gWkUtnXEyrhYGT2pdHmJNJEwGuMdMIje1OTCmS8OPlI3TFsHhhbe/8H3bDjZAZmZ2CjQWdM3vApU5mEZbpJW3VC3aLMyEJdeF4Tb1f5tzpfMGnDPuo+hqVPi77MuOuLz/vPoM9VTRvnr32f1bPGnUvYBLl+W2Ih/XmbiVYWta1x4B5JbD66R/2KqR5vkiWd+grQCgbsbyrrnSZWjF89phzUN/koYaYCaHzTT26yEe2bSzgP4RI1+Xdxa5l57CVpdQ8E1E8w== 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=JEO2UxQECnJG10kdZVoFHI5t5em8Fodb+wGgkdA8lPImMGfkrTbnH0y7+OchNbBFPffjTyUwVybGA/oZk8zD+U+xRE2RrLoF/aL+KtW4DbdiGkxbNLg67Pyp8uRfgA6yRuPjBZHrK2zfY6slSkYww7IFhmm0OrOf3F+V7f6/9qA= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:25:30 +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.3131.028; Tue, 30 Jun 2020 05:25:30 +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 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 v10 11/12] dma: imx-sdma: add i.mx6ul compatible name Date: Tue, 30 Jun 2020 21:31:15 +0800 Message-Id: <1593523876-22387-12-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:25:24 +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: 9c8c5074-2364-42b6-412f-08d81cb600ee X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:632; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: cy7o8BJ8Dt9vPt50iqpYin06ZuhcVtAZOImSa8O4tVXX/voBRPdqtX/vf2B6dH1nxlYU39T0pL1KLNjaHZEGzjG8cFh345aDyrlGmsP16rc41d6njKlWlH8kHgbV61Sz/da/vqthURA9i5U4EzdVm63WnO0PPxNVuHkT/yJKoJXw4iYrXIE9vKQcSGTZp/7PZaA05sQQub/cmFc2r3/iorX3sKma6mGMGnUwAsYZK5AaXEXaB+GXfXw3FNML2D/RKxY5KzitWQz8BiQDRob7vbhn7kBxB0e7+YyUuxcifCiD6LU/vI5TcQFm91Mk1dNcKhSIIrNM5j77nsxnGYBLe7hooi7hZKjPVw8R0aHnTEU= 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(4744005)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(478600001)(316002)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: lkaRUIEjyN+NIPv8GJstx8h/Av70SMu7oI0CGC9iRfO9gC2NUlYRF47VhnZTf97Qv6zxZoY1AukxYju5Q1B/DqrDqjZovrXaVosFS4aMYQWZbHLuzRvxquU1AY9opCfc2qnpyeVwoCqLQ4g+zw11dwCIO4UkPHAwx5sxKbWoDWvlXw/gv3ywGe3l4Lzms9Aon9CllusuDV6vtQRdK5P6q6OkTB/ImMkeETzLc+HOok0BgudDvqGfr3c+gc1ANBbc/lnr+14LsPa74XtLeyv7rOPGNi55Hg6HDJZR0CmMHp4kZrawmx52Pzk2somdK0fYNscLFrXxDpXuKlTJS3/QNG0DSBBsvuwIwkznWYMoVI4FZiuh1gcWmuToTN5xsva5vTU5yZex6+SyAW33ybPsVX29XprH9MveQkwl8tqi2sK706IXByHsJ0TAc6jZVsEs0ivn+p7GoTXs3ttBm0LHmxxFpM0W6SUIltr1YiozqA4= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9c8c5074-2364-42b6-412f-08d81cb600ee X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:25:30.1642 (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: AdQO2ZXve7Yn7lX38UrKB53cTHHrHEcyQ4AYNNjNciAEh+6WYw884r2wXrjqTn8E6qSZXEfsMfEsdpPvlOh1lg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 Tue Jun 30 13:31: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: 11633169 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 1EBF613B4 for ; Tue, 30 Jun 2020 05:25:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id EFCCF206CB for ; Tue, 30 Jun 2020 05:25:42 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="kOVdD9vs" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729835AbgF3FZm (ORCPT ); Tue, 30 Jun 2020 01:25:42 -0400 Received: from mail-am6eur05on2049.outbound.protection.outlook.com ([40.107.22.49]:6022 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729832AbgF3FZk (ORCPT ); Tue, 30 Jun 2020 01:25:40 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=gV+EHo0JENEuABxZ6g7bRCux86lgnX4btI140X3usOZp3g98fnBiOCXodpmAh8rzam1PPj7ziI9/PY3U5ma0rqDukcTaZYZolt8CNSXA2W0hp2CnfrD0+SGXXouBs0LhYJp/65dQtw/S5icZ8wYH+QAPGNu1Bu/Xmtfk8KzAjh/FSi5Rm04WlT3cb7g+4LuxIQi+F4YznoDfBczxMCD5AJE0HBxw8XAARfjHoV8wRzNiRAutF936MMkq77XojaEP3Vmy+ECoGy2q052DeWznglBO/1VwbUAjEOf4DkUMXtPsvCoMmtJofzSQIE8t4TYB6yswcGB4tDMx8GpZdyWzng== 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=nwRHmQ4mQ9Ssi/XHtHwbkLAPrzpFChC9/nuv3wVGWus=; b=f/OwWJrYgydUP2XZSxw6BX3iNNvUlmoyzDBjbUVG4rmmtIb1Os/7OAULOwz7ijljMc5hF2Id7VkimdH13qUpNcb/ETHBb7Z+IT7RhBRBu/LjaI7Lcdpq+Q9LSkUr6QxoLx92nKMssxKf0gvsxtLr4c3dv9Q4+BSmrrk/Kjwi+DmYk38F0kbEACoKDruXGnU5lXReTd6kJsEO77ur3WLqMlsCojm3lF1aODCq/nnsZTZO0M8HD8B/oRVs/m3qSArBHjhY1Xl4S28SwUoZiXNTKosF15oZ5oKsxNc4dDbIG0ssdPASwgwZALQ5BLlg4J2O/fuRd63lwLmMx5F2rU/49w== 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=nwRHmQ4mQ9Ssi/XHtHwbkLAPrzpFChC9/nuv3wVGWus=; b=kOVdD9vsimmwFLWtDn0jmGcgHGqcfwheQjffTMbGCZMiHyJe+7t4T4ljrd4NcMVcYUQqv7Zni5++jNJxTozpVAnofZjk47HwljeGIvKjqD+eb82506UEikje1fvVLL7JCO0ba+mCqlJdyiSx62ZlRqUe7YmjxPP2MJw3bcxthDU= 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 VE1PR04MB6640.eurprd04.prod.outlook.com (2603:10a6:803:122::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3131.26; Tue, 30 Jun 2020 05:25:35 +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.3131.028; Tue, 30 Jun 2020 05:25:35 +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 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 v10 12/12] dmaengine: imx-sdma: add uart rom script Date: Tue, 30 Jun 2020 21:31:16 +0800 Message-Id: <1593523876-22387-13-git-send-email-yibin.gong@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> References: <1593523876-22387-1-git-send-email-yibin.gong@nxp.com> X-ClientProxiedBy: SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::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 SG2PR06CA0132.apcprd06.prod.outlook.com (2603:1096:1:1d::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3131.21 via Frontend Transport; Tue, 30 Jun 2020 05:25:30 +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: e553974c-fe53-4c61-a08c-08d81cb60451 X-MS-TrafficTypeDiagnostic: VE1PR04MB6640: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5236; X-Forefront-PRVS: 0450A714CB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: i8UQB+H8rZHZnN/OBJN42KlVGhy5NtClfdZ/kta8inaH5HYP5WGJUnnaG8TNkA2Uq7VCEClbI06Y/eqns/42YasoBKrCb6iLpACXeH2PXy8Gpm5Zav+pQvya2LUMPZCp1ZBsGomxsxJBitcYMg9hESd7n4EXiVxXrbiglG0C7pDsgVky/AV/3KMOz69Q9sM6mUN9DCY5QSJ3aa5Fl/xrCcaFYTxmgEUPAW7LEO6R9MObiv/K15mrscw2ynebav157oGQwiWmHMlwPBMUk+QXP6Sx7Zumf8w0MrgnwQfKXaSNOFT+Dq5W4tBvwja0JyIwikDlQk3gQ2HFw7OSwZzpLY/ff4BxNTCCSHqUg9OUJHVJdPbjBUDzmnU12sROeYu/ZsZWx+A2z0Rtfj+ZbpeIG+xPT8DEjLdkZjBKPDkVnb8/GPbVR57LE1Ih1VC0Gfp9 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)(346002)(136003)(39860400002)(366004)(396003)(86362001)(956004)(6666004)(2616005)(52116002)(7416002)(4326008)(6506007)(6486002)(2906002)(5660300002)(186003)(26005)(36756003)(16526019)(8676002)(966005)(478600001)(316002)(83380400001)(66946007)(66476007)(6512007)(8936002)(66556008)(921003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: nJfpPgNA6DMoeL0GGi82qHQSoF+O3XPTEdnpCE/chW3MLG2u0rC5473FnvTfgG+bgmPx/cDm00uX8w/3FpsaTK0SOMSD7PioOMAd60AmobCwQ5Tj3P/iJi1mrREHWmwxeUqqiO0PDaHhXs9sYwsyhKziXa1CybouXRYsm/z8phbFsNDFBMT7W7NgjfcNu6840RRgxNCdEWQikBkvMBJFpzKZli5vYopEwJFtxBoNy4AfA+U8StfwpDBZXtRWr2iA+Ec63LmrqnYvJotFMZKkBq21WddsVBIKWOtc6julEImhaDx4gEfFYJqCL5amnDdLlR3k9Yo3gz4GL/SSt6IHvUOg1RMEVdf2y5ZUB51aY/i6wsuZam4PK3t4/uoOnNRHiA/fGT3R7VTiHEJtO07fZ02zmBIQokMLvGMN55Gqqa6X42ZOIXy7VYZTHyaPblchnVbKrfdlSEfuB589X18CCbnJhG44qLZAw6NCd7fbwzE= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: e553974c-fe53-4c61-a08c-08d81cb60451 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jun 2020 05:25:35.7037 (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: euCy1t98rRqtiF5f/n9UiS32eZmFiciWHJbdz/5hiJuFWRuLlge2VWC6b6X43NSg3twWrZvQ6UtWqeY6IswFGw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6640 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 3058c78..e946271 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 */