Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 12 Oct 2001 22:06:01 +0200
From:      Poul-Henning Kamp <phk@critter.freebsd.dk>
To:        Matt Dillon <dillon@FreeBSD.org>
Cc:        cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/sys/vm vnode_pager.c 
Message-ID:  <15537.1002917161@critter.freebsd.dk>
In-Reply-To: Your message of "Fri, 12 Oct 2001 11:17:34 PDT." <200110121817.f9CIHYU38714@freefall.freebsd.org> 

next in thread | previous in thread | raw e-mail | index | archive | help

Me and my laptop have been wondering about that bug for some time :-)

Thanks!

In message <200110121817.f9CIHYU38714@freefall.freebsd.org>, Matt Dillon writes
:
>dillon      2001/10/12 11:17:34 PDT
>
>  Modified files:
>    sys/vm               vnode_pager.c 
>  Log:
>  Finally fix the VM bug where a file whos EOF occurs in the middle of a page
>  would sometimes prevent a dirty page from being cleaned, even when synced,
>  resulting in the dirty page being re-flushed to disk every 30-60 seconds or
>  so, forever.  The problem is that when the filesystem flushes a page to
>  its backing file it typically does not clear dirty bits representing areas
>  of the page that are beyond the file EOF.  If the file is also mmap()'d and
>  a fault is taken, vm_fault (properly, is required to) set the vm_page_t->dirty
>  bits to VM_PAGE_BITS_ALL.  This combination could leave us with an uncleanable,
>  unfreeable page.
>  
>  The solution is to have the vnode_pager detect the edge case and manually
>  clear the dirty bits representing areas beyond the file EOF.  The filesystem
>  does the rest and the page comes up clean after the write completes.
>  
>  MFC after:	3 days
>  
>  Revision  Changes    Path
>  1.138     +22 -4     src/sys/vm/vnode_pager.c
>
>

-- 
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk@FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?15537.1002917161>