Message ID | 20220805063214.32432-2-andrea.righi@canonical.com |
---|---|
State | New |
Headers | show |
Series | [J] UBUNTU: SAUCE: overlayfs: remove CONFIG_AUFS_FS dependency | expand |
On Fri, 5 Aug 2022 08:32:10 +0200 Andrea Righi <andrea.righi@canonical.com> wrote: > From: Alexander Mikhalitsyn <alexander.mikhalitsyn@virtuozzo.com> > > BugLink: https://bugs.launchpad.net/bugs/1983640 > > Right now we have a fix: > b07bc17b ("UBUNTU: SAUCE: overlayfs: fix incorrect mnt_id of files opened from map_files") > in master branch of Jammy kernel, but only formaly. Because these kernels compiled without > CONFIG_AUFS_FS set, so this fix just disabled. There is no need to make it dependent on > CONFIG_AUFS_FS option, because in all cases we have mm/prfile.c compiled-in. > > Fixes: b07bc17b ("UBUNTU: SAUCE: overlayfs: fix incorrect mnt_id of files opened from map_files") > Signed-off-by: Alexander Mikhalitsyn <alexander.mikhalitsyn@virtuozzo.com> > Signed-off-by: Andrea Righi <andrea.righi@canonical.com> > --- > fs/overlayfs/file.c | 7 ------- > 1 file changed, 7 deletions(-) > > diff --git a/fs/overlayfs/file.c b/fs/overlayfs/file.c > index 2e4ebebdb7d1..7024771dcae8 100644 > --- a/fs/overlayfs/file.c > +++ b/fs/overlayfs/file.c > @@ -490,7 +490,6 @@ static int ovl_fsync(struct file *file, loff_t start, loff_t end, int datasync) > return ret; > } > > -#if IS_ENABLED(CONFIG_AUFS_FS) > /* > * In map_files_get_link() (fs/proc/base.c) > * we need to determine correct path from overlayfs. > @@ -516,12 +515,6 @@ static void ovl_vm_prfile_set(struct vm_area_struct *vma, > vma->vm_region->vm_prfile = file; > #endif > } > -#else /* !CONFIG_AUFS_FS */ > -static void ovl_vm_prfile_set(struct vm_area_struct *vma, > - struct file *file) > -{ > -} > -#endif/* CONFIG_AUFS_FS */ > > static int ovl_mmap(struct file *file, struct vm_area_struct *vma) > { > -- > 2.34.1 > Hi Andrea, I'm sorry for pinging you. Do you have any plan to apply this to jammy/linux? As I can see master/master-next/master-prep branches lacks of this fix: https://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/jammy/tree/fs/overlayfs/file.c?h=master-next#n524 Best regards, Alex
On 22.08.22 12:34, Alexander Mikhalitsyn wrote: > On Fri, 5 Aug 2022 08:32:10 +0200 > Andrea Righi <andrea.righi@canonical.com> wrote: > >> From: Alexander Mikhalitsyn <alexander.mikhalitsyn@virtuozzo.com> >> >> BugLink: https://bugs.launchpad.net/bugs/1983640 >> >> Right now we have a fix: >> b07bc17b ("UBUNTU: SAUCE: overlayfs: fix incorrect mnt_id of files opened from map_files") >> in master branch of Jammy kernel, but only formaly. Because these kernels compiled without >> CONFIG_AUFS_FS set, so this fix just disabled. There is no need to make it dependent on >> CONFIG_AUFS_FS option, because in all cases we have mm/prfile.c compiled-in. >> >> Fixes: b07bc17b ("UBUNTU: SAUCE: overlayfs: fix incorrect mnt_id of files opened from map_files") >> Signed-off-by: Alexander Mikhalitsyn <alexander.mikhalitsyn@virtuozzo.com> >> Signed-off-by: Andrea Righi <andrea.righi@canonical.com> >> --- >> fs/overlayfs/file.c | 7 ------- >> 1 file changed, 7 deletions(-) >> >> diff --git a/fs/overlayfs/file.c b/fs/overlayfs/file.c >> index 2e4ebebdb7d1..7024771dcae8 100644 >> --- a/fs/overlayfs/file.c >> +++ b/fs/overlayfs/file.c >> @@ -490,7 +490,6 @@ static int ovl_fsync(struct file *file, loff_t start, loff_t end, int datasync) >> return ret; >> } >> >> -#if IS_ENABLED(CONFIG_AUFS_FS) >> /* >> * In map_files_get_link() (fs/proc/base.c) >> * we need to determine correct path from overlayfs. >> @@ -516,12 +515,6 @@ static void ovl_vm_prfile_set(struct vm_area_struct *vma, >> vma->vm_region->vm_prfile = file; >> #endif >> } >> -#else /* !CONFIG_AUFS_FS */ >> -static void ovl_vm_prfile_set(struct vm_area_struct *vma, >> - struct file *file) >> -{ >> -} >> -#endif/* CONFIG_AUFS_FS */ >> >> static int ovl_mmap(struct file *file, struct vm_area_struct *vma) >> { >> -- >> 2.34.1 >> > > Hi Andrea, > > I'm sorry for pinging you. Do you have any plan to apply this to jammy/linux? > As I can see master/master-next/master-prep branches lacks of this fix: > https://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/jammy/tree/fs/overlayfs/file.c?h=master-next#n524 > > Best regards, > Alex > Hi Alex, we will, there is a bit of a backlog but hopefully somewhen this week it should show up. -Stefan
On Mon, 22 Aug 2022 15:48:55 +0200 Stefan Bader <stefan.bader@canonical.com> wrote: > On 22.08.22 12:34, Alexander Mikhalitsyn wrote: > > On Fri, 5 Aug 2022 08:32:10 +0200 > > Andrea Righi <andrea.righi@canonical.com> wrote: > > > >> From: Alexander Mikhalitsyn <alexander.mikhalitsyn@virtuozzo.com> > >> > >> BugLink: https://bugs.launchpad.net/bugs/1983640 > >> > >> Right now we have a fix: > >> b07bc17b ("UBUNTU: SAUCE: overlayfs: fix incorrect mnt_id of files opened from map_files") > >> in master branch of Jammy kernel, but only formaly. Because these kernels compiled without > >> CONFIG_AUFS_FS set, so this fix just disabled. There is no need to make it dependent on > >> CONFIG_AUFS_FS option, because in all cases we have mm/prfile.c compiled-in. > >> > >> Fixes: b07bc17b ("UBUNTU: SAUCE: overlayfs: fix incorrect mnt_id of files opened from map_files") > >> Signed-off-by: Alexander Mikhalitsyn <alexander.mikhalitsyn@virtuozzo.com> > >> Signed-off-by: Andrea Righi <andrea.righi@canonical.com> > >> --- > >> fs/overlayfs/file.c | 7 ------- > >> 1 file changed, 7 deletions(-) > >> > >> diff --git a/fs/overlayfs/file.c b/fs/overlayfs/file.c > >> index 2e4ebebdb7d1..7024771dcae8 100644 > >> --- a/fs/overlayfs/file.c > >> +++ b/fs/overlayfs/file.c > >> @@ -490,7 +490,6 @@ static int ovl_fsync(struct file *file, loff_t start, loff_t end, int datasync) > >> return ret; > >> } > >> > >> -#if IS_ENABLED(CONFIG_AUFS_FS) > >> /* > >> * In map_files_get_link() (fs/proc/base.c) > >> * we need to determine correct path from overlayfs. > >> @@ -516,12 +515,6 @@ static void ovl_vm_prfile_set(struct vm_area_struct *vma, > >> vma->vm_region->vm_prfile = file; > >> #endif > >> } > >> -#else /* !CONFIG_AUFS_FS */ > >> -static void ovl_vm_prfile_set(struct vm_area_struct *vma, > >> - struct file *file) > >> -{ > >> -} > >> -#endif/* CONFIG_AUFS_FS */ > >> > >> static int ovl_mmap(struct file *file, struct vm_area_struct *vma) > >> { > >> -- > >> 2.34.1 > >> > > > > Hi Andrea, > > > > I'm sorry for pinging you. Do you have any plan to apply this to jammy/linux? > > As I can see master/master-next/master-prep branches lacks of this fix: > > https://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/jammy/tree/fs/overlayfs/file.c?h=master-next#n524 > > > > Best regards, > > Alex > > > Hi Alex, Hi Stefan, fantastic! Thanks! ;-) Regards, Alex > > we will, there is a bit of a backlog but hopefully somewhen this week it should > show up. > > -Stefan
On 05.08.22 08:32, Andrea Righi wrote: > From: Alexander Mikhalitsyn <alexander.mikhalitsyn@virtuozzo.com> > > BugLink: https://bugs.launchpad.net/bugs/1983640 > > Right now we have a fix: > b07bc17b ("UBUNTU: SAUCE: overlayfs: fix incorrect mnt_id of files opened from map_files") > in master branch of Jammy kernel, but only formaly. Because these kernels compiled without > CONFIG_AUFS_FS set, so this fix just disabled. There is no need to make it dependent on > CONFIG_AUFS_FS option, because in all cases we have mm/prfile.c compiled-in. > > Fixes: b07bc17b ("UBUNTU: SAUCE: overlayfs: fix incorrect mnt_id of files opened from map_files") > Signed-off-by: Alexander Mikhalitsyn <alexander.mikhalitsyn@virtuozzo.com> > Signed-off-by: Andrea Righi <andrea.righi@canonical.com> > --- Applied to jammy:linux/master-next. Thanks. -Stefan > fs/overlayfs/file.c | 7 ------- > 1 file changed, 7 deletions(-) > > diff --git a/fs/overlayfs/file.c b/fs/overlayfs/file.c > index 2e4ebebdb7d1..7024771dcae8 100644 > --- a/fs/overlayfs/file.c > +++ b/fs/overlayfs/file.c > @@ -490,7 +490,6 @@ static int ovl_fsync(struct file *file, loff_t start, loff_t end, int datasync) > return ret; > } > > -#if IS_ENABLED(CONFIG_AUFS_FS) > /* > * In map_files_get_link() (fs/proc/base.c) > * we need to determine correct path from overlayfs. > @@ -516,12 +515,6 @@ static void ovl_vm_prfile_set(struct vm_area_struct *vma, > vma->vm_region->vm_prfile = file; > #endif > } > -#else /* !CONFIG_AUFS_FS */ > -static void ovl_vm_prfile_set(struct vm_area_struct *vma, > - struct file *file) > -{ > -} > -#endif/* CONFIG_AUFS_FS */ > > static int ovl_mmap(struct file *file, struct vm_area_struct *vma) > {
diff --git a/fs/overlayfs/file.c b/fs/overlayfs/file.c index 2e4ebebdb7d1..7024771dcae8 100644 --- a/fs/overlayfs/file.c +++ b/fs/overlayfs/file.c @@ -490,7 +490,6 @@ static int ovl_fsync(struct file *file, loff_t start, loff_t end, int datasync) return ret; } -#if IS_ENABLED(CONFIG_AUFS_FS) /* * In map_files_get_link() (fs/proc/base.c) * we need to determine correct path from overlayfs. @@ -516,12 +515,6 @@ static void ovl_vm_prfile_set(struct vm_area_struct *vma, vma->vm_region->vm_prfile = file; #endif } -#else /* !CONFIG_AUFS_FS */ -static void ovl_vm_prfile_set(struct vm_area_struct *vma, - struct file *file) -{ -} -#endif/* CONFIG_AUFS_FS */ static int ovl_mmap(struct file *file, struct vm_area_struct *vma) {