lkml.org 
[lkml]   [2001]   [Jan]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH] filemap_fdatasync & related changes


    On Thu, 4 Jan 2001, Chris Mason wrote:
    >
    > The page dirty bit is not reset.
    > the page is never unlocked.
    >
    > So how about something like this in filemap_fdatasync

    I'd rather just change the rule that "writepage()" will clear the dirty
    bit itself and always unlock (and "1" just to inform the upper layers that
    the page cannot be thrown away).

    > And then, in filemap_fdatawait:
    >
    > list_del(&page->list) ;
    > if (PageDirty(page))
    > list_add(&page->list, &mapping->dirty_pages) ;
    > else
    > list_add(&page->list, &mapping->clean_pages) ;

    Can't be done. The thing depends on the fact that it always depletes the
    dirty list. The whole fdatasync() logic hinges on the fact that it will
    always move pages "down" - otherwise it will never complete.

    Linus

    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 12:52    [W:3.727 / U:0.012 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site