in situ MTD upgrade from userspace (kernel, CRAMFS, YAFFS)

Josh Boyer jdub at us.ibm.com
Mon Nov 8 07:58:11 EST 2004


On Fri, 2004-11-05 at 16:59, David Wuertele wrote:
> > 1.  There are many other processes running at the time of the upgrade.
> >     They are running out of CRAMFS.  As I overwrite the CRAMFS
> >     partition, is it possible that my write could get corrupted?
> >     Perhaps by crashing programs that inadvertently do weird syscalls?
> 
> Corollary question:
> 
>   As my own userspace process overwrites the CRAMFS block that
>   contains that process's program, how can I ensure that the process
>   doesn't get hosed until after it has a chance to reboot the system?

Copy it and all it's needed shared libraries (including libc) into a
tmpfs and start it from there.

If you don't do that, then cramfs gets mighty confused if it needs to
read a text page of your app and thing have changed underneath it.

josh





More information about the linux-mtd mailing list