[xenial/master-next 1/1] UBUNTU: SAUCE: overlayfs: fix regression in whiteout detection
Andy Whitcroft
apw at canonical.com
Tue Sep 6 12:47:34 UTC 2016
The Ubuntu backport of the below commit necessarily had to follow the
changes to is_ovl_whiteout. In the process the wrong dentry was passed
preventing correct detection of legacy whitouts in a rename over a
whitout on some upper filesystem types (at least ramfs):
commit 11f3710417d026ea2f4fcf362d866342c5274185
Author: Miklos Szeredi <mszeredi at redhat.com>
Date: Mon Mar 21 17:31:44 2016 +0100
ovl: verify upper dentry before unlink and rename
Pass the correct dentry to allow detection of the appropriate whiteout
types.
Fixes: 11f3710417d0 ("ovl: verify upper dentry before unlink and rename") in Ubuntu
BugLink: http://bugs.launchpad.net/bugs/1618572
Signed-off-by: Andy Whitcroft <apw at canonical.com>
---
fs/overlayfs/dir.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/overlayfs/dir.c b/fs/overlayfs/dir.c
index f85f51f..01b6b8a 100644
--- a/fs/overlayfs/dir.c
+++ b/fs/overlayfs/dir.c
@@ -919,7 +919,7 @@ static int ovl_rename2(struct inode *olddir, struct dentry *old,
} else {
new_create = true;
if (!d_is_negative(newdentry) &&
- (!new_opaque || !ovl_is_whiteout(newdentry,ovl_config_legacy(newdentry))))
+ (!new_opaque || !ovl_is_whiteout(newdentry,ovl_config_legacy(new))))
goto out_dput;
}
--
2.9.3
More information about the kernel-team
mailing list