mirror of
				https://github.com/torvalds/linux.git
				synced 2025-11-04 10:40:15 +02:00 
			
		
		
		
	ovl: support idmapped layers
Now that overlay is able to take a layers idmapping into account allow overlay mounts to be created on top of idmapped mounts. Cc: <linux-unionfs@vger.kernel.org> Tested-by: Giuseppe Scrivano <gscrivan@redhat.com> Reviewed-by: Amir Goldstein <amir73il@gmail.com> Signed-off-by: Christian Brauner (Microsoft) <brauner@kernel.org> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
This commit is contained in:
		
							parent
							
								
									8bc0095df6
								
							
						
					
					
						commit
						bc70682a49
					
				
					 2 changed files with 1 additions and 5 deletions
				
			
		| 
						 | 
					@ -92,7 +92,7 @@ static inline struct vfsmount *ovl_upper_mnt(struct ovl_fs *ofs)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
static inline struct user_namespace *ovl_upper_mnt_userns(struct ovl_fs *ofs)
 | 
					static inline struct user_namespace *ovl_upper_mnt_userns(struct ovl_fs *ofs)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	return &init_user_ns;
 | 
						return mnt_user_ns(ovl_upper_mnt(ofs));
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
static inline struct ovl_fs *OVL_FS(struct super_block *sb)
 | 
					static inline struct ovl_fs *OVL_FS(struct super_block *sb)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -874,10 +874,6 @@ static int ovl_mount_dir_noesc(const char *name, struct path *path)
 | 
				
			||||||
		pr_err("filesystem on '%s' not supported\n", name);
 | 
							pr_err("filesystem on '%s' not supported\n", name);
 | 
				
			||||||
		goto out_put;
 | 
							goto out_put;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
	if (is_idmapped_mnt(path->mnt)) {
 | 
					 | 
				
			||||||
		pr_err("idmapped layers are currently not supported\n");
 | 
					 | 
				
			||||||
		goto out_put;
 | 
					 | 
				
			||||||
	}
 | 
					 | 
				
			||||||
	if (!d_is_dir(path->dentry)) {
 | 
						if (!d_is_dir(path->dentry)) {
 | 
				
			||||||
		pr_err("'%s' not a directory\n", name);
 | 
							pr_err("'%s' not a directory\n", name);
 | 
				
			||||||
		goto out_put;
 | 
							goto out_put;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue