summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAmir Goldstein <amir73il@gmail.com>2018-05-15 11:57:28 +0300
committerMiklos Szeredi <mszeredi@redhat.com>2018-05-31 11:06:10 +0200
commita8b9e0ceed3214d0b9da211f39004931ec1d2a1b (patch)
tree79ed16fbd3038434a43061a211e72abab53a5c38
parent4280f74a577dfbfac83e9ab38e7113ea3102a2eb (diff)
downloadlinux-a8b9e0ceed3214d0b9da211f39004931ec1d2a1b.tar.gz
linux-a8b9e0ceed3214d0b9da211f39004931ec1d2a1b.tar.bz2
linux-a8b9e0ceed3214d0b9da211f39004931ec1d2a1b.zip
ovl: remove WARN_ON() real inode attributes mismatch
Overlayfs should cope with online changes to underlying layer without crashing the kernel, which is what xfstest overlay/019 checks. This test may sometimes trigger WARN_ON() in ovl_create_or_link() when linking an overlay inode that has been changed on underlying layer. Remove those WARN_ON() to prevent the stress test from failing. Signed-off-by: Amir Goldstein <amir73il@gmail.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
-rw-r--r--fs/overlayfs/dir.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/fs/overlayfs/dir.c b/fs/overlayfs/dir.c
index 839709c7803a..01902adc7153 100644
--- a/fs/overlayfs/dir.c
+++ b/fs/overlayfs/dir.c
@@ -510,13 +510,6 @@ static int ovl_create_or_link(struct dentry *dentry, struct inode *inode,
}
out_revert_creds:
revert_creds(old_cred);
- if (!err) {
- struct inode *realinode = d_inode(ovl_dentry_upper(dentry));
-
- WARN_ON(inode->i_mode != realinode->i_mode);
- WARN_ON(!uid_eq(inode->i_uid, realinode->i_uid));
- WARN_ON(!gid_eq(inode->i_gid, realinode->i_gid));
- }
return err;
}