diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2018-06-07 08:53:50 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2018-06-07 08:53:50 -0700 |
commit | 70f2ae1f002b0ed4b4382210df8e4b6e54079012 (patch) | |
tree | 113839bf2f25f75f7ca53595149ebe9679aee674 /fs/overlayfs/super.c | |
parent | da315f6e03988a7127680bbc26e1028991b899b8 (diff) | |
parent | 01b39dcc95680b04c7af5de7f39f577e9c4865e3 (diff) | |
download | linux-70f2ae1f002b0ed4b4382210df8e4b6e54079012.tar.gz linux-70f2ae1f002b0ed4b4382210df8e4b6e54079012.tar.bz2 linux-70f2ae1f002b0ed4b4382210df8e4b6e54079012.zip |
Merge tag 'ovl-fixes-4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs
Pull overlayfs fixes from Miklos Szeredi:
"This contains a fix for the vfs_mkdir() issue discovered by Al, as
well as other fixes and cleanups"
* tag 'ovl-fixes-4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs:
ovl: use inode_insert5() to hash a newly created inode
ovl: Pass argument to ovl_get_inode() in a structure
vfs: factor out inode_insert5()
ovl: clean up copy-up error paths
ovl: return EIO on internal error
ovl: make ovl_create_real() cope with vfs_mkdir() safely
ovl: create helper ovl_create_temp()
ovl: return dentry from ovl_create_real()
ovl: struct cattr cleanups
ovl: strip debug argument from ovl_do_ helpers
ovl: remove WARN_ON() real inode attributes mismatch
ovl: Kconfig documentation fixes
ovl: update documentation for unionmount-testsuite
Diffstat (limited to 'fs/overlayfs/super.c')
-rw-r--r-- | fs/overlayfs/super.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/fs/overlayfs/super.c b/fs/overlayfs/super.c index e8551c97de51..704b37311467 100644 --- a/fs/overlayfs/super.c +++ b/fs/overlayfs/super.c @@ -611,11 +611,10 @@ retry: goto retry; } - err = ovl_create_real(dir, work, - &(struct cattr){.mode = S_IFDIR | 0}, - NULL, true); - if (err) - goto out_dput; + work = ovl_create_real(dir, work, OVL_CATTR(attr.ia_mode)); + err = PTR_ERR(work); + if (IS_ERR(work)) + goto out_err; /* * Try to remove POSIX ACL xattrs from workdir. We are good if: |