linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Maxim Patlasov <mpatlasov@parallels.com>
To: Miklos Szeredi <miklos@szeredi.hu>
Cc: <dev@parallels.com>, <xemul@parallels.com>,
	<fuse-devel@lists.sourceforge.net>, <bfoster@redhat.com>,
	<linux-kernel@vger.kernel.org>, <jbottomley@parallels.com>,
	<linux-fsdevel@vger.kernel.org>, <akpm@linux-foundation.org>,
	<fengguang.wu@intel.com>, <devel@openvz.org>
Subject: Re: [PATCH 05/11] fuse: Trust kernel i_mtime only -v2
Date: Mon, 20 Jan 2014 15:33:37 +0400	[thread overview]
Message-ID: <52DD0991.2000905@parallels.com> (raw)
In-Reply-To: <20140106162242.GE16230@tucsk.piliscsaba.szeredi.hu>

On 01/06/2014 08:22 PM, Miklos Szeredi wrote:
> On Thu, Dec 26, 2013 at 07:41:41PM +0400, Maxim Patlasov wrote:
>>>> +
>>>> +	if (!err)
>>>> +		clear_bit(FUSE_I_MTIME_DIRTY, &fi->state);
>>> Doing the test and the clear separately opens a huge race window when i_mtime
>>> modifications are bound to get lost.
>> No. Because the whole operation is protected by i_mutex (see
>> fuse_fsync_common()).
> fuse_release_common() doesn't have i_mutex.  It's probably safe to acquire it,
> but is that really needed?

No, that's not needed, I think. Because by the time of calling 
fuse_release(), file->f_count is already zero and no userspace activity 
is possible on the file.

Are you OK about -v3 version of the patch (sent 12/26/2013)?

Thanks,
Maxim

>
> Thanks,
> Miklos
>

  reply	other threads:[~2014-01-20 11:33 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-10 13:09 [PATCH v6 00/11] fuse: An attempt to implement a write-back cache policy Maxim Patlasov
2013-10-10 13:10 ` [PATCH 01/11] fuse: Linking file to inode helper Maxim Patlasov
2013-10-10 13:10 ` [PATCH 02/11] fuse: Prepare to handle short reads Maxim Patlasov
2013-10-10 13:10 ` [PATCH 03/11] fuse: Connection bit for enabling writeback Maxim Patlasov
2013-10-10 13:10 ` [PATCH 04/11] fuse: Trust kernel i_size only - v4 Maxim Patlasov
     [not found] ` <20131010130718.10089.6736.stgit-opBMJL+S1+lZ2WjqXT1pg9yJl3JzOD/t@public.gmane.org>
2013-10-10 13:10   ` [PATCH 05/11] fuse: Trust kernel i_mtime only -v2 Maxim Patlasov
2013-11-12 16:52     ` Miklos Szeredi
2013-12-26 15:41       ` Maxim Patlasov
2014-01-06 16:22         ` Miklos Szeredi
2014-01-20 11:33           ` Maxim Patlasov [this message]
2013-12-26 15:51       ` [PATCH 05/11] fuse: Trust kernel i_mtime only -v3 Maxim Patlasov
2013-10-10 13:11 ` [PATCH 06/11] fuse: Flush files on wb close -v2 Maxim Patlasov
     [not found]   ` <20131010131102.10089.51081.stgit-opBMJL+S1+lZ2WjqXT1pg9yJl3JzOD/t@public.gmane.org>
2013-10-10 13:19     ` [PATCH] " Maxim Patlasov
2013-10-10 13:11 ` [PATCH 07/11] fuse: restructure fuse_readpage() Maxim Patlasov
2013-11-12 17:17   ` Miklos Szeredi
2013-12-20 14:54     ` Maxim Patlasov
2014-01-06 16:43       ` Miklos Szeredi
2014-01-20 11:46         ` Maxim Patlasov
2013-10-10 13:11 ` [PATCH 08/11] fuse: Implement write_begin/write_end callbacks -v2 Maxim Patlasov
2013-10-10 13:11 ` [PATCH 09/11] fuse: fuse_flush() should wait on writeback Maxim Patlasov
2013-10-10 13:12 ` [PATCH 10/11] fuse: Fix O_DIRECT operations vs cached writeback misorder - v2 Maxim Patlasov
2013-10-10 13:12 ` [PATCH 11/11] fuse: Turn writeback cache on Maxim Patlasov
     [not found] ` <87li13pido.fsf@vostro.rath.org>
     [not found]   ` <CAJfpegvFFXPuEoXXXJCBLEQi+T3mx95g4X+MjxAbyg0rhjbfDA@mail.gmail.com>
     [not found]     ` <528321C3.20307@parallels.com>
     [not found]       ` <CAJfpegu_ScgdgHDVM_5GMQC86OFnpXLDsuArKbWP_cX-D8m8Jw@mail.gmail.com>
     [not found]         ` <52FA4ECD.2030608@parallels.com>
     [not found]           ` <52FC2DE5.9010008@rath.org>
     [not found]             ` <52FCB029.9040608@parallels.com>
     [not found]               ` <87wqgwdvi1.fsf@vostro.rath.org>
2014-02-27 15:33                 ` fuse write performance Miklos Szeredi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52DD0991.2000905@parallels.com \
    --to=mpatlasov@parallels.com \
    --cc=akpm@linux-foundation.org \
    --cc=bfoster@redhat.com \
    --cc=dev@parallels.com \
    --cc=devel@openvz.org \
    --cc=fengguang.wu@intel.com \
    --cc=fuse-devel@lists.sourceforge.net \
    --cc=jbottomley@parallels.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=miklos@szeredi.hu \
    --cc=xemul@parallels.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).