linux-mtd.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
To: Richard Genoud <richard.genoud@gmail.com>,
	"Velykokhatko, Sergey" <Sergey.Velykokhatko@mcc-med.de>
Cc: Ricard Wanderlof <ricard.wanderlof@axis.com>,
	Brian Norris <computersforpeace@gmail.com>,
	"linux-mtd@lists.infradead.org" <linux-mtd@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: Bug in mtd_get_device_size()?
Date: Mon, 11 Mar 2013 10:08:51 +0200	[thread overview]
Message-ID: <1362989331.5101.41.camel@sauron.fi.intel.com> (raw)
In-Reply-To: <CACQ1gAhJzy5tGSuejc3GqaqRxtHvkABOY-tODzedveeRXddvxQ@mail.gmail.com>

On Fri, 2013-03-01 at 15:29 +0100, Richard Genoud wrote:
> > Unfortunately I have no additional information why it happened, but
> anyway is it really necessary to runs ubiformat+ubimkvol for such
> cases? Or is it possible to recover data?
> I honestly don't know, but I'm sure Artem has some idea on that.

Everything should work in theory. If there are issues, they should be
looked at and investigated. I do not have any better suggestion off the
top of my head.

> >Since my solution for this case is to put the device data in separate MTD with one single UBI volume. But you know how much space I should reserve on NAND MTD for single XML-File with 200Bytes :-).
> I've got the same problem with uboot environment for example. It's
> only some hundred bytes, and still I have to reserve the maximum bad
> blocks number + 1 for the environment itself (so for your device 41).
> I know, this looks overkill...
> For 200bytes, I would try to store them elsewhere (spi dataflash,
> eeprom...) if there's such devices on your board.
> There's also the 1st block of the nand device which is guaranteed to
> be "valid" for 1000 erase cycles (valid with 1-bit ECC per 528 bytes)

The ideal solution would be to not partition the chip at all, of course.

BTW, if we ara talking about a device for medicine with tens of years of
lifetime, you need to be careful about read disturb issues. In the MTD
web site we discuss them - and there is a suggestion to read whole UBI
device from time to time to force scrubbing.

> > Alternative is to try to mount only device volume, copy data in tmpfs, run ubiformat+ubimkvol+mount and copy the data back to the device volume. Or you have other idea?

Not sure why this would be needed. We did not do any on-flash format
breakage AFAIK. But I admit I did not read this thread carefully.

Sergey, feel free to ask specific questions in separate threads, to make
it easier to answer them.

-- 
Best Regards,
Artem Bityutskiy

  reply	other threads:[~2013-03-11  8:08 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-28 12:30 Bug in mtd_get_device_size()? Velykokhatko, Sergey
2013-02-28 17:24 ` Brian Norris
2013-03-01  8:10   ` Richard Genoud
2013-03-01  9:36     ` AW: " Velykokhatko, Sergey
2013-03-01  8:29   ` Velykokhatko, Sergey
2013-03-01 10:35     ` Richard Genoud
2013-03-01 11:49       ` AW: " Velykokhatko, Sergey
2013-03-01 12:09         ` Richard Genoud
2013-03-01 13:27           ` AW: " Velykokhatko, Sergey
2013-03-01 14:29             ` Richard Genoud
2013-03-11  8:08               ` Artem Bityutskiy [this message]
     [not found]                 ` <BAF0C2081321BA469F9ADF648F97D9B04C78FA60DB@MCC023.weinmann.com>
2013-03-11 16:39                   ` UBI. How are critical these messages? Artem Bityutskiy
2013-03-01 12:02       ` Bug in mtd_get_device_size()? Ricard Wanderlof

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=1362989331.5101.41.camel@sauron.fi.intel.com \
    --to=artem.bityutskiy@linux.intel.com \
    --cc=Sergey.Velykokhatko@mcc-med.de \
    --cc=computersforpeace@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=ricard.wanderlof@axis.com \
    --cc=richard.genoud@gmail.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 NNTP newsgroup(s).