From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754835AbaCNOwW (ORCPT ); Fri, 14 Mar 2014 10:52:22 -0400 Received: from cantor2.suse.de ([195.135.220.15]:33569 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754319AbaCNOwS (ORCPT ); Fri, 14 Mar 2014 10:52:18 -0400 Date: Fri, 14 Mar 2014 15:52:15 +0100 From: Jan Kara To: Roman Peniaev Cc: Jan Kara , Tejun Heo , Andrew Morton , Alexander Viro , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, Jens Axboe Subject: Re: [PATCH 1/1] fs/mpage.c: forgotten WRITE_SYNC in case of data integrity write Message-ID: <20140314145215.GG18583@quack.suse.cz> References: <20140218155945.ee2e22e07fa3b4f242b16a7f@linux-foundation.org> <20140313200119.GB504@quack.suse.cz> <20140313143456.157404fd7f208638ca70e317@linux-foundation.org> <20140314130712.GC12613@htj.dyndns.org> <20140314141143.GH12613@htj.dyndns.org> <20140314141511.GF18583@quack.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri 14-03-14 23:23:45, Roman Peniaev wrote: > On Fri, Mar 14, 2014 at 11:15 PM, Jan Kara wrote: > > On Fri 14-03-14 10:11:43, Tejun Heo wrote: > >> > Also, could you please help me do understand how can I guarantee > >> > integrity in case of block device with big volatile > >> > cache and filesystem, which does not support REQ_FLUSH/FUA? > >> > >> If a device has a volatile cache but doesn't support flush, it can't > >> guarantee integrity. There's no way for its user to determine or > >> force whether certain data is on non-volatile media. It's an > >> inherently broken device. > > I think his problem was that the device does support REQ_FLUSH/FUA but > > the filesystem on top of it doesn't issue it properly. That's a filesystem > > problem so fix the filesystem... :) Which one is it? > > take any old school, e.g. ext2 or even better: fat :) Well, for ext2, you can use ext4 kernel driver which takes care of REQ_FLUSH properly. For fat, you'll need to fix the fs... Honza -- Jan Kara SUSE Labs, CR