Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

cgroup: port to ns_ref_*() helpers

Stop accessing ns.count directly.

Acked-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Jan Kara <jack@suse.cz>
Signed-off-by: Christian Brauner <brauner@kernel.org>

+2 -2
+2 -2
include/linux/cgroup_namespace.h
··· 29 29 30 30 static inline void get_cgroup_ns(struct cgroup_namespace *ns) 31 31 { 32 - refcount_inc(&ns->ns.count); 32 + ns_ref_inc(ns); 33 33 } 34 34 35 35 static inline void put_cgroup_ns(struct cgroup_namespace *ns) 36 36 { 37 - if (refcount_dec_and_test(&ns->ns.count)) 37 + if (ns_ref_put(ns)) 38 38 free_cgroup_ns(ns); 39 39 } 40 40