From mboxrd@z Thu Jan 1 00:00:00 1970 From: npiggin@suse.de Subject: [patch 9/9] mm: do_sync_mapping_range integrity fix Date: Wed, 29 Oct 2008 01:47:24 +1100 Message-ID: <20081028145734.706927000@nick.local0.net> References: <20081028144715.683011000@suse.de> Cc: linux-fsdevel@vger.kernel.org, Dave Chinner , Chris Mason To: akpm@linux-foundation.org Return-path: Received: from cantor2.suse.de ([195.135.220.15]:59488 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752889AbYJ1PBL (ORCPT ); Tue, 28 Oct 2008 11:01:11 -0400 Content-Disposition: inline; filename=mm-do-sync-mapping-range-fix.patch Sender: linux-fsdevel-owner@vger.kernel.org List-ID: Chris Mason notices do_sync_mapping_range didn't actually ask for data integrity writeout. Unfortunately, it is advertised as being usable for data integrity operations. This is a data interity bug. Signed-off-by: Nick Piggin --- Index: linux-2.6/fs/sync.c =================================================================== --- linux-2.6.orig/fs/sync.c +++ linux-2.6/fs/sync.c @@ -269,7 +269,7 @@ int do_sync_mapping_range(struct address if (flags & SYNC_FILE_RANGE_WRITE) { ret = __filemap_fdatawrite_range(mapping, offset, endbyte, - WB_SYNC_NONE); + WB_SYNC_ALL); if (ret < 0) goto out; } --