diff options
| author | Alex Shi <alex.shi@linaro.org> | 2016-03-17 12:51:14 +0800 |
|---|---|---|
| committer | Alex Shi <alex.shi@linaro.org> | 2016-03-17 12:51:14 +0800 |
| commit | 6d0b88c88bf58bfd89ffbdaa97b03617fe8c6478 (patch) | |
| tree | 706c149c0f0d6865d14e6b18058826f9dfd49f24 /fs/overlayfs/super.c | |
| parent | 258181e60ef13001b0ae05cb58079fd79ed86a46 (diff) | |
| parent | 0d1912303e54ed1b2a371be0bba51c384dd57326 (diff) | |
Merge tag 'v4.4.6' into linux-linaro-lsk-v4.4
This is the 4.4.6 stable release
Diffstat (limited to 'fs/overlayfs/super.c')
| -rw-r--r-- | fs/overlayfs/super.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/fs/overlayfs/super.c b/fs/overlayfs/super.c index f42c9407fbad..000b2ed05c29 100644 --- a/fs/overlayfs/super.c +++ b/fs/overlayfs/super.c @@ -76,12 +76,14 @@ enum ovl_path_type ovl_path_type(struct dentry *dentry) if (oe->__upperdentry) { type = __OVL_PATH_UPPER; - if (oe->numlower) { - if (S_ISDIR(dentry->d_inode->i_mode)) - type |= __OVL_PATH_MERGE; - } else if (!oe->opaque) { + /* + * Non-dir dentry can hold lower dentry from previous + * location. Its purity depends only on opaque flag. + */ + if (oe->numlower && S_ISDIR(dentry->d_inode->i_mode)) + type |= __OVL_PATH_MERGE; + else if (!oe->opaque) type |= __OVL_PATH_PURE; - } } else { if (oe->numlower > 1) type |= __OVL_PATH_MERGE; @@ -322,6 +324,7 @@ static const struct dentry_operations ovl_dentry_operations = { static const struct dentry_operations ovl_reval_dentry_operations = { .d_release = ovl_dentry_release, + .d_select_inode = ovl_d_select_inode, .d_revalidate = ovl_dentry_revalidate, .d_weak_revalidate = ovl_dentry_weak_revalidate, }; |
