ovl: implement tmpfile
authorMiklos Szeredi <mszeredi@redhat.com>
Thu, 2 May 2024 18:35:57 +0000 (20:35 +0200)
committerMiklos Szeredi <mszeredi@redhat.com>
Thu, 2 May 2024 18:35:57 +0000 (20:35 +0200)
commit9a87907de3597a339cc129229d1a20bc7365ea5f
treea3a6e2b3784ee2e895ceb5668ca5bb1de754b1fa
parented30a4a51bb196781c8058073ea720133a65596f
ovl: implement tmpfile

Combine inode creation with opening a file.

There are six separate objects that are being set up: the backing inode,
dentry and file, and the overlay inode, dentry and file.  Cleanup in case
of an error is a bit of a challenge and is difficult to test, so careful
review is needed.

All tmpfile testcases except generic/509 now run/pass, and no regressions
are observed with full xfstests.

Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Reviewed-by: Amir Goldstein <amir73il@gmail.com>
fs/backing-file.c
fs/internal.h
fs/namei.c
fs/overlayfs/dir.c
fs/overlayfs/file.c
fs/overlayfs/overlayfs.h
include/linux/backing-file.h