lkml.org 
[lkml]   [2016]   [Mar]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] cgroup mount: ignore nsroot=
On Wed, Mar 30, 2016 at 12:21:00PM -0500, Serge E. Hallyn wrote:
> As of the patch "cgroup namespaces: add a 'nsroot=' mountinfo field",
> cgroupfs mountinfo output shows 'nsroot='. If userspace like criu
> copy/pastes mount options from there into a new mount command, we should
> ignore it.
>
> Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>

Tested-by: Tycho Andersen <tycho.andersen@canonical.com>

Thanks, Serge.

> ---
> kernel/cgroup.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/kernel/cgroup.c b/kernel/cgroup.c
> index ef0c25d..69fb112 100644
> --- a/kernel/cgroup.c
> +++ b/kernel/cgroup.c
> @@ -1680,6 +1680,10 @@ static int parse_cgroupfs_options(char *data, struct cgroup_sb_opts *opts)
> opts->none = true;
> continue;
> }
> + if (!strncmp(token, "nsroot=", 7)) {
> + /* ignore nsroot= copied from mountinfo */
> + continue;
> + }
> if (!strcmp(token, "all")) {
> /* Mutually exclusive option 'all' + subsystem name */
> if (one_ss)
> --
> 2.7.0
>

\
 
 \ /
  Last update: 2016-03-30 20:21    [W:0.085 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site