Message ID | 20221102112451.128110-1-peng.fan@oss.nxp.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp3563411wru; Wed, 2 Nov 2022 04:35:03 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7EnLAUG6D6OECrtXpoQ0rS7oiTBNAykUTEs7b/3uUiPlH+MYDbwm6K8jOMIH6bf4RChBpC X-Received: by 2002:a17:902:720a:b0:181:150c:fcc4 with SMTP id ba10-20020a170902720a00b00181150cfcc4mr24851047plb.109.1667388903089; Wed, 02 Nov 2022 04:35:03 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1667388903; cv=pass; d=google.com; s=arc-20160816; b=dd2gL6MvffPohxQj9PmyviE4VEZZe/kRwwgQsjTwpyWyiP+xVsLYU9pK3jUznFkewi 1VQTDlOs99mnrZSpEGYm79201s4mtWou5jueC/Xba2iZV41xidBH4lk7Ytgu4W7nla2b 7Cj11sAJ9/7fDQ98dxU/64ISwgM21DKO949xZfg3Ks0sJmysDzBEhHRAUHXLnBMsnAjf /OlhTV+Gao1kdG5xqX6FUdZ5xwNh+jRcb2e4ge7tEAPnHP5zNolNUMQsrtLrsqkke5xQ 8+wW8h1fKGkUGp9ZbioIC2i0ZYVxmnPF9Shm/OvB1/COfKWSjDQpMtH7DXIf7ajD4Gc8 wExA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :message-id:date:subject:cc:to:from:dkim-signature; bh=SWlNtzCdAWVrYve5om23lHn1xZc4+/XdLwo3T4eWn10=; b=Dt85BzBxfIIBB4Pk0QkAqL/yfxshRhTaLlKo4b5FTNzWJnQeqmZEQStDqGP6HXzhtZ eHnQQH3NiOvQCcePjZMnHSRs4dTFpWgbcipjgyjsSrya0FGIagVcsLCoCeV7y5hEfArc f3KOxezodVrbPVWlHyr+pbKNF2ZNwg58kIkScyezvWneeVHzs9gVQcU9S7/MzG5omQ8w ZfnfwKtLd9mTa4k8Ch/Q+wEbeKU8KZ9d8Wf1miaybO8Klo7aeSVwA+TM8zYaMmOEnEQB uLllBOcgmIR6W03sCYmiWYOc6O3MxEScqtmOOTgw7mcfwnKK0cI6NrbIaAia2z/IYt1g D1uA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=cHzNW6a8; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q17-20020a170902789100b00186e5ede745si14238273pll.89.2022.11.02.04.34.49; Wed, 02 Nov 2022 04:35:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=cHzNW6a8; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230480AbiKBLXb (ORCPT <rfc822;billy.jones8454@gmail.com> + 99 others); Wed, 2 Nov 2022 07:23:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57162 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229700AbiKBLXa (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 2 Nov 2022 07:23:30 -0400 Received: from EUR03-AM7-obe.outbound.protection.outlook.com (mail-am7eur03on2072.outbound.protection.outlook.com [40.107.105.72]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 79797D2EC; Wed, 2 Nov 2022 04:23:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hb8F+opIUe77kPNzDU7DZrdZASMvFjj4DKzY9Sc6MQj9EdOVHnx4CVxzFcbocjW33DeAkrlCprFA0NSl2nDQEr38TaRL0ayBuicVBJ2zg2lRN56QxLmfhjMgx+0ezpN/DLROBXeCZ/ybcXZdh11qVk1x2HhdUUp6mpXUR/0ik2YN2QXcD56VDYcsZt6+kDiT6b2ozM6lHIhdmnYgcvxDKvzscYcyR9U6doIjQiv3bdU297FasDeA5CQWFatcq3+QZNgbQmkHj/hfTkMk3qKW8xCL7baXkw7Ghc8zXfabFfEz+TXuiBZw7V4/dDRLWb7v6QDS+pV9LMfzrheaQVPrjg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=SWlNtzCdAWVrYve5om23lHn1xZc4+/XdLwo3T4eWn10=; b=JxnwUVrq5IrdR7+w151RXDuMC6wnndj/ieeMZFdta9auEm9yg1a8UhYFpVZGIcFVSdSBO6b2Y/VrVdXkn9fnxmqWXB/PH9ufvOXoD2DouGQmhATSxwGLEtshoxSFKvWQ+NXGB+x8TkgPayL2DLmGyaljq+5ubQXEar53wrAXNh2Fuiza4vG/brIgglZgK4Zsz+++JQNnPqJzt8iV9dx0LI7Mp5mI1x4kZaNwOvOziWKZZ76f2mhaHLw2dfLIsXeTP8Vi8ouapV1NgzJ21EcEJFZO0DHdp2OFqSa3IfAnWRsIujF2QCfkHW1X88rpviYt/OZMWxvf6t5UUrXdyRGFJw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector2-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=SWlNtzCdAWVrYve5om23lHn1xZc4+/XdLwo3T4eWn10=; b=cHzNW6a8JoDYpaOPtjRh0G0krV9rcfvIJZ0Wdd5UpoaVO4WUMx2O9B0y1jr0f9gFI6UFtj8upIOS1C4CX1FHQJNKsynevFL6Pu+eWbynl7860kwG6flb7nRLU/0Ck8taUZ1YCxDm5R+ttP1YX7f7Wh0P5TiPyyu8NVu66pCWJAg= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=oss.nxp.com; Received: from DU0PR04MB9417.eurprd04.prod.outlook.com (2603:10a6:10:358::11) by AS8PR04MB8344.eurprd04.prod.outlook.com (2603:10a6:20b:3b3::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5769.14; Wed, 2 Nov 2022 11:23:22 +0000 Received: from DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::36a4:e1fc:67a2:c701]) by DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::36a4:e1fc:67a2:c701%7]) with mapi id 15.20.5791.020; Wed, 2 Nov 2022 11:23:22 +0000 From: "Peng Fan (OSS)" <peng.fan@oss.nxp.com> To: andersson@kernel.org, mathieu.poirier@linaro.org, shawnguo@kernel.org, s.hauer@pengutronix.de, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, linux-remoteproc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Peng Fan <peng.fan@nxp.com> Subject: [PATCH V2 0/2] remoteproc: imx: add start up delay Date: Wed, 2 Nov 2022 19:24:49 +0800 Message-Id: <20221102112451.128110-1-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.37.1 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SI2PR06CA0003.apcprd06.prod.outlook.com (2603:1096:4:186::14) To DU0PR04MB9417.eurprd04.prod.outlook.com (2603:10a6:10:358::11) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DU0PR04MB9417:EE_|AS8PR04MB8344:EE_ X-MS-Office365-Filtering-Correlation-Id: bdabf21b-d6aa-47a2-77f1-08dabcc4a667 X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 9HsNYV5saarPMZsZVFKcz/SVlfeiToF0WFH0Gi0LS4XTiX+YjsAp9DWW1b457sJnROlmxY9GXv09TieTmujA/6tiZXOVJK1+6HJRMHzjzMzNx8d0Ircbw/m2X+xyhYDGybWZDx7QtMiA75GoK4uRhcqNgSLSSGBH3FmUachsLmKFqUE4FImwv3W9bghRAd8LtT/1X8G7i0ftGp2vKeGHvbeobDHACfCmONzCIxiVIC+0PQLn8prITtBVizexsYteaYqh2hq+EUC77f1jZ3XB4XB9Q4GR947UGbSiFOfX0Cw0q9GRZi3HIUYnb/dDWO4xHJhci2+eRagdy41Lls/RbWujgHpTXwtQgsuDua3EEFMx/9YfY6zTsFsDymfqxBnmOEesP3dWxYauV4um6Fem5K/XYu+uIdJRzCNnBHf11y73NEVOdfSWl2pySTq4VvmpPcDa/azcLESX2vzjyiZbGisdExxiO3SnTUH5Co0hyju8G6bf1MH7xhzmg24j8oKs+wP+mLr9TcgroTQgDRbsvrmM7+4eoCDuXDJ/C4Fy51omczEqsBbzqP07jLuVVcHjCWrOHMfpDQQc2jFXNy8sDETzc8KpywZyZYpPNOOb8RI54Zs2ApR2UeyQ7DoBReLRupPCMCoDgBsnucNhpbqJ7YMgykOyxI6f/Jw/iHcpsJ1+T4/aHWHAJ59KB9SD63VYpveAGDfU9Im3F5AeT3EiOxpgbS4xmyQsD47lArW215QEohk90HjzWIaHF/obclar/x4WPxA6PqvmSe4dlldny0gTXc3qkWFZqGUBkx0urxQ= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DU0PR04MB9417.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(4636009)(366004)(39860400002)(376002)(396003)(136003)(346002)(451199015)(6666004)(5660300002)(316002)(2616005)(6512007)(86362001)(66946007)(1076003)(66556008)(2906002)(7416002)(83380400001)(8676002)(66476007)(6506007)(4326008)(26005)(41300700001)(8936002)(186003)(966005)(6486002)(478600001)(38350700002)(38100700002)(52116002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 3ScyI8QBEg3UOWlvcfna6xXN6zJj7zQN6OfYM4M/ICQP2pCSqrGru21qDPVDfPTO+X8L+6UmsF6Z6lOIzNSTd9Puv1xkYxTZx0E6UyUK32eE19M8UvNuPrRN4YOPY3efQ84dlB8jD5WvGjbpLqWi9Hh3MdBT3qez1fVJejxkvmDsJosx6AaMvWoYLkMFA+Csk3c/nin41hjaOsp7GmwSKHEJiMXBOKFNLpiIWAV30Yn1f/i7leo5cUvUOXmCcVAsy1kmRlmE862gNsoTYxgvDCr+1vUyRVLdpmxDIAk0tC48pAMzKwoGitTIRMQaI7xosU/XVdfdBfGP4/QTw+vllxCg2mw4G/Btjt+o1TmjFWe59SCnFEfkBmfF4CFpOoPhcHh4lDyQ4rssQQPRjfeV8uJ271js1ZqFhH+dEWX5Y/zlL9Eq+TcTEYjMrKgJVV8JON3caMY13gAiij5vXbyM0aq86RsYomMjQ4W8x1YiLAZFYfAyLmBl69mdeDYGwcAi7p65Z3S/xtTlnI7L0xPNZpFeag5aC6z08+N1ZyI9rm4Ep6/T7JlzdiXZ4uFuZmlUUxhy4TFv4QwrHV+LBcShn3q7Y7LGyHVh+uw/sUqVvnjRQh4XuvEJYLXJwlcMXJ8ejwoxLfGa2cEmTb76UtWbeEjCkYPTF1+jGAaJqL5VKGsS9BlDUfnol+yGF0sKeVb2V6PKe7aYcLZ7MEavpyKPflLAIsZIbFUATkTs0CV9sdC030xHiE8PpmNNI1aDHLL+DLWBMopLe0OIsLBo410qiFmG+YHGf6Y/QKtYN5JQZhZ0KRCfNt1RXqfWbG4njdclK1jRchtYxENStqyTu5WcqIYSvm9+y3l+3U6ftCRyMQa8bdyqAIJrk0AZF8X+kcZt3lsQe5A3ftljYEaemzIUOxH/HrCDY+AH22hgzXH4qQr9q1IVFe7GWaG3q1YaLDn4d4t36ePfUgwj+yiyzIhPsd7GAZ4qRkT4JaZbsZZPVo2S8ZKSWIACNcAxHP3y6pEnLYMsIeihkS240yHbmN5p50R5pxfsXx7qg8LH4BfY+2rfRwOUW+8w9KNr7GjvSC/j2AXqg0zxTicYeIVa7xNkqLdZAthTzB8PC2yqH8lae+tcwJLTnslO2T4ANxtc4p2e2xvDgrbZTTRMjQaw8VXGUEgN0ppE2GBmw3RTtkIznSGVArWaK1GPD77UkX1GfsMiYvmDbwrPiaHApsfu0g1HW4O/vBf+4b+bt2+6OHhCyFYqzY7ImI37GXp8/9XEB6BdxgemK66MCwRBkQ6s/MV2tojiPVAPWp2GLVJlauounPvLyq9b494PMH3TwYw3D1EgCQshn8XZPzyVMIbcfdkfNrpXp57gVjgVlDxcOdN8sg5snnaAr67qLprTFaZ5aS3ML9Wl0KuuCCu8a+ArBT6nQasJIvQnqIF3pTcwf/7YG9lhzuXO1nGKonGO/TXQK88BMzpwJ6IR9Jgl6Mk3YYtESlaiPl41IyB+JPVEugtroDlJLIzGdyunY3mM8q2VuxQTHOCobz+15R7ZlWEzWvhzJB48nfparZjPlkkjD76fJr1vrvH0xqtSYoYRZZW7E7/H X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: bdabf21b-d6aa-47a2-77f1-08dabcc4a667 X-MS-Exchange-CrossTenant-AuthSource: DU0PR04MB9417.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Nov 2022 11:23:22.1350 (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: oNOmHgJW5b4VFc43Dk3SoIldO/FPj3Dru0AiSTTixfgIRv9PB+/8Sku5liktrDHd2rA68GFyLUp4hyclizcreg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR04MB8344 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1748383986444844830?= X-GMAIL-MSGID: =?utf-8?q?1748383986444844830?= |
Series |
remoteproc: imx: add start up delay
|
|
Message
Peng Fan (OSS)
Nov. 2, 2022, 11:24 a.m. UTC
From: Peng Fan <peng.fan@nxp.com>
V2:
Rebased on linux-next
V1:
https://lore.kernel.org/lkml/20220609123500.3492475-1-peng.fan@oss.nxp.com/
There is case that after remoteproc start remote processor[M4], the M4
runs slow and before M4 finish its own rpmsg framework initialization,
linux sends out vring kick message, then M4 firmware drops the kick
message. Some NXP released Cortex-M[x] images has such limitation that
it requires linux sends out vring kick message after M4 firmware finish
its rpmsg framework initialization.
The best case is to use a method to let M4 notify Linux that M4 has
finished initialization, but we could not patch released firmware,
then update driver to detect notification.
So add delay before linux send out vring kick message. It is not good to
use a fixed time delay in driver, so I choose to get that from device
tree.
Peng Fan (2):
dt-bindings: remoteproc: imx_rproc: add fsl,startup-delay-ms
remoteproc: imx_rproc: delay after kick remote processor
.../devicetree/bindings/remoteproc/fsl,imx-rproc.yaml | 4 ++++
drivers/remoteproc/imx_rproc.c | 9 +++++++++
2 files changed, 13 insertions(+)
Comments
On Wed, 2 Nov 2022 at 05:23, Peng Fan (OSS) <peng.fan@oss.nxp.com> wrote: > > From: Peng Fan <peng.fan@nxp.com> > > V2: > Rebased on linux-next > > V1: > https://lore.kernel.org/lkml/20220609123500.3492475-1-peng.fan@oss.nxp.com/ > > There is case that after remoteproc start remote processor[M4], the M4 > runs slow and before M4 finish its own rpmsg framework initialization, > linux sends out vring kick message, then M4 firmware drops the kick > message. Some NXP released Cortex-M[x] images has such limitation that > it requires linux sends out vring kick message after M4 firmware finish > its rpmsg framework initialization. > > The best case is to use a method to let M4 notify Linux that M4 has > finished initialization, but we could not patch released firmware, > then update driver to detect notification. > > So add delay before linux send out vring kick message. It is not good to > use a fixed time delay in driver, so I choose to get that from device > tree. > From where I stand this is a hack to hide the lack of motivation to enact the real solution that is outlined above. I also wonder how these problems were not caught during the testing phase. Either find a way to upgrade your firmware or keep this in your internal tree. > Peng Fan (2): > dt-bindings: remoteproc: imx_rproc: add fsl,startup-delay-ms > remoteproc: imx_rproc: delay after kick remote processor > > .../devicetree/bindings/remoteproc/fsl,imx-rproc.yaml | 4 ++++ > drivers/remoteproc/imx_rproc.c | 9 +++++++++ > 2 files changed, 13 insertions(+) > > -- > 2.37.1 >
> Subject: Re: [PATCH V2 0/2] remoteproc: imx: add start up delay > > On Wed, 2 Nov 2022 at 05:23, Peng Fan (OSS) <peng.fan@oss.nxp.com> > wrote: > > > > From: Peng Fan <peng.fan@nxp.com> > > > > V2: > > Rebased on linux-next > > > > V1: > > > > > https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flore > > .kernel.org%2Flkml%2F20220609123500.3492475-1- > peng.fan%40oss.nxp.com%2 > > > F&data=05%7C01%7Cpeng.fan%40nxp.com%7Cf14584bdef9349e744ca > 08dabcf7 > > > e1be%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C0%7C63803007007 > 2451509%7 > > > CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJ > BTiI6Ik1 > > > haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=Ck73gkOPpNVT > kcZL8olCZP8B > > %2BrIpZHV48uZBl2R8HdM%3D&reserved=0 > > > > There is case that after remoteproc start remote processor[M4], the M4 > > runs slow and before M4 finish its own rpmsg framework initialization, > > linux sends out vring kick message, then M4 firmware drops the kick > > message. Some NXP released Cortex-M[x] images has such limitation that > > it requires linux sends out vring kick message after M4 firmware > > finish its rpmsg framework initialization. > > > > The best case is to use a method to let M4 notify Linux that M4 has > > finished initialization, but we could not patch released firmware, > > then update driver to detect notification. > > > > So add delay before linux send out vring kick message. It is not good > > to use a fixed time delay in driver, so I choose to get that from > > device tree. > > > > From where I stand this is a hack to hide the lack of motivation to enact the > real solution that is outlined above. I also wonder how these problems > were not caught during the testing phase. Either find a way to upgrade your > firmware or keep this in your internal tree. In the beginning, i.mx not migrated to use remoteproc, i.MX release only support uboot kick Cortex-M core and use downstream imx_rpmsg driver to communicate with remote core. There is no runtime stop/start. After migrated to remoteproc, we do see some issue, but old firmware was there. Thanks, Peng. > > > Peng Fan (2): > > dt-bindings: remoteproc: imx_rproc: add fsl,startup-delay-ms > > remoteproc: imx_rproc: delay after kick remote processor > > > > .../devicetree/bindings/remoteproc/fsl,imx-rproc.yaml | 4 ++++ > > drivers/remoteproc/imx_rproc.c | 9 +++++++++ > > 2 files changed, 13 insertions(+) > > > > -- > > 2.37.1 > >
On Thu, Nov 03, 2022 at 05:08:15AM +0000, Peng Fan wrote: > > Subject: Re: [PATCH V2 0/2] remoteproc: imx: add start up delay > > > > On Wed, 2 Nov 2022 at 05:23, Peng Fan (OSS) <peng.fan@oss.nxp.com> > > wrote: > > > > > > From: Peng Fan <peng.fan@nxp.com> > > > > > > V2: > > > Rebased on linux-next > > > > > > V1: > > > > > > > > https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flore > > > .kernel.org%2Flkml%2F20220609123500.3492475-1- > > peng.fan%40oss.nxp.com%2 > > > > > F&data=05%7C01%7Cpeng.fan%40nxp.com%7Cf14584bdef9349e744ca > > 08dabcf7 > > > > > e1be%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C0%7C63803007007 > > 2451509%7 > > > > > CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJ > > BTiI6Ik1 > > > > > haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=Ck73gkOPpNVT > > kcZL8olCZP8B > > > %2BrIpZHV48uZBl2R8HdM%3D&reserved=0 > > > > > > There is case that after remoteproc start remote processor[M4], the M4 > > > runs slow and before M4 finish its own rpmsg framework initialization, > > > linux sends out vring kick message, then M4 firmware drops the kick > > > message. Some NXP released Cortex-M[x] images has such limitation that > > > it requires linux sends out vring kick message after M4 firmware > > > finish its rpmsg framework initialization. > > > > > > The best case is to use a method to let M4 notify Linux that M4 has > > > finished initialization, but we could not patch released firmware, > > > then update driver to detect notification. > > > > > > So add delay before linux send out vring kick message. It is not good > > > to use a fixed time delay in driver, so I choose to get that from > > > device tree. > > > > > > > From where I stand this is a hack to hide the lack of motivation to enact the > > real solution that is outlined above. I also wonder how these problems > > were not caught during the testing phase. Either find a way to upgrade your > > firmware or keep this in your internal tree. > In the beginning, i.mx not migrated to use remoteproc, i.MX release only support > uboot kick Cortex-M core and use downstream imx_rpmsg driver to > communicate with remote core. There is no runtime stop/start. > > After migrated to remoteproc, we do see some issue, but old firmware was > there. You could also attach() to that remote processor, if the HW supports it. But my position remains the same - either find a way to work with this situation that is not a hack or keep this patch in your internal tree. > > Thanks, > Peng. > > > > > > Peng Fan (2): > > > dt-bindings: remoteproc: imx_rproc: add fsl,startup-delay-ms > > > remoteproc: imx_rproc: delay after kick remote processor > > > > > > .../devicetree/bindings/remoteproc/fsl,imx-rproc.yaml | 4 ++++ > > > drivers/remoteproc/imx_rproc.c | 9 +++++++++ > > > 2 files changed, 13 insertions(+) > > > > > > -- > > > 2.37.1 > > >