On Oct 19 2016, Miklos Szeredi <miklos-sUDqSbJrdHQHWmgEVkV9KA@xxxxxxxxxxxxxxxx> wrote: > On Wed, Oct 19, 2016 at 10:32 AM, Amir Goldstein <amir73il-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote: >> On Wed, Oct 19, 2016 at 11:01 AM, Miklos Szeredi <miklos-sUDqSbJrdHQHWmgEVkV9KA@xxxxxxxxxxxxxxxx> wrote: >>> On Wed, Oct 19, 2016 at 7:53 AM, Amir Goldstein <amir73il-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote: >>>> On Wed, Oct 19, 2016 at 4:51 AM, Nikolaus Rath <Nikolaus-BTH8mxji4b0@xxxxxxxxxxxxxxxx> wrote: >>> >>>>> Really no one able to clarify the difference between the FUSE invalidate >>>>> and delete dentry requests? >>>> >>>> It may sound strange to you, but I think the documentation is clear enough. >>>> The difference is that in delete case, you *know* that the entry has >>>> been deleted >>>> and in invalidate case, you may not know what happened to the entry. >>>> The specific use cases are implementation specific, but maybe you lost >>>> contact with remote server or maybe the remote protocol imposes a timeout >>>> for validity or maybe you do not have enough information >>>> to figure out if the entry has been deleted and re-created. >>>> Invalidate simply means that you no longer know that the entry is valid. >>> >>> That was the intent, yes. However 'invalidate' + 'lookup negative' >>> should be equivalent to 'delete'. And it is. >>> >>> The reason why 'delete' was introduced by commit 451d0f599934 ("FUSE: >>> Notifying the kernel of deletion.") is that 'invalidate' wasn't able >>> to remove in-use subtrees. >>> >>> Commit bafc9b754f75 ("vfs: More precise tests in d_invalidate") >>> changed that, so now 'notify_delete' is superfluous and AFAICS the >>> effect of it is exactly the same as 'notify_invalidate'. >>> >> >> Minus fsnotify_nameremove() for whatever it is worth. > > Ah, right. But fuse lacks proper fsnotify support for remote fs > anyway, so it's not worth much. Thanks Miklos! So I'll extend the documentation to say that both _invalidate() and _delete() drop the dentry from the cache (so the next lookup attempt) will be passed to the fuse file sysem), but that _delete() will also inform any inotify watchers that the entry has disappeared. Best, -Nikolaus -- GPG encrypted emails preferred. Key id: 0xD113FCAC3C4E599F Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F »Time flies like an arrow, fruit flies like a Banana.« -- 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