Documentation/filesystems/vfs.txt: document how ->i_link works
authorEric Biggers <ebiggers@google.com>
Thu, 11 Apr 2019 23:16:28 +0000 (16:16 -0700)
committerAl Viro <viro@zeniv.linux.org.uk>
Wed, 1 May 2019 03:59:25 +0000 (23:59 -0400)
Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Documentation/filesystems/vfs.txt

index 33120f220f86f3aa6a531a0d8ea6c2fdc4dddc4d..57fc576b1f3eacc27cb2a4d4e23075605fae950f 100644 (file)
@@ -463,6 +463,12 @@ otherwise noted.
        argument.  If request can't be handled without leaving RCU mode,
        have it return ERR_PTR(-ECHILD).
 
+       If the filesystem stores the symlink target in ->i_link, the
+       VFS may use it directly without calling ->get_link(); however,
+       ->get_link() must still be provided.  ->i_link must not be
+       freed until after an RCU grace period.  Writing to ->i_link
+       post-iget() time requires a 'release' memory barrier.
+
   readlink: this is now just an override for use by readlink(2) for the
        cases when ->get_link uses nd_jump_link() or object is not in
        fact a symlink.  Normally filesystems should only implement