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

Re: Max Mount Count

Stephen writes:
> On Fri, Jun 08, 2001 at 10:48:03AM -0600, Andreas Dilger wrote:
> > Could you send me the ext3 lockfs/unlockfs functions you are using so I can
> > add them to the 2.4 CVS?  I wrote some which I _think_ are OK, but since
> > you have already tested yours...
> Check out ext3_change_inode_journal_flag() in CVS --- that already
> uses an established manner for locking an ext3 filesystem:
> 	journal_lock_updates(journal);
> 	journal_flush(journal);
> to lock the journal and flush any pending updates to disk, effectively
> freezing the filesystem; and 
> 	journal_unlock_updates(journal);
> to resume.

I totally agree, and I am using these.  However, there needs to be a pair of
super_operations functions "ext3_write_super_lockfs()" and "ext3_unlockfs()"
which actually call the above functions.  I basically took the code out
of ext3_change_inode_journal_flag() to make the lockfs() and unlockfs() code
(adding some bits to clear the RECOVERY superblock flag before the snapshot
and turning it back on after the snapshot).

However, rather than forgetting a few bits and re-doing the testing Jay
has already done, I would rather just take a look at what he has.

Cheers, Andreas
Andreas Dilger  \ "If a man ate a pound of pasta and a pound of antipasto,
                 \  would they cancel out, leaving him still hungry?"
http://www-mddsp.enel.ucalgary.ca/People/adilger/               -- Dogbert

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