xattr: break delegations in {set,remove}xattr
authorFrank van der Linden <fllinden@amazon.com>
Tue, 23 Jun 2020 22:39:18 +0000 (22:39 +0000)
committerChuck Lever <chuck.lever@oracle.com>
Mon, 13 Jul 2020 21:27:03 +0000 (17:27 -0400)
commit08b5d5014a27e717826999ad20e394a8811aae92
tree9ad6215f9a0716012bf842c10d95e021d79be880
parentc1326210477ecc06c53221f0005c64419aba30d6
xattr: break delegations in {set,remove}xattr

set/removexattr on an exported filesystem should break NFS delegations.
This is true in general, but also for the upcoming support for
RFC 8726 (NFSv4 extended attribute support). Make sure that they do.

Additionally, they need to grow a _locked variant, since callers might
call this with i_rwsem held (like the NFS server code).

Cc: stable@vger.kernel.org # v4.9+
Cc: linux-fsdevel@vger.kernel.org
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Frank van der Linden <fllinden@amazon.com>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
fs/xattr.c
include/linux/xattr.h