Re: [patch 5/8] mm: write_cache_pages integrity fix

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Oct 09, 2008 at 09:35:58AM -0400, Chris Mason wrote:
> On Thu, 2008-10-09 at 15:27 +0200, Nick Piggin wrote:
> 
> I don't think do_sync_mapping_range is broken as is.  It simply splits
> the operations into different parts.  The caller can request that we
> wait for pending IO first.

It is. Not because of it's whacky API, but because it uses WB_SYNC_NONE. 


> WB_SYNC_NONE none just means don't wait for IO in flight, and there are
> valid uses for it that will slow down if you switch them all to
> WB_SYNC_ALL.

To write_cache_pages it means that, but further down the chain (eg.
block_write_full_page) it also means not to wait on other stuff.

It has broadly meant "don't worry about data integirty" for a long time
AFAIKS.


> The problem is that we have a few flags and callers that mean almost but
> not quite the same thing.  Some people confuse WB_SYNC_NONE with
> wbc->nonblocking.
> 
> I'd leave WB_SYNC_NONE alone and set wbc->nr_to_write to the max int, or
> just make a new flag that says write every dirty page in this range.

Well it wouldn't hurt to clarify things. I'd rather introduce a new
WB_SYNC_WRITEBACK or something for that guy. But anyway, as I said,
it's just a minimal fix.

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

[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux