Message ID | 20231113155354.620298-1-debug.penguin32@gmail.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b909:0:b0:403:3b70:6f57 with SMTP id t9csp1295998vqg; Mon, 13 Nov 2023 07:54:44 -0800 (PST) X-Google-Smtp-Source: AGHT+IGSeoJ/9dNY/j42jaMdVn56migHdmaLvJMO+3W+xIcf5zJtODLuiRvkWomiypppcs97IjhK X-Received: by 2002:a05:6870:aa8a:b0:1e9:8eaf:c369 with SMTP id gr10-20020a056870aa8a00b001e98eafc369mr10362820oab.43.1699890884252; Mon, 13 Nov 2023 07:54:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1699890884; cv=none; d=google.com; s=arc-20160816; b=Hh0VMDLxJUYM4GwcuH5Ca8YjzUcm2Sp5mFiUT8DwyqRgOe5nSV5VjSadn1QHyj0/vm HTyl6/0r7Qa3V6MQrBVLFNrLRBGraDS3nPoY3CxJme5sw6bbvx78PM6XEtST/tvsanzW vauLQrC0/SyF7DUrV/9WxsY3gmW8vkl54C/sBQDS3rnoG3kBkUM9x82gFv2B7FUuuehZ LTRXuQ+rXJAM01gdJrnSS257XpnnefophS1b5JafQ8MuWKcADV+i8/A6eR+GCSdkcs+g NzTOFEJJBJQNJ0dHcgKpbaL5x2d/ooHBbeTtqGX7ItQKGr7Rx1S/WHu2HMgkb7tAwlYm rjNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:from :dkim-signature; bh=m9P5g3/fICZscbHOqQNcqknCdN9kVr+xTLjYRH6XTbc=; fh=G+gMxIP+s/NRUX0KFc+MbWG01Ae8dg+CbDWZx6hTV7k=; b=xYNixYN29jnaQqpnRF9UunShuQxmLyefbEhY7v3l9K5ZY0V7aImuadV1r15F4EvVLB 2NP0Gef0UFw5T7tEfIf+E8pSGaNtCNsdNp1/vuh6a1fH5KUGT/Fgu68aibCBnENbtDD/ dDAkg27jbHJwPuY7B8Hn21/vA1nCKcOppPaAxJaxpw0+z5BHC45f2uQxTCYn7riridxx jt+SxpUaP3GvF7H54x5AFahdj7pYuJtmUuT0D+H6E62KWQ2BKjLM9MrOPuhNyixgPAZv 1vcskg3ZU5yAV9bEl4GMOZMfLAZb2BElQPke0SfNJiJnFrysHXCV/GaiL1bPYbXv6/+4 beTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20230601 header.b=eTTRM7Rw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id eg23-20020a056a00801700b006baae7ecfacsi6031514pfb.308.2023.11.13.07.54.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Nov 2023 07:54:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20230601 header.b=eTTRM7Rw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id C0C6780A80FC; Mon, 13 Nov 2023 07:54:41 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231282AbjKMPyZ (ORCPT <rfc822;heyuhang3455@gmail.com> + 29 others); Mon, 13 Nov 2023 10:54:25 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54820 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229644AbjKMPyX (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 13 Nov 2023 10:54:23 -0500 Received: from mail-oi1-x232.google.com (mail-oi1-x232.google.com [IPv6:2607:f8b0:4864:20::232]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EAA0893; Mon, 13 Nov 2023 07:54:20 -0800 (PST) Received: by mail-oi1-x232.google.com with SMTP id 5614622812f47-3b2f28caab9so2851801b6e.1; Mon, 13 Nov 2023 07:54:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1699890860; x=1700495660; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=m9P5g3/fICZscbHOqQNcqknCdN9kVr+xTLjYRH6XTbc=; b=eTTRM7Rwd3EBv48LZWBcBqSucUfO5aZOsf2vd8gC+/rp3j1eKF6/sBpJ1lIMYTk0fI QHJ41rMcuds7wQuBpoOBzid8WPPq3bgOcbulPrzFgcAPmS5+nJlKiU2978JvD71U8982 nj5la319XQvcXMyQ2f0LHGALszE3CA2fHIbMnonclOvR88KVU7WQvF9X3h7tZA1fpvxD 7tj9axPBVWf7VAhMYFO9YD4RsXiKSEN7hA1dPQnU1spBtzbETcCA18Cio80CJAJtLWDx JoBcubKYSjnsenAOSCa8BKFxjnqGZvf8KF+VJh0j3OI5xebiXcp1knxW0xTsWsiBMjBO NqdQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1699890860; x=1700495660; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=m9P5g3/fICZscbHOqQNcqknCdN9kVr+xTLjYRH6XTbc=; b=mu5sigezdjhWED4PDaVqI4UI/s58N6OZJrNPYKJfDg0to6hU6mc6NJnbtUMb0dghAq 0XfBnMNtAzTU7ZQ6pDv4dBL5ABtaHHmkNBQ1WQZT8AqYKm/+uya+4+maQugBEYoXtVlT aslYlE4Bo6yjLanFKs1qnbNyd3xdDY7fveFkD+P9qHQuH31BISt5akNZCc0mhMVCaFyT QQu+M5TBQkaeSqjp4wPJLuNUTU0xBE3T50l0jVLF7xWBReEOOZ8yA26OIGhOrH2AN2yN ko4+12WTTwHR0nmoCn+NbXNoEgWYuHe6Ey+l9JQUSo/W/+EdpYLjA97OSxlVCyGeUKTt 5T7w== X-Gm-Message-State: AOJu0Yz1hqwRpaITxtxeRkxaM0EOo6xsZsxCkH4TBebwPEqM8gEpNtkb ApcLLXBbhpU0xG9BC3N5OBc= X-Received: by 2002:a54:4810:0:b0:3ac:a4ec:e136 with SMTP id j16-20020a544810000000b003aca4ece136mr7716635oij.51.1699890860256; Mon, 13 Nov 2023 07:54:20 -0800 (PST) Received: from localhost.localdomain ([149.167.148.33]) by smtp.gmail.com with ESMTPSA id e15-20020a65678f000000b0057ab7d42a4dsm3562722pgr.86.2023.11.13.07.54.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Nov 2023 07:54:19 -0800 (PST) From: Ronald Monthero <debug.penguin32@gmail.com> Cc: richard@nod.at, vigneshr@ti.com, heiko@sntech.de, martin.blumenstingl@googlemail.com, paul@crapouillou.net, robh@kernel.org, u.kleine-koenig@pengutronix.de, debug.penguin32@gmail.com, AVKrasnov@sberdevices.ru, r.czerwinski@pengutronix.de, andriy.shevchenko@linux.intel.com, jaimeliao.tw@gmail.com, linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org, Miquel Raynal <miquel.raynal@bootlin.com> Subject: [PATCH v2] mtd: rawnand: Increment IFC_TIMEOUT_MSECS for nand controller response Date: Tue, 14 Nov 2023 01:53:51 +1000 Message-Id: <20231113155354.620298-1-debug.penguin32@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231113131634.614467-1-debug.penguin32@gmail.com> References: <20231113131634.614467-1-debug.penguin32@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.3 required=5.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Mon, 13 Nov 2023 07:54:41 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1782464783835693775 X-GMAIL-MSGID: 1782464783835693775 |
Series |
[v2] mtd: rawnand: Increment IFC_TIMEOUT_MSECS for nand controller response
|
|
Commit Message
Ronald Monthero
Nov. 13, 2023, 3:53 p.m. UTC
Under heavy load it is likely that the controller is done
with its own task but the thread unlocking the wait is not
scheduled in time. Increasing IFC_TIMEOUT_MSECS allows the
controller to respond within allowable timeslice of 1 sec
fsl,ifc-nand 7e800000.nand: Controller is not responding
main/smp_fsm.c:1884 <inrcu: rcu_preempt detected stalls on CPUs/tasks:
rcu: Tasks blocked on level-0 rcu_node (CPUs 0-1): P116/2:b..l
(detected by 1, t=2102 jiffies, g=7729, q=754)
task:irq/31-arm-irq1 state:D stack: 0 pid: 116 ppid: 2 flags:0x00000000
[<8064b97f>] (__schedule) from [<8064bb01>] (schedule+0x8d/0xc2)
[<8064bb01>] (schedule) from [<8064dacd>]
[<8064dacd>] (rt_mutex_slowlock_block.constprop.0) from [<8064db57>]
[<8064db57>] (__rt_mutex_slowlock.constprop.0) from [<8064dbf7>]
[<8064dbf7>] (rt_mutex_slowlock.constprop.0) from [<804b2047>]
[<804b2047>] (nand_get_device) from [<804b5335>] (nand_write_oob+0x1b/0x4a)
[<804b5335>] (nand_write_oob) from [<804a3585>] (mtd_write+0x41/0x5c)
[<804a3585>] (mtd_write) from [<804c1d47>] (ubi_io_write+0x17f/0x22c)
[<804c1d47>] (ubi_io_write) from [<804c047b>] (ubi_eba_write_leb+0x5b/0x1d0)
Signed-off-by: Ronald Monthero <debug.penguin32@gmail.com>
---
drivers/mtd/nand/raw/fsl_ifc_nand.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Comments
You are too quick with v2, below my comments (new and old). On Tue, Nov 14, 2023 at 01:53:51AM +1000, Ronald Monthero wrote: > Under heavy load it is likely that the controller is done > with its own task but the thread unlocking the wait is not > scheduled in time. Increasing IFC_TIMEOUT_MSECS allows the > controller to respond within allowable timeslice of 1 sec Missing period at the end? > fsl,ifc-nand 7e800000.nand: Controller is not responding > main/smp_fsm.c:1884 <inrcu: rcu_preempt detected stalls on CPUs/tasks: > rcu: Tasks blocked on level-0 rcu_node (CPUs 0-1): P116/2:b..l > (detected by 1, t=2102 jiffies, g=7729, q=754) > task:irq/31-arm-irq1 state:D stack: 0 pid: 116 ppid: 2 flags:0x00000000 > [<8064b97f>] (__schedule) from [<8064bb01>] (schedule+0x8d/0xc2) > [<8064bb01>] (schedule) from [<8064dacd>] > [<8064dacd>] (rt_mutex_slowlock_block.constprop.0) from [<8064db57>] > [<8064db57>] (__rt_mutex_slowlock.constprop.0) from [<8064dbf7>] > [<8064dbf7>] (rt_mutex_slowlock.constprop.0) from [<804b2047>] At least above 9 lines are not important and may be removed. > [<804b2047>] (nand_get_device) from [<804b5335>] (nand_write_oob+0x1b/0x4a) > [<804b5335>] (nand_write_oob) from [<804a3585>] (mtd_write+0x41/0x5c) > [<804a3585>] (mtd_write) from [<804c1d47>] (ubi_io_write+0x17f/0x22c) > [<804c1d47>] (ubi_io_write) from [<804c047b>] (ubi_eba_write_leb+0x5b/0x1d0) ... > -#define IFC_TIMEOUT_MSECS 500 /* Maximum number of mSecs to wait > +#define IFC_TIMEOUT_MSECS 1000 /* Maximum number of mSecs to wait > for IFC NAND Machine */ While at it, you may improve the comment, e.g., "Maximum timeout to wait for IPC NAND Machine"
Hi Andy, Thanks for the feedback, I had not seen your response by then. I will modify and send it again. BR, Ron On Tue, Nov 14, 2023 at 2:04 AM Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote: > > You are too quick with v2, below my comments (new and old). > > On Tue, Nov 14, 2023 at 01:53:51AM +1000, Ronald Monthero wrote: > > Under heavy load it is likely that the controller is done > > with its own task but the thread unlocking the wait is not > > scheduled in time. Increasing IFC_TIMEOUT_MSECS allows the > > controller to respond within allowable timeslice of 1 sec > > Missing period at the end? > > > fsl,ifc-nand 7e800000.nand: Controller is not responding > > > main/smp_fsm.c:1884 <inrcu: rcu_preempt detected stalls on CPUs/tasks: > > rcu: Tasks blocked on level-0 rcu_node (CPUs 0-1): P116/2:b..l > > (detected by 1, t=2102 jiffies, g=7729, q=754) > > task:irq/31-arm-irq1 state:D stack: 0 pid: 116 ppid: 2 flags:0x00000000 > > [<8064b97f>] (__schedule) from [<8064bb01>] (schedule+0x8d/0xc2) > > [<8064bb01>] (schedule) from [<8064dacd>] > > [<8064dacd>] (rt_mutex_slowlock_block.constprop.0) from [<8064db57>] > > [<8064db57>] (__rt_mutex_slowlock.constprop.0) from [<8064dbf7>] > > [<8064dbf7>] (rt_mutex_slowlock.constprop.0) from [<804b2047>] > > At least above 9 lines are not important and may be removed. > > > [<804b2047>] (nand_get_device) from [<804b5335>] (nand_write_oob+0x1b/0x4a) > > [<804b5335>] (nand_write_oob) from [<804a3585>] (mtd_write+0x41/0x5c) > > [<804a3585>] (mtd_write) from [<804c1d47>] (ubi_io_write+0x17f/0x22c) > > [<804c1d47>] (ubi_io_write) from [<804c047b>] (ubi_eba_write_leb+0x5b/0x1d0) > > ... > > > -#define IFC_TIMEOUT_MSECS 500 /* Maximum number of mSecs to wait > > +#define IFC_TIMEOUT_MSECS 1000 /* Maximum number of mSecs to wait > > for IFC NAND Machine */ > > While at it, you may improve the comment, e.g., > > "Maximum timeout to wait for IPC NAND Machine" > > -- > With Best Regards, > Andy Shevchenko > >
diff --git a/drivers/mtd/nand/raw/fsl_ifc_nand.c b/drivers/mtd/nand/raw/fsl_ifc_nand.c index 20bb1e0cb5eb..42f8ea46b6a8 100644 --- a/drivers/mtd/nand/raw/fsl_ifc_nand.c +++ b/drivers/mtd/nand/raw/fsl_ifc_nand.c @@ -21,7 +21,7 @@ #define ERR_BYTE 0xFF /* Value returned for read bytes when read failed */ -#define IFC_TIMEOUT_MSECS 500 /* Maximum number of mSecs to wait +#define IFC_TIMEOUT_MSECS 1000 /* Maximum number of mSecs to wait for IFC NAND Machine */ struct fsl_ifc_ctrl;