[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20151223161526.GG5003@mtj.duckdns.org>
Date: Wed, 23 Dec 2015 11:15:26 -0500
From: Tejun Heo <tj@...nel.org>
To: serge.hallyn@...ntu.com
Cc: linux-kernel@...r.kernel.org, adityakali@...gle.com,
linux-api@...r.kernel.org, containers@...ts.linux-foundation.org,
cgroups@...r.kernel.org, lxc-devel@...ts.linuxcontainers.org,
akpm@...ux-foundation.org, ebiederm@...ssion.com,
gregkh@...uxfoundation.org, lizefan@...wei.com, hannes@...xchg.org,
Serge Hallyn <serge.hallyn@...onical.com>
Subject: Re: [PATCH 3/8] cgroup: introduce cgroup namespaces
Hello,
On Tue, Dec 22, 2015 at 10:23:24PM -0600, serge.hallyn@...ntu.com wrote:
...
> +char *cgroup_path(struct cgroup *cgrp, char *buf, size_t buflen)
> +{
> + int ret;
> +
> + ret = cgroup_path_ns(cgrp, buf, buflen, current->nsproxy->cgroup_ns);
> + if (ret < 0 || ret >= buflen)
> + return NULL;
> + return buf;
> +}
> +EXPORT_SYMBOL_GPL(cgroup_path);
Shouldn't this function check whether it's being called from a task
context? e.g. it could be being called from an irq handler and may
end up scoping the path incorrectly.
Thanks.
--
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists