All of lore.kernel.org
 help / color / mirror / Atom feed
From: Josh Wu <josh.wu@atmel.com>
To: Brian Norris <computersforpeace@gmail.com>,
	Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Cc: Lior Amsalem <alior@marvell.com>,
	Tawfik Bayouk <tawfik@marvell.com>,
	Nadav Haklai <nadavh@marvell.com>,
	linux-mtd@lists.infradead.org,
	Ezequiel Garcia <ezequiel.garcia@free-electrons.com>,
	David Woodhouse <dwmw2@infradead.org>
Subject: Re: [PATCH] mtd: nand: reduce the warning noise when the ECC is too weak
Date: Fri, 18 Jul 2014 17:59:45 +0800	[thread overview]
Message-ID: <53C8F011.7020507@atmel.com> (raw)
In-Reply-To: <20140714052259.GD29385@norris-Latitude-E6410>

Hi, Brian

On 7/14/2014 1:22 PM, Brian Norris wrote:
> On Wed, Jul 02, 2014 at 03:16:32PM +0200, Thomas Petazzoni wrote:
>> In commit 67a9ad9b8a6f ("mtd: nand: Warn the user if the selected ECC
>> strength is too weak"), a check was added to inform the user when the
>> ECC used for a NAND device is weaker than the recommended ECC
>> advertised by the NAND chip. However, the warning uses WARN_ON(),
>> which has two undesirable side-effects:
>>
>>   - It just prints to the kernel log the fact that there is a warning
>>     in this file, at this line, but it doesn't explain anything about
>>     the warning itself.
>>
>>   - It dumps a stack trace which is very noisy, for something that the
>>     user is most likely not able to fix. If a certain ECC used by the
>>     kernel is weaker than the advertised one, it's most likely to make
>>     sure the kernel uses an ECC that is compatible with the one used by
>>     the bootloader, and changing the bootloader may not necessarily be
>>     easy. Therefore, normal users would not be able to do anything to
>>     fix this very noisy warning, and will have to suffer from it at
>>     every kernel boot. At least every time I see this stack trace in my
>>     kernel boot log, I wonder what new thing is broken, just to realize
>>     that it's once again this NAND ECC warning.
>>
>> Therefore, this commit turns:
>>
>> ------------[ cut here ]------------
>> WARNING: CPU: 0 PID: 1 at /home/thomas/projets/linux-2.6/drivers/mtd/nand/nand_base.c:4051 nand_scan_tail+0x538/0x780()
>> Modules linked in:
>> CPU: 0 PID: 1 Comm: swapper Not tainted 3.16.0-rc3-dirty #4
>> [<c000e3dc>] (unwind_backtrace) from [<c000bee4>] (show_stack+0x10/0x14)
>> [<c000bee4>] (show_stack) from [<c0018180>] (warn_slowpath_common+0x6c/0x8c)
>> [<c0018180>] (warn_slowpath_common) from [<c001823c>] (warn_slowpath_null+0x1c/0x24)
>> [<c001823c>] (warn_slowpath_null) from [<c02c50cc>] (nand_scan_tail+0x538/0x780)
>> [<c02c50cc>] (nand_scan_tail) from [<c0639f78>] (orion_nand_probe+0x224/0x2e4)
>> [<c0639f78>] (orion_nand_probe) from [<c026da00>] (platform_drv_probe+0x18/0x4c)
>> [<c026da00>] (platform_drv_probe) from [<c026c1f4>] (really_probe+0x80/0x218)
>> [<c026c1f4>] (really_probe) from [<c026c47c>] (__driver_attach+0x98/0x9c)
>> [<c026c47c>] (__driver_attach) from [<c026a8f0>] (bus_for_each_dev+0x64/0x94)
>> [<c026a8f0>] (bus_for_each_dev) from [<c026bae4>] (bus_add_driver+0x144/0x1ec)
>> [<c026bae4>] (bus_add_driver) from [<c026cb00>] (driver_register+0x78/0xf8)
>> [<c026cb00>] (driver_register) from [<c026da5c>] (platform_driver_probe+0x20/0xb8)
>> [<c026da5c>] (platform_driver_probe) from [<c00088b8>] (do_one_initcall+0x80/0x1d8)
>> [<c00088b8>] (do_one_initcall) from [<c0620c9c>] (kernel_init_freeable+0xf4/0x1b4)
>> [<c0620c9c>] (kernel_init_freeable) from [<c049a098>] (kernel_init+0x8/0xec)
>> [<c049a098>] (kernel_init) from [<c00095f0>] (ret_from_fork+0x14/0x24)
>> ---[ end trace 62f87d875aceccb4 ]---
>>
>> Into the much shorter, and much more useful:
>>
>> nand: WARNING: MT29F2G08ABAEAWP: the ECC used on your system is too weak compared to the one required by the NAND chip
>>
>> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
> Pushed to linux-mtd.git, for 3.16 I think. Thanks!

Excuse me that to ask a question which is not related with the code.

I find this fix is not in l2-mtd.git but only in linux-mtd.git. So I 
wondering how the patch is merged in linux mainline and stable tree.

Will the linux-mtd.git be merged in linux mainline and stable git tree 
before v3.16 release? So the l2-mtd.git can rebase on the merged tag.

Am I understand the flow correctly?

Thanks in advance.

Best Regards,
Josh Wu
>
> Brian
>
> ______________________________________________________
> Linux MTD discussion mailing list
> http://lists.infradead.org/mailman/listinfo/linux-mtd/

  reply	other threads:[~2014-07-18 10:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-02 13:16 [PATCH] mtd: nand: reduce the warning noise when the ECC is too weak Thomas Petazzoni
2014-07-14  5:22 ` Brian Norris
2014-07-18  9:59   ` Josh Wu [this message]
2014-07-18 16:54     ` Brian Norris
2014-07-21  6:33       ` Josh Wu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=53C8F011.7020507@atmel.com \
    --to=josh.wu@atmel.com \
    --cc=alior@marvell.com \
    --cc=computersforpeace@gmail.com \
    --cc=dwmw2@infradead.org \
    --cc=ezequiel.garcia@free-electrons.com \
    --cc=linux-mtd@lists.infradead.org \
    --cc=nadavh@marvell.com \
    --cc=tawfik@marvell.com \
    --cc=thomas.petazzoni@free-electrons.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.