[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87pq06f5ee.fsf@rustcorp.com.au>
Date: Tue, 12 Feb 2013 16:19:29 +1030
From: Rusty Russell <rusty@...tcorp.com.au>
To: Johannes Weiner <hannes@...xchg.org>
Cc: LKML <linux-kernel@...r.kernel.org>,
Andrew Morton <akpm@...ux-foundation.org>,
"Nick Piggin" <npiggin@...nel.dk>,
Stewart Smith <stewart@...mingspork.com>
Subject: Re: RFC: mincore: add a bit to indicate a page is dirty.
Johannes Weiner <hannes@...xchg.org> writes:
> On Mon, Feb 11, 2013 at 01:43:03PM +1030, Rusty Russell wrote:
>> I am writing an app which really wants to know if a file is on the
>> disk or not (ie. do I need to sync?).
>
> When the page is under writeback, it's not necessarily on disk yet,
> but you also don't need to sync. Which semantics make more sense?
>
> I'm leaning toward checking both PG_dirty and PG_writeback.
If it's already under PG_writeback, you probably still need to wait for
it to finish if you're trying to ensure write ordering. ie. sync.
I've updated my patch by stealing your code.
Thanks!
Rusty.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists