mirror of
https://github.com/torvalds/linux.git
synced 2026-01-25 07:47:50 +00:00
ref_tracker: eliminate the ref_tracker_dir name field
Now that we have dentries and the ability to create meaningful symlinks to them, don't keep a name string in each tracker. Switch the output format to print "class@address", and drop the name field. Also, add a kerneldoc header for ref_tracker_dir_init(). Signed-off-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20250618-reftrack-dbgfs-v15-9-24fc37ead144@kernel.org Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
committed by
Jakub Kicinski
parent
8f2079f8da
commit
707bd05be7
@@ -155,7 +155,7 @@ __ref_tracker_dir_pr_ostream(struct ref_tracker_dir *dir,
|
||||
stats = ref_tracker_get_stats(dir, display_limit);
|
||||
if (IS_ERR(stats)) {
|
||||
pr_ostream(s, "%s%s@%p: couldn't get stats, error %pe\n",
|
||||
s->prefix, dir->name, dir, stats);
|
||||
s->prefix, dir->class, dir, stats);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -166,14 +166,14 @@ __ref_tracker_dir_pr_ostream(struct ref_tracker_dir *dir,
|
||||
if (sbuf && !stack_depot_snprint(stack, sbuf, STACK_BUF_SIZE, 4))
|
||||
sbuf[0] = 0;
|
||||
pr_ostream(s, "%s%s@%p has %d/%d users at\n%s\n", s->prefix,
|
||||
dir->name, dir, stats->stacks[i].count,
|
||||
dir->class, dir, stats->stacks[i].count,
|
||||
stats->total, sbuf);
|
||||
skipped -= stats->stacks[i].count;
|
||||
}
|
||||
|
||||
if (skipped)
|
||||
pr_ostream(s, "%s%s@%p skipped reports about %d/%d users.\n",
|
||||
s->prefix, dir->name, dir, skipped, stats->total);
|
||||
s->prefix, dir->class, dir, skipped, stats->total);
|
||||
|
||||
kfree(sbuf);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user