[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Suggestion: Read-Only mount - No gc



> Sorry, should I have been less terse? You can 'remount' filesystems
> read-write when they were previously read-only. If you do so with 
your
> patch in place, you'll find that you have no GC thread.

> It would be nice to make it start the GC thread (if it's not already
> running) when the filesystem is remounted read-write, and also to 
make it
> _stop_ the GC thread when the filesystem is remounted read-only. 

> Note that you only need to STOP the GC thread in the latter case, 
not kill
> it. And that restarting the GC thread upon 'mount -orw,remount' is 
useful
> even then the filesystem was _already_ read-write, because you can 
kill
> the GC thread directly by sending it the right signal.

> -- 
> dwmw2

David:

I have added the remount support you requested; however, I went
the kill route rather than the stop route. It is more suitable
for my application.

Remounting from RO/RW to RW will start the GC thread if one is
not present. Remounting from RW to RO will kill the GC thread.

Here are the changes in a 'diff -u' format. My testing was
done with inode-v22.c. I have included what I think the
changes for inode-v23.c should be. It looks like the v22 and
v23 are bit out of step in the jffs_read_super() with respect to
lock_super() and module incrementing - so I guessed.






--------------------------------
Bye!
Dan McDonald
The Late Night Software Shop 
Sign up today for your Free E-mail at: http://www.canoe.ca/CanoeMail 

remount.diff