diff --git a/kernel/cgroup.c b/kernel/cgroup.c index 3fe01102607b164c1fb47a6be951fe0c02832875..771d1b8aaae98bd9e980b79dc838905e3f023a48 100644 --- a/kernel/cgroup.c +++ b/kernel/cgroup.c @@ -2348,6 +2348,9 @@ int cgroup_add_cftypes(struct cgroup_subsys *ss, struct cftype *cfts) { int ret; + if (!cfts || cfts[0].name[0] == '\0') + return 0; + ret = cgroup_init_cftypes(ss, cfts); if (ret) return ret;