libfuse: document deadlock avoidance for fuse_notify_inval_entry()
authorMiklos Szeredi <mszeredi@suse.cz>
Tue, 15 Jul 2014 09:57:37 +0000 (11:57 +0200)
committerMiklos Szeredi <mszeredi@suse.cz>
Tue, 15 Jul 2014 09:57:37 +0000 (11:57 +0200)
and fuse_notify_delete()

Reported by Han-Wen Nienhuys

ChangeLog
include/fuse_lowlevel.h

index 810059983ff7981a0d970bb9d159766329276fbd..4e7da1daae04a2e6c5720dfdefef1d176f1fe3a8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2014-07-15  Miklos Szeredi <miklos@szeredi.hu>
+
+       * libfuse: document deadlock avoidance for
+       fuse_notify_inval_entry() and fuse_notify_delete()
+
 2014-03-26  Miklos Szeredi <miklos@szeredi.hu>
 
        * Initilaize stat buffer passed to ->getattr() and ->fgetattr() to
index 595f061a5349b81ea0a6bf07ebd476406f957178..31ea87f45184f68c69cb828bb02bc2f8df4debde 100644 (file)
@@ -1401,6 +1401,10 @@ int fuse_lowlevel_notify_inval_inode(struct fuse_chan *ch, fuse_ino_t ino,
  * Notify to invalidate parent attributes and the dentry matching
  * parent/name
  *
+ * To avoid a deadlock don't call this function from a filesystem operation and
+ * don't call it with a lock held that can also be held by a filesystem
+ * operation.
+ *
  * @param ch the channel through which to send the invalidation
  * @param parent inode number
  * @param name file name
@@ -1415,6 +1419,10 @@ int fuse_lowlevel_notify_inval_entry(struct fuse_chan *ch, fuse_ino_t parent,
  * parent/name if the dentry's inode number matches child (otherwise it
  * will invalidate the matching dentry).
  *
+ * To avoid a deadlock don't call this function from a filesystem operation and
+ * don't call it with a lock held that can also be held by a filesystem
+ * operation.
+ *
  * @param ch the channel through which to send the notification
  * @param parent inode number
  * @param child inode number