public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: David Woodhouse <dwmw2@infradead.org>
To: tglx@linutronix.de
Cc: linux-mtd@lists.infradead.org
Cc: J B <mad_flasher@hotmail.com>
Subject: Re: moving MTD partitions
Date: Wed, 30 Apr 2003 14:04:00 +0100	[thread overview]
Message-ID: <1051707840.18316.452.camel@passion.cambridge.redhat.com> (raw)
In-Reply-To: <200304301557.04691.tglx@linutronix.de>

On Wed, 2003-04-30 at 14:57, Thomas Gleixner wrote:
> On Wednesday 30 April 2003 13:29, J B wrote:
> > "The basic question is if it is feasible to resize (smaller or larger) a
> > jffs2 filesystem / mtd block device over flash and maintain the existing
> > contents. Copying the contents out and then back again is not an option
> > (not enough space)."
> 
> First answer is no.
> On second thought could be a possibility to do so. 

Well, making it _larger_ is trivial. Just extend the partition with
empty erase blocks, and they'll get used.

Making it smaller is of course more of a problem -- you need to force
garbage collection until there's at least one block which is completely
free, then unmount, move the last block of the fs into the newly-freed
block, reduce the size by one block and remount it. Repeat.

You used to be able to force GC by repeatedly sending SIGHUP to the
kernel's GC daemon process, but I think Thomas is right that you can't
do that any more and you have to hack it. You'd probably do better to do
it offline with a special tool. 

-- 
dwmw2

  reply	other threads:[~2003-04-30 13:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-30 11:29 moving MTD partitions J B
2003-04-30 13:57 ` Thomas Gleixner
2003-04-30 13:04   ` David Woodhouse [this message]
     [not found] <Law11-F117Oc7wo95EF00013168@hotmail.com>
2003-04-30 16:28 ` Thomas Gleixner

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=1051707840.18316.452.camel@passion.cambridge.redhat.com \
    --to=dwmw2@infradead.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=tglx@linutronix.de \
    /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