From 29486df325e1fe6e1764afcb19e3370804c2b002 Mon Sep 17 00:00:00 2001 From: "Serge E. Hallyn" Date: Tue, 29 Apr 2008 01:00:14 -0700 Subject: cgroups: introduce cft->read_seq() Introduce a read_seq() helper in cftype, which uses seq_file to print out lists. Use it in the devices cgroup. Also split devices.allow into two files, so now devices.deny and devices.allow are the ones to use to manipulate the whitelist, while devices.list outputs the cgroup's current whitelist. Signed-off-by: Serge E. Hallyn Acked-by: Paul Menage Cc: Balbir Singh Cc: KAMEZAWA Hiroyuki Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/cgroup.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include/linux/cgroup.h') diff --git a/include/linux/cgroup.h b/include/linux/cgroup.h index d58a958..0952480 100644 --- a/include/linux/cgroup.h +++ b/include/linux/cgroup.h @@ -226,6 +226,12 @@ struct cftype { */ int (*read_map) (struct cgroup *cont, struct cftype *cft, struct cgroup_map_cb *cb); + /* + * read_seq_string() is used for outputting a simple sequence + * using seqfile. + */ + int (*read_seq_string) (struct cgroup *cont, struct cftype *cft, + struct seq_file *m); ssize_t (*write) (struct cgroup *cgrp, struct cftype *cft, struct file *file, -- cgit v1.1