xfs
[Top] [All Lists]

Re: Syncing problems.

To: Steve Lord <lord@xxxxxxx>
Subject: Re: Syncing problems.
From: Rajagopal Ananthanarayanan <ananth@xxxxxxx>
Date: Tue, 13 Feb 2001 14:01:37 -0800
Cc: Russell Cattelan <cattelan@xxxxxxxxxxx>, linux-xfs@xxxxxxxxxxx
References: <200102130207.f1D27kc07973@xxxxxxxxxxxxxxxxxxxx>
Sender: owner-linux-xfs@xxxxxxxxxxx
> > Hmm looks like we are not always writing stuff out.
> >
> > This system was up for several minutes before I locked it up.
> > This file has size but no extents.
> >

It may also be the case I ran into recently: when writepage
is employed to convert a delalloc page, prepare/commit_write is
used to convert a page if the page falls at EOF. In this case,
writepage used PBF_FILE_ALLOCATE, but prepare_write doesn't honor that.
Can you try the attached (but untested) patch?

----
--------------------------------------------------------------------------
Rajagopal Ananthanarayanan ("ananth")
Member Technical Staff, SGI.
--------------------------------------------------------------------------
--- /usr/tmp/TmpDir.25410-0/linux/fs/pagebuf/page_buf_io.c_1.51 Tue Feb 13 
13:56:53 2001
+++ linux/fs/pagebuf/page_buf_io.c      Tue Feb 13 13:56:01 2001
@@ -1248,7 +1248,7 @@
         * go get some space.
         */
        bh = page->buffers;
-       if ((!bh || !buffer_mapped(bh)) && !DelallocPage(page)) {
+       if ((!bh || !buffer_mapped(bh)) && (!DelallocPage(page) || (flags & 
PBF_FILE_ALLOCATE))) {
                if (!mp) {
                        mp = &map;
                        err = inode->i_op->pagebuf_bmap(inode,
<Prev in Thread] Current Thread [Next in Thread>