public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: Adrian Hunter <adrian.hunter@nokia.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Rohit Hagargundgi <h.rohit@samsung.com>,
	David Woodhouse <dwmw2@infradead.org>,
	"linux-mtd@lists.infradead.org" <linux-mtd@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"Bityutskiy Artem \(Nokia-M/Helsinki\)"
	<Artem.Bityutskiy@nokia.com>
Subject: Re: [PATCH 1/3] [MTD] Flex-OneNAND support
Date: Thu, 05 Mar 2009 15:38:50 +0200	[thread overview]
Message-ID: <49AFD5EA.5010502@nokia.com> (raw)
In-Reply-To: <20090304085055.c9de6cbb.akpm@linux-foundation.org>

Andrew Morton wrote:
>>>> +	return mtd->ecc_stats.corrected - stats.corrected ? -EUCLEAN : 0;
>>>> +}
>>> I wonder what the heck EUCLEAN was invented for and whether MTD's
>>> extensive use of it is appropriate.
>> UBI uses it to detect bit-flips so that data can be moved before it
>> can no longer be read.  So it is pretty much essential for flash
>> memories.
> 
> That's not the point.
> 
> My point is: for what purpose was EUNCLEAN created by whoever created
> it and, given that, is its use by MTD appropriate?  Because it does
> appear that this gets returned all the way to userspace sometimes.

I have had a look at the use of EUCLEAN and found the following:
	1. It does not seem to be defined in POSIX
	2. It may have been used by unix variants to indicate an
attempt to mount a file system whose superblock was not marked
as clean.
	3. In Linux, it is used almost exclusively by MTD, with
one exception in smbfs, from which it is tempting to conclude that
smbfs (at least) is using it incorrectly.  There is one web page
http://www.wlug.org.nz/EUCLEAN where the author suggests ENOMEDIUM
might be a better choice.

Can you point me to where EUCLEAN is returned to userspace?  I took
a quick look and couldn't see it.

  parent reply	other threads:[~2009-03-05 13:40 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-03  6:36 [PATCH 1/3] [MTD] Flex-OneNAND support Rohit Hagargundgi
2009-03-03 20:49 ` Andrew Morton
2009-03-04 11:41   ` Adrian Hunter
2009-03-04 16:50     ` Andrew Morton
2009-03-04 23:47       ` Kyungmin Park
2009-03-04 23:55         ` Andrew Morton
2009-03-05  3:43           ` Kyungmin Park
2009-03-05  4:46             ` Amit Kumar Sharma
2009-03-05 13:38       ` Adrian Hunter [this message]
2009-03-05 14:46         ` Artem Bityutskiy
2009-03-05 19:13         ` Andrew Morton
2009-03-05 18:18   ` Rohit Hagargundgi

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=49AFD5EA.5010502@nokia.com \
    --to=adrian.hunter@nokia.com \
    --cc=Artem.Bityutskiy@nokia.com \
    --cc=akpm@linux-foundation.org \
    --cc=dwmw2@infradead.org \
    --cc=h.rohit@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mtd@lists.infradead.org \
    /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