mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Jörn Engel" <joern@wohnheim.fh-wedel.de>
To: Pierre Ossman <drzeus-list@drzeus.cx>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: Re: Flash erase groups and filesystems
Date: Tue, 16 Aug 2005 20:52:30 +0200	[thread overview]
Message-ID: <20050816185230.GA2931@wohnheim.fh-wedel.de> (raw)
In-Reply-To: <20050816181336.GA2014@wohnheim.fh-wedel.de>

On Tue, 16 August 2005 20:13:36 +0200, Jörn Engel wrote:
> On Tue, 16 August 2005 19:09:12 +0200, Pierre Ossman wrote:
> > 
> > I'm not sure we're talking about the same thing. I'm not suggesting new
> > features in the VFS layer. I want to know if something breaks if I
> > implement this erase feature in the MMC layer. In essence the file
> > system has marked the sectors as "forget" by issuing a write to them.
> > The question is if it is assumed that they are unchanged if the write
> > fails half-way through.
> 
> Yes.  Most filesystems expect to find either 1) old data or 2) new
> data.  Blocks full of 0xff are non-expected.

Maybe this isn't obvious.  Because of this expectation, it is
absolutely not safe to pre-erase blocks, just because the fs will
write them anyway.  Unless you can guarantee that the write will
always succeed, even in case of power outage, you just broke the
expectation.

Fixing all filesystem is also not an option, even ignoring the
question whether such a change would be a fix, a change of behaviour
or a plain bug.

So the only remaining option is to add a new interface that lets
filesystems decide to support pre-erase in some form.  And one such
interface would be the "forget" operation.  Nice attribute of forget
is the fact that it would also help some FTL layers in the kernel.
There is nothing MMC-specific about it.

Jörn

-- 
But this is not to say that the main benefit of Linux and other GPL
software is lower-cost. Control is the main benefit--cost is secondary.
-- Bruce Perens

  reply	other threads:[~2005-08-16 18:52 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-08-15 20:21 Pierre Ossman
2005-08-16 16:27 ` Jörn Engel
2005-08-16 17:09   ` Pierre Ossman
2005-08-16 18:13     ` Jörn Engel
2005-08-16 18:52       ` Jörn Engel [this message]
2005-08-17 11:35         ` Pierre Ossman
2005-08-17 11:45           ` Jörn Engel
2005-08-17 14:35     ` Pavel Machek
2005-08-18 11:09       ` linux-os (Dick Johnson)

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=20050816185230.GA2931@wohnheim.fh-wedel.de \
    --to=joern@wohnheim.fh-wedel.de \
    --cc=drzeus-list@drzeus.cx \
    --cc=linux-kernel@vger.kernel.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

all inboxes | Powered by JetHome®