linux-hardened/fs/ecryptfs
Miklos Szeredi 1cd66c93ba fs: make remaining filesystems use .rename2
This is trivial to do:

 - add flags argument to foo_rename()
 - check if flags is zero
 - assign foo_rename() to .rename2 instead of .rename

This doesn't mean it's impossible to support RENAME_NOREPLACE for these
filesystems, but it is not trivial, like for local filesystems.
RENAME_NOREPLACE must guarantee atomicity (i.e. it shouldn't be possible
for a file to be created on one host while it is overwritten by rename on
another host).

Filesystems converted:

9p, afs, ceph, coda, ecryptfs, kernfs, lustre, ncpfs, nfs, ocfs2, orangefs.

After this, we can get rid of the duplicate interfaces for rename.

Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Acked-by: David Howells <dhowells@redhat.com> [AFS]
Acked-by: Mike Marshall <hubcap@omnibond.com>
Cc: Eric Van Hensbergen <ericvh@gmail.com>
Cc: Ilya Dryomov <idryomov@gmail.com>
Cc: Jan Harkes <jaharkes@cs.cmu.edu>
Cc: Tyler Hicks <tyhicks@canonical.com>
Cc: Oleg Drokin <oleg.drokin@intel.com>
Cc: Trond Myklebust <trond.myklebust@primarydata.com>
Cc: Mark Fasheh <mfasheh@suse.com>
2016-09-27 11:03:58 +02:00
..
crypto.c ecryptfs: fix spelling mistakes 2016-06-20 10:02:35 -05:00
debug.c eCryptfs: update comment and debug statement 2007-10-16 09:43:11 -07:00
dentry.c eCryptfs: Invalidate dcache entries when lower i_nlink is zero 2015-08-18 17:29:48 -05:00
ecryptfs_kernel.h switch ->setxattr() to passing dentry and inode separately 2016-05-27 20:09:16 -04:00
file.c ecryptfs: don't allow mmap when the lower fs doesn't support it 2016-07-08 10:35:28 -05:00
inode.c fs: make remaining filesystems use .rename2 2016-09-27 11:03:58 +02:00
Kconfig Minor code cleanups and new Kconfig option to disable /dev/ecryptfs 2013-03-07 12:47:24 -08:00
keystore.c mm, fs: get rid of PAGE_CACHE_* and page_cache_{get,release} macros 2016-04-04 10:41:08 -07:00
kthread.c Revert "ecryptfs: forbid opening files without mmap handler" 2016-07-07 18:47:57 -05:00
main.c ecryptfs: drop null test before destroy functions 2016-06-20 10:02:22 -05:00
Makefile eCryptfs: allow userspace messaging to be disabled 2013-03-03 23:59:59 -08:00
messaging.c fs/ecryptfs/messaging.c: remove null test before kfree 2014-07-03 16:38:09 -05:00
miscdev.c ecryptfs: close rmmod race 2013-04-09 14:08:16 -04:00
mmap.c switch ->setxattr() to passing dentry and inode separately 2016-05-27 20:09:16 -04:00
read_write.c mm, fs: get rid of PAGE_CACHE_* and page_cache_{get,release} macros 2016-04-04 10:41:08 -07:00
super.c eCryptfs: Do not allocate hash tfm in NORECLAIM context 2016-04-20 17:50:01 +08:00