On Thu, Feb 10, 2005 at 09:39:05AM -0800, Badari Pulavarty wrote:
> On Wed, 2005-02-09 at 08:37, Stephen C. Tweedie wrote:
> > Hi,
> > 
> > On Wed, 2005-02-09 at 16:18, Badari Pulavarty wrote:
> > 
> > > I am trying to understand journaling code in ext3. 
> > > Can some one enlighten me, why we need journal start
> > > and stop in ext3_writeback_writepage() ? The block
> > > allocation is already made in prepare_write().
> > 
> > prepare_write()/commit_write() are used for write(2) writes: the data is
> > dirtied, but not immediately queued for IO (unless you're using O_SYNC).
> >  
> > writepage is used when you want to write the page's data to disk
> > *immediately* --- it's used when the VM is swapping out an mmaped file,
> > or for msync().
> > 
> > So when writepage comes in, there's no guarantee that we've had a
> > previous prepare.  You can, for example, use ftruncate() to create a
> > large hole in a file, and then mmap() it; if you then dirty a page, then
> > the allocation occurs in the writepage().  So a transaction handle is
> > necessary.
> > 
> > --Stephen
> 
> Okay, I started hacking. I added ext3_writeback_writepages() which calls
> journal start/stop before calling mpage_writepages().
> 
> I am getting OOPs which puzzles me. 2 reasons why..
> 
> 1) First of all OOps in is __mod_timer() which I have not touched.

Total Guess:

Callback after io-completed is blowing up ?  Especially if it is
trying to touch a buffer_head that isn't there or something. 

Sonny
-
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to