Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756737AbbGVNrU (ORCPT ); Wed, 22 Jul 2015 09:47:20 -0400 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:34399 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754568AbbGVNrR (ORCPT ); Wed, 22 Jul 2015 09:47:17 -0400 Date: Wed, 22 Jul 2015 15:47:13 +0200 From: Pavel Machek To: NeilBrown Cc: NeilBrown , "J. Bruce Fields" , John Stoffel , Austin S Hemmelgarn , Kevin Easton , "Theodore Ts'o" , Sage Weil , Trond Myklebust , Dave Chinner , Zach Brown , Alexander Viro , Linux FS-devel Mailing List , Linux Kernel Mailing List , Linux API Mailing List Subject: Re: [PATCH RFC] vfs: add a O_NOMTIME flag Message-ID: <20150722134713.GB20106@amd> References: <20150511144719.GA14088@thunk.org> <20150511231021.GC14088@thunk.org> <20150512050821.GA9404@chicago.guarana.org> <5551E7EB.8040301@gmail.com> <21842.1555.38099.868100@quad.stoffel.home> <20150512143637.GA6370@fieldses.org> <20150513083951.5eb63bc0@notabene.brown> <20150714131300.GA6804@amd> <20150715145456.0376796b@noble> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150715145456.0376796b@noble> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1795 Lines: 51 On Wed 2015-07-15 14:54:56, NeilBrown wrote: > On Tue, 14 Jul 2015 15:13:00 +0200 Pavel Machek wrote: > > > Hi! > > > > > BTW When you "swap" to a file the mtime doesn't get updated. No one seems to > > > complain about that. I guess it is a rather narrow use-case though. > > > > Actually yes, I'd like to complain. > > > > It was not swap, it was mount -o loop, but I guess that's the same > > case. Then rsync refused to work on that file... and being on slow ARM > > system it took me a while to figure out WTF is going on. > > > > So yes, we have problems with mtime, and yes, they matter. > > Pavel > > Odd... > I assume you mean > mount -o loop /some/file /mountpoint > > and then when you write to the filesystem on /mountpoint the mtime > of /some/file doesn't get updated? > I think it should. > drivers/block/loop.c uses vfs_iter_write() to write to a file. > That calls f_op->write_iter which will typically call > generic_file_write_iter() which will call file_update_time() to update > the time stamps. Yes, that. I'm pretty sure I seen it, but it was probably on 2.6.X kernel... Does it make sense to try to reproduce it on the old kernel? > What filesystem was /some/file on? Very probably VFAT. > I just did some testing on ext4 and it seems to do the right thing > mtime gets updated. Yes, I tried here, and it seems to be ok. Thanks, Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/