aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorPaul Menage <menage@google.com>2008-04-29 04:00:06 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-04-29 11:06:09 -0400
commite73d2c61d1fcbd3621688ae457b49509c8d4c601 (patch)
treee54b1543e786afd036b7884776a6753d8a8973f6 /include/linux
parent418d7d875ce7f33ef0d48d7cc3a95f31302dcf56 (diff)
CGroups _s64 files: add cgroups read_s64/write_s64 file methods
These patches add cgroups read_s64 and write_s64 control file methods (the signed equivalent of read_u64/write_u64) and use them to implement the cpu.rt_runtime_us control file in the CFS cgroup subsystem. This patch: These are the signed equivalents of the read_u64/write_u64 methods Signed-off-by: Paul Menage <menage@google.com> Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/cgroup.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/cgroup.h b/include/linux/cgroup.h
index b40fd5ee9a76..785a01cfb49d 100644
--- a/include/linux/cgroup.h
+++ b/include/linux/cgroup.h
@@ -216,6 +216,10 @@ struct cftype {
216 */ 216 */
217 u64 (*read_u64) (struct cgroup *cgrp, struct cftype *cft); 217 u64 (*read_u64) (struct cgroup *cgrp, struct cftype *cft);
218 /* 218 /*
219 * read_s64() is a signed version of read_u64()
220 */
221 s64 (*read_s64) (struct cgroup *cgrp, struct cftype *cft);
222 /*
219 * read_map() is used for defining a map of key/value 223 * read_map() is used for defining a map of key/value
220 * pairs. It should call cb->fill(cb, key, value) for each 224 * pairs. It should call cb->fill(cb, key, value) for each
221 * entry. The key/value pairs (and their ordering) should not 225 * entry. The key/value pairs (and their ordering) should not
@@ -234,6 +238,10 @@ struct cftype {
234 * userspace. Use in place of write(); return 0 or error. 238 * userspace. Use in place of write(); return 0 or error.
235 */ 239 */
236 int (*write_u64) (struct cgroup *cgrp, struct cftype *cft, u64 val); 240 int (*write_u64) (struct cgroup *cgrp, struct cftype *cft, u64 val);
241 /*
242 * write_s64() is a signed version of write_u64()
243 */
244 int (*write_s64) (struct cgroup *cgrp, struct cftype *cft, s64 val);
237 245
238 int (*release) (struct inode *inode, struct file *file); 246 int (*release) (struct inode *inode, struct file *file);
239}; 247};