summaryrefslogtreecommitdiff
path: root/fs/overlayfs/ovl_entry.h
diff options
context:
space:
mode:
authorAmir Goldstein <amir73il@gmail.com>2017-11-08 20:23:36 +0300
committerMiklos Szeredi <mszeredi@redhat.com>2018-01-24 12:19:25 +0300
commitd583ed7d138825fd9469d5419e23230ad39173e8 (patch)
tree2da4bca9cba146bedead26fff6355b987a44b858 /fs/overlayfs/ovl_entry.h
parent972d0093c2f7b1bd57e47a1780a552dde528fd16 (diff)
downloadlinux-d583ed7d138825fd9469d5419e23230ad39173e8.tar.xz
ovl: store layer index in ovl_layer
Store the fs root layer index inside ovl_layer struct, so we can get the root fs layer index from merge dir lower layer instead of find it with ovl_find_layer() helper. Signed-off-by: Amir Goldstein <amir73il@gmail.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Diffstat (limited to 'fs/overlayfs/ovl_entry.h')
-rw-r--r--fs/overlayfs/ovl_entry.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/overlayfs/ovl_entry.h b/fs/overlayfs/ovl_entry.h
index 9d0bc03bf6e4..608e48755070 100644
--- a/fs/overlayfs/ovl_entry.h
+++ b/fs/overlayfs/ovl_entry.h
@@ -22,6 +22,8 @@ struct ovl_config {
struct ovl_layer {
struct vfsmount *mnt;
dev_t pseudo_dev;
+ /* Index of this layer in fs root (upper == 0) */
+ int idx;
};
struct ovl_path {