public inbox for ecos-devel@sourceware.org
 help / color / mirror / Atom feed
From: "Jürgen Lambrecht" <J.Lambrecht@televic.com>
To: Ross Younger <wry@ecoscentric.com>
Cc: Andrew Lunn <andrew@lunn.ch>,
	"ecos-devel@ecos.sourceware.org" 
	<ecos-devel@ecos.sourceware.org>
Subject: Re: Re: NAND review
Date: Fri, 19 Jun 2009 16:54:00 -0000	[thread overview]
Message-ID: <4A3BC2BF.3050106@televic.com> (raw)
In-Reply-To: <4A3B9D36.4000704@ecoscentric.com>

Ross Younger wrote:
>> Nick Garnett wrote:
>>     
<snip>
>> What is the typical life of a
>> block? 10000 erases? A developer may conceivably replace the kernel
>> 10,000 times, but in a deployed product i doubt this will happen. So i
>> say forget about wear leveling for this case.
>>     
>
> I have been thinking about lifespan and how likely we are to come across
> worn-bad blocks. The Samsung chip on the EA 2468 board specifies 100k
> write/erase cycles per block and data retention of at least ten years, which
> seems to be pretty typical for NAND parts, and comparable to most NOR parts?
>   
yes, but 20 years data retention (Spansion NOR).
>   
>> I'm assuming here that a NAND block
>> goes bad because of writes and erases, not reads and age. So once the
>> image has been successfully written, it should be readable forever.
>>     
>
> This is my understanding as well.
>   
mine too.
>   
>> Bad block are important. But a simple linear log structure should be
>> sufficient. When reading/writing if the BBT says the block is good,
>> use it, if it is bad, skip it.
>>     
>
> Properly NAND-aware filesystems take both kinds of bad blocks in their
> stride; there's no point in adding the complexity if such a mapping if
> you're using such a filesystem.
>
> Even with something simpler, factory-bad blocks are straightforward: as you
> say, one can simply linear-map them into oblivion in the driver at the cost
> of extra time complexity *on every NAND operation*. (I add the emphasis
> because I expect the overhead will add up fast if the NAND is heavily used.)
>
> Worn-bad blocks are harder; you can't ever add one to the mapping, because
> you'd have changed the in-flash address of everything above it.
>
> I've been thinking about this sort of question in the context of a simple
> layer to make NAND look like NOR for RedBoot, and have had an interesting
> idea which I'm going to propose on this list when I've written it up.
>
>
>   
>> The rootfs is a more interesting issue. Linux is very unlikely to boot
>> into a useful system without its rootfs. I see two options here. You
>> could tftp boot using a initramfs loaded to RAM to boot into linux
>> with a minimal system to perform a rootfs on NAND installation. Or
>> redboot has to somehow put the rootfs into the NAND partition.
>>     
>
> You could also embed your entire rootfs into the kernel image as a cramfs.
>
>
>   
>> This leads to three things:
>>
>> 1) Full read/write support for the FS in Redboot. For NOR we normally
>>    have only read support.
>>     
>
> Do you mean jffs2?
>
> At the moment my YAFFS layer is fully read-write, but I could add a
> read-only switch if this was thought to be useful?
>
>   
>> 2) mkfs functionality.
>>     
>
> I don't know about other filesystems, but YAFFS always scans the NAND on
> mount, and automatically does the Right Thing when asked to mount a
> fully-erased array. (My RedBoot patch already includes logic to erase a nand
> partition.)
>
>   
The same with JFFS2 (after a bugfix in my case).

Kind regards,
Juergen

  parent reply	other threads:[~2009-06-19 16:54 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-19  8:27 Simon Kallweit
2009-05-19 13:47 ` Ross Younger
2009-05-19 14:17   ` Andrew Lunn
2009-05-20 13:24     ` Bart Veer
2009-05-20 13:34       ` Rutger Hofman
2009-05-20 13:53         ` Andrew Lunn
2009-05-20 13:56           ` Gary Thomas
2009-05-20 14:22             ` Andrew Lunn
2009-05-20 15:22               ` Andrew Lunn
2009-05-20 15:34               ` Bart Veer
2009-05-20 13:58           ` Rutger Hofman
2009-05-20 14:16     ` Ross Younger
2009-05-20 14:21       ` Gary Thomas
2009-05-20 15:25         ` Ross Younger
2009-05-20 15:37           ` Gary Thomas
2009-05-19 16:29 ` Andrew Lunn
2009-06-03  8:51   ` Andrew Lunn
2009-06-03 10:21     ` Ross Younger
2009-06-03 10:48       ` Andrew Lunn
2009-06-03 11:52         ` Simon Kallweit
2009-06-03 12:26         ` Rutger Hofman
2009-06-03 13:33     ` Jürgen Lambrecht
2009-06-10 17:39     ` Nick Garnett
2009-06-11 11:25       ` Rutger Hofman
2009-06-13 16:31       ` Andrew Lunn
2009-06-18 14:10         ` Nick Garnett
2009-06-19  7:47           ` Andrew Lunn
2009-06-19 14:14             ` Ross Younger
2009-06-19 15:02               ` Andrew Lunn
2009-06-19 16:54               ` Jürgen Lambrecht [this message]
2009-06-29 11:09             ` Nick Garnett
2009-06-19  8:07           ` Andrew Lunn
2009-06-19 11:37             ` Daniel Morris
2009-06-19 12:06               ` Andrew Lunn
2009-05-20  1:02 ` Jonathan Larmour
2009-05-20  7:11   ` Simon Kallweit
2009-05-20 11:12     ` Rutger Hofman
2009-05-20 11:29       ` Simon Kallweit
2009-05-20 13:37         ` Rutger Hofman

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=4A3BC2BF.3050106@televic.com \
    --to=j.lambrecht@televic.com \
    --cc=andrew@lunn.ch \
    --cc=ecos-devel@ecos.sourceware.org \
    --cc=wry@ecoscentric.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).