diff options
author | Tejun Heo <tj@kernel.org> | 2012-04-01 21:09:55 +0200 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2012-04-01 21:09:55 +0200 |
commit | 4baf6e33251b37f111e21289f8ee71fe4cce236e (patch) | |
tree | 7decc386a60679fd2696041810cf331c0daf1f41 /security | |
parent | cgroup: relocate cftype and cgroup_subsys definitions in controllers (diff) | |
download | linux-4baf6e33251b37f111e21289f8ee71fe4cce236e.tar.xz linux-4baf6e33251b37f111e21289f8ee71fe4cce236e.zip |
cgroup: convert all non-memcg controllers to the new cftype interface
Convert debug, freezer, cpuset, cpu_cgroup, cpuacct, net_prio, blkio,
net_cls and device controllers to use the new cftype based interface.
Termination entry is added to cftype arrays and populate callbacks are
replaced with cgroup_subsys->base_cftypes initializations.
This is functionally identical transformation. There shouldn't be any
visible behavior change.
memcg is rather special and will be converted separately.
Signed-off-by: Tejun Heo <tj@kernel.org>
Acked-by: Li Zefan <lizf@cn.fujitsu.com>
Cc: Paul Menage <paul@paulmenage.org>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Vivek Goyal <vgoyal@redhat.com>
Diffstat (limited to 'security')
-rw-r--r-- | security/device_cgroup.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/security/device_cgroup.c b/security/device_cgroup.c index c43a3323feea..442204cc22d9 100644 --- a/security/device_cgroup.c +++ b/security/device_cgroup.c @@ -447,22 +447,16 @@ static struct cftype dev_cgroup_files[] = { .read_seq_string = devcgroup_seq_read, .private = DEVCG_LIST, }, + { } /* terminate */ }; -static int devcgroup_populate(struct cgroup_subsys *ss, - struct cgroup *cgroup) -{ - return cgroup_add_files(cgroup, ss, dev_cgroup_files, - ARRAY_SIZE(dev_cgroup_files)); -} - struct cgroup_subsys devices_subsys = { .name = "devices", .can_attach = devcgroup_can_attach, .create = devcgroup_create, .destroy = devcgroup_destroy, - .populate = devcgroup_populate, .subsys_id = devices_subsys_id, + .base_cftypes = dev_cgroup_files, }; int __devcgroup_inode_permission(struct inode *inode, int mask) |