stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* FAILED: patch "[PATCH] ovl: warn instead of error if d_type is not supported" failed to apply to 4.6-stable tree
@ 2016-07-25  0:18 gregkh
  2016-07-25  9:25 ` Miklos Szeredi
  0 siblings, 1 reply; 3+ messages in thread
From: gregkh @ 2016-07-25  0:18 UTC (permalink / raw)
  To: vgoyal, mszeredi, stable; +Cc: stable


The patch below does not apply to the 4.6-stable tree.
If someone wants it applied there, or to any other stable or longterm
tree, then please email the backport, including the original git commit
id to <stable@vger.kernel.org>.

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

>From e7c0b5991dd1be7b6f6dc2b54a15a0f47b64b007 Mon Sep 17 00:00:00 2001
From: Vivek Goyal <vgoyal@redhat.com>
Date: Fri, 1 Jul 2016 10:02:44 -0400
Subject: [PATCH] ovl: warn instead of error if d_type is not supported

overlay needs underlying fs to support d_type. Recently I put in a
patch in to detect this condition and started failing mount if
underlying fs did not support d_type.

But this breaks existing configurations over kernel upgrade. Those who
are running docker (partially broken configuration) with xfs not
supporting d_type, are surprised that after kernel upgrade docker does
not run anymore.

https://github.com/docker/docker/issues/22937#issuecomment-229881315

So instead of erroring out, detect broken configuration and warn
about it. This should allow existing docker setups to continue
working after kernel upgrade.

Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Fixes: 45aebeaf4f67 ("ovl: Ensure upper filesystem supports d_type")
Cc: <stable@vger.kernel.org> 4.6

diff --git a/fs/overlayfs/super.c b/fs/overlayfs/super.c
index ce02f46029da..9a7693d5f8ff 100644
--- a/fs/overlayfs/super.c
+++ b/fs/overlayfs/super.c
@@ -1082,11 +1082,13 @@ static int ovl_fill_super(struct super_block *sb, void *data, int silent)
 			if (err < 0)
 				goto out_put_workdir;
 
-			if (!err) {
-				pr_err("overlayfs: upper fs needs to support d_type.\n");
-				err = -EINVAL;
-				goto out_put_workdir;
-			}
+			/*
+			 * We allowed this configuration and don't want to
+			 * break users over kernel upgrade. So warn instead
+			 * of erroring out.
+			 */
+			if (!err)
+				pr_warn("overlayfs: upper fs needs to support d_type.\n");
 		}
 	}
 


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: FAILED: patch "[PATCH] ovl: warn instead of error if d_type is not supported" failed to apply to 4.6-stable tree
  2016-07-25  0:18 FAILED: patch "[PATCH] ovl: warn instead of error if d_type is not supported" failed to apply to 4.6-stable tree gregkh
@ 2016-07-25  9:25 ` Miklos Szeredi
  2016-07-25 20:27   ` Greg KH
  0 siblings, 1 reply; 3+ messages in thread
From: Miklos Szeredi @ 2016-07-25  9:25 UTC (permalink / raw)
  To: gregkh; +Cc: Vivek Goyal, stable

On Mon, Jul 25, 2016 at 2:18 AM,  <gregkh@linuxfoundation.org> wrote:
>
> The patch below does not apply to the 4.6-stable tree.
> If someone wants it applied there, or to any other stable or longterm
> tree, then please email the backport, including the original git commit
> id to <stable@vger.kernel.org>.

This depends on the following commit:

21765194cecf ("ovl: Do d_type check only if work dir creation was successful")

Thanks,
Miklos

> ------------------ original commit in Linus's tree ------------------
>
> From e7c0b5991dd1be7b6f6dc2b54a15a0f47b64b007 Mon Sep 17 00:00:00 2001
> From: Vivek Goyal <vgoyal@redhat.com>
> Date: Fri, 1 Jul 2016 10:02:44 -0400
> Subject: [PATCH] ovl: warn instead of error if d_type is not supported
>
> overlay needs underlying fs to support d_type. Recently I put in a
> patch in to detect this condition and started failing mount if
> underlying fs did not support d_type.
>
> But this breaks existing configurations over kernel upgrade. Those who
> are running docker (partially broken configuration) with xfs not
> supporting d_type, are surprised that after kernel upgrade docker does
> not run anymore.
>
> https://github.com/docker/docker/issues/22937#issuecomment-229881315
>
> So instead of erroring out, detect broken configuration and warn
> about it. This should allow existing docker setups to continue
> working after kernel upgrade.
>
> Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
> Fixes: 45aebeaf4f67 ("ovl: Ensure upper filesystem supports d_type")
> Cc: <stable@vger.kernel.org> 4.6
>
> diff --git a/fs/overlayfs/super.c b/fs/overlayfs/super.c
> index ce02f46029da..9a7693d5f8ff 100644
> --- a/fs/overlayfs/super.c
> +++ b/fs/overlayfs/super.c
> @@ -1082,11 +1082,13 @@ static int ovl_fill_super(struct super_block *sb, void *data, int silent)
>                         if (err < 0)
>                                 goto out_put_workdir;
>
> -                       if (!err) {
> -                               pr_err("overlayfs: upper fs needs to support d_type.\n");
> -                               err = -EINVAL;
> -                               goto out_put_workdir;
> -                       }
> +                       /*
> +                        * We allowed this configuration and don't want to
> +                        * break users over kernel upgrade. So warn instead
> +                        * of erroring out.
> +                        */
> +                       if (!err)
> +                               pr_warn("overlayfs: upper fs needs to support d_type.\n");
>                 }
>         }
>
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: FAILED: patch "[PATCH] ovl: warn instead of error if d_type is not supported" failed to apply to 4.6-stable tree
  2016-07-25  9:25 ` Miklos Szeredi
@ 2016-07-25 20:27   ` Greg KH
  0 siblings, 0 replies; 3+ messages in thread
From: Greg KH @ 2016-07-25 20:27 UTC (permalink / raw)
  To: Miklos Szeredi; +Cc: Vivek Goyal, stable

On Mon, Jul 25, 2016 at 11:25:13AM +0200, Miklos Szeredi wrote:
> On Mon, Jul 25, 2016 at 2:18 AM,  <gregkh@linuxfoundation.org> wrote:
> >
> > The patch below does not apply to the 4.6-stable tree.
> > If someone wants it applied there, or to any other stable or longterm
> > tree, then please email the backport, including the original git commit
> > id to <stable@vger.kernel.org>.
> 
> This depends on the following commit:
> 
> 21765194cecf ("ovl: Do d_type check only if work dir creation was successful")

Thanks, that worked.

greg k-h

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-07-25 20:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-25  0:18 FAILED: patch "[PATCH] ovl: warn instead of error if d_type is not supported" failed to apply to 4.6-stable tree gregkh
2016-07-25  9:25 ` Miklos Szeredi
2016-07-25 20:27   ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).