diff options
author | Dhaval Giani <dhaval@linux.vnet.ibm.com> | 2009-06-26 23:06:18 +0530 |
---|---|---|
committer | Dhaval Giani <dhaval@linux.vnet.ibm.com> | 2009-06-26 23:06:18 +0530 |
commit | 305fdb705e4eca50f3dc18d7cc685b547ce0ee98 (patch) | |
tree | 492943020ca7fd7d7756aaab80434571785e8eca /include | |
parent | 3c60aa98093e94985fb3fe43c03bb91a5e6b45c6 (diff) | |
download | libcg-305fdb705e4eca50f3dc18d7cc685b547ce0ee98.tar.gz libcg-305fdb705e4eca50f3dc18d7cc685b547ce0ee98.tar.xz libcg-305fdb705e4eca50f3dc18d7cc685b547ce0ee98.zip |
libcgroup: Introduce an API to get the mount point of a specific subsystem
Introduce an API which will query the mount table and return the mount point
of a specific subsystem. This is needed in the case when the user knows which
subsystem he wants the details of, which would make the use of the get_controller*
APIs cumbersome.
Signed-off-by: Dhaval Giani <dhaval@linux.vnet.ibm.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/libcgroup.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/libcgroup.h b/include/libcgroup.h index ce0d8a5..9bc74d6 100644 --- a/include/libcgroup.h +++ b/include/libcgroup.h @@ -324,6 +324,15 @@ int cgroup_get_controller_begin(void **handle, struct cgroup_mount_point *info); */ int cgroup_get_controller_next(void **handle, struct cgroup_mount_point *info); int cgroup_get_controller_end(void **handle); + +/* + * Reads the mount to table to give the mount point of a controller + * @controller: Name of the controller + * @mount_point: The string where the mount point is stored. Please note, + * the caller must free mount_point. + */ +int cgroup_get_subsys_mount_point(char *controller, char **mount_point); + /* The wrappers for filling libcg structures */ struct cgroup *cgroup_new_cgroup(const char *name); |