jffs2_gcd_mtdx thread and umount problem.

Joakim Tjernlund joakim.tjernlund at transmode.se
Mon Jan 18 20:13:39 EST 2010


Johnny Hung <johnny.hacking at gmail.com> wrote on 18/01/2010 09:26:26:
>
Please don't top post.

> Yes, umount / reboot command doesn't hang after first boot + wait for
> 20 minutes. The jffs2_gcd_mtdx will re-erase empty blocks but how do I
> know it is finished?

You don't or just monitor jffs2_gcd_mtdx until it is finished.

>
> BTW, why jffs2_gcd_mtd need to re-erase empty blocks and it will cause
> some command cannot work if erase block is necessary. I mean many
> pepple could meet this problem if it is need to erase empty block and
> how do they overcome or workaround it.

Because it might not be completely erased due to power failure in the
middle of an erase. You get random bit flips if that happens.

You can avoid this by writing clean markers in every empty block when you
install it, a bit messy though and it won't solve the general problem: Try
removing a few big files and then reboot, you will have to wait then too.
If you don't use JFFS2 as a module and unload it, you can my old patch which will
solve both problems.

    Jocke
>
> Thank you so much, Jocke
> BRs, H. Johnny
>
> > I guess this is the first reboot after mounting a new JFFS2 FS?
> > Then JFFS2 is reerasing empty blocks and you will have to wait
> > until it is done.
> >
> > I posted a patch long ago for this, but it was racy w.r.t JFSS2 module unload so
> > it didn't make it into the repo. Search the list for
> > "[JFFS2] Stop erasing blocks when rebooting." to find my old patch
> >
> >  Jocke
> >
> >
>



More information about the Linuxppc-dev mailing list