lkml.org 
[lkml]   [2017]   [Jun]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V3 11/12] blktrace: add an option to allow displying cgroup path
Hello,

On Thu, Jun 15, 2017 at 11:17:19AM -0700, Shaohua Li wrote:
> From: Shaohua Li <shli@fb.com>
>
> By default we output cgroup id in blktrace. This adds an option to
> display cgroup path. Since get cgroup path is a relativly heavy
> operation, we don't enable it by default.
>
> with the option enabled, blktrace will output something like this:
> dd-1353 [007] d..2 293.015252: 8,0 /test/level D R 24 + 8 [dd]
>
> Signed-off-by: Shaohua Li <shli@fb.com>
> @@ -613,6 +613,9 @@ static inline struct kernfs_node_id *cgroup_get_node_id(struct cgroup *cgrp)
> {
> return &cgrp->kn->id;
> }
> +
> +void cgroup_path_from_node_id(const struct kernfs_node_id *id,
> + char *buf, size_t buflen);

Maybe cgroup_path_from_kernfs_id()? We eventually can replace
cgrp->id w/ kernfs id and drop the kernfs qualifier.

Thanks.

--
tejun

\
 
 \ /
  Last update: 2017-06-19 21:17    [W:0.254 / U:0.084 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site