Searched refs:upperdir (Results 1 - 4 of 4) sorted by relevance

/linux-4.1.27/fs/overlayfs/
H A Ddir.c165 struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent); ovl_create_upper() local
166 struct inode *udir = upperdir->d_inode; ovl_create_upper()
171 newdentry = lookup_one_len(dentry->d_name.name, upperdir, ovl_create_upper()
193 struct dentry *upperdir) ovl_lock_rename_workdir()
195 /* Workdir should not be the same as upperdir */ ovl_lock_rename_workdir()
196 if (workdir == upperdir) ovl_lock_rename_workdir()
199 /* Workdir should not be subdir of upperdir and vice versa */ ovl_lock_rename_workdir()
200 if (lock_rename(workdir, upperdir) != NULL) ovl_lock_rename_workdir()
206 unlock_rename(workdir, upperdir); ovl_lock_rename_workdir()
208 pr_err("overlayfs: failed to lock workdir+upperdir\n"); ovl_lock_rename_workdir()
217 struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent); ovl_clear_empty() local
218 struct inode *udir = upperdir->d_inode; ovl_clear_empty()
228 err = ovl_lock_rename_workdir(workdir, upperdir); ovl_clear_empty()
273 unlock_rename(workdir, upperdir); ovl_clear_empty()
285 unlock_rename(workdir, upperdir); ovl_clear_empty()
303 * Can race with copy-up, since we don't hold the upperdir ovl_check_empty_and_clear()
322 struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent); ovl_create_over_whiteout() local
323 struct inode *udir = upperdir->d_inode; ovl_create_over_whiteout()
331 err = ovl_lock_rename_workdir(workdir, upperdir); ovl_create_over_whiteout()
340 upper = lookup_one_len(dentry->d_name.name, upperdir, ovl_create_over_whiteout()
376 unlock_rename(workdir, upperdir); ovl_create_over_whiteout()
508 struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent); ovl_remove_and_whiteout() local
509 struct inode *udir = upperdir->d_inode; ovl_remove_and_whiteout()
539 err = ovl_lock_rename_workdir(workdir, upperdir); ovl_remove_and_whiteout()
550 upper = lookup_one_len(dentry->d_name.name, upperdir, ovl_remove_and_whiteout()
566 if (upper->d_parent != upperdir) ovl_remove_and_whiteout()
584 unlock_rename(workdir, upperdir); ovl_remove_and_whiteout()
597 struct dentry *upperdir = ovl_dentry_upper(dentry->d_parent); ovl_remove_upper() local
598 struct inode *dir = upperdir->d_inode; ovl_remove_upper()
604 if (upper->d_parent == upperdir) { ovl_remove_upper()
192 ovl_lock_rename_workdir(struct dentry *workdir, struct dentry *upperdir) ovl_lock_rename_workdir() argument
H A Dsuper.c32 char *upperdir; member in struct:ovl_config
341 struct dentry *upperdir, *upperdentry = NULL; ovl_lookup() local
349 upperdir = ovl_upperdentry_dereference(poe); ovl_lookup()
350 if (upperdir) { ovl_lookup()
351 this = ovl_lookup_real(upperdir, &dentry->d_name); ovl_lookup()
483 kfree(ufs->config.upperdir); ovl_put_super()
526 if (ufs->config.upperdir) { ovl_show_options()
527 seq_show_option(m, "upperdir", ufs->config.upperdir); ovl_show_options()
559 {OPT_UPPERDIR, "upperdir=%s"},
601 kfree(config->upperdir); ovl_parse_opt()
602 config->upperdir = match_strdup(&args[0]); ovl_parse_opt()
603 if (!config->upperdir) ovl_parse_opt()
628 if (!config->upperdir && config->workdir) { ovl_parse_opt()
790 /* Workdir should not be subdir of upperdir and vice versa */ ovl_workdir_ok()
791 static bool ovl_workdir_ok(struct dentry *workdir, struct dentry *upperdir) ovl_workdir_ok() argument
795 if (workdir != upperdir) { ovl_workdir_ok()
796 ok = (lock_rename(workdir, upperdir) == NULL); ovl_workdir_ok()
797 unlock_rename(workdir, upperdir); ovl_workdir_ok()
854 if (ufs->config.upperdir) { ovl_fill_super()
860 err = ovl_mount_dir(ufs->config.upperdir, &upperpath); ovl_fill_super()
877 pr_err("overlayfs: workdir and upperdir must reside under the same mount\n"); ovl_fill_super()
881 pr_err("overlayfs: workdir and upperdir must be separate subtrees\n"); ovl_fill_super()
897 } else if (!ufs->config.upperdir && stacklen == 1) { ovl_fill_super()
898 pr_err("overlayfs: at least 2 lowerdir are needed while upperdir nonexistent\n"); ovl_fill_super()
923 if (ufs->config.upperdir) { ovl_fill_super()
1024 kfree(ufs->config.upperdir); ovl_fill_super()
H A Dcopy_up.c207 static int ovl_copy_up_locked(struct dentry *workdir, struct dentry *upperdir, ovl_copy_up_locked() argument
213 struct inode *udir = upperdir->d_inode; ovl_copy_up_locked()
224 upper = lookup_one_len(dentry->d_name.name, upperdir, ovl_copy_up_locked()
307 struct dentry *upperdir; ovl_copy_up_one() local
317 upperdir = parentpath.dentry; ovl_copy_up_one()
353 if (lock_rename(workdir, upperdir) != NULL) { ovl_copy_up_one()
354 pr_err("overlayfs: failed to lock workdir+upperdir\n"); ovl_copy_up_one()
359 unlock_rename(workdir, upperdir); ovl_copy_up_one()
370 err = ovl_copy_up_locked(workdir, upperdir, dentry, lowerpath, ovl_copy_up_one()
374 ovl_set_timestamps(upperdir, &pstat); ovl_copy_up_one()
377 unlock_rename(workdir, upperdir); ovl_copy_up_one()
H A Doverlayfs.h158 struct dentry *ovl_upper_create(struct dentry *upperdir, struct dentry *dentry,

Completed in 117 milliseconds