tools/sched_ext: Add missing -d option in scx_flatcg
PATCH 1/1 tools/sched_ext: Add missing -d option in scx_flatcg
Add missing -d option to help_fmt to reflect the capability.
--- tools/sched_ext/scx_flatcg.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
tools/sched_ext/scx_flatcg.c +2 -1
@@ -27,10 +27,11 @@ const char help_fmt[] ="\n" "See the top-level comment in .bpf.c for more details.\n" "\n" -"Usage: %s [-s SLICE_US] [-i INTERVAL] [-f] [-v]\n" +"Usage: %s [-s SLICE_US] [-i INTERVAL] [-d] [-f] [-v]\n" "\n" " -s SLICE_US Override slice duration\n" " -i INTERVAL Report interval\n" +" -d Dump cgroup hierarchy on start\n" " -f Use FIFO scheduling instead of weighted vtime scheduling\n" " -v Print libbpf debug messages\n" " -h Display this help and exit\n" ;
Signature · 1 line
2.48.1
Tejun Heo
reviewerHello,
-d is dead code - it just sets dump_cgrps which is only echoed in the status-line printf, nothing actually dumps the cgroup hierarchy. The right thing to do is remove the whole thing - the 'd' in getopt(), case 'd':, the dump_cgrps variable and its printf - rather than document dead code as a feature.
Want to spin a removal patch?
Thanks.
Signature · 1 line
tejun
Hi Tejun,
Quoted 7 lines · Tejun Heo
-d is dead code - it just sets
dump_cgrpswhich is only echoed in the status-line printf, nothing actually dumps the cgroup hierarchy. The right thing to do is remove the whole thing - the 'd' ingetopt(), case 'd':, thedump_cgrpsvariable and its printf - rather than document dead code as a feature.Want to spin a removal patch?
Yeah, for sure! Thanks for the explanation, will do!
Signature · 2 lines
Cheers, Cheng-Yang