From ce2c1c20f7b49d7df5ea076c0d36f6693aa3484b Mon Sep 17 00:00:00 2001 From: Benno Schulenberg Date: Mon, 31 Mar 2025 11:44:38 +0200 Subject: [PATCH] irqtop: improve several more option descriptions, and align them all Keep at least two spaces between option+argument and its description, while making sure not to go above 80 columns per line. Also, improve the docstring (there is no need to mention that irqtop is a utility) and remove the ugly Q from the list of interactive keys. CC: Joe Jin CC: Zhenwei Pi Signed-off-by: Benno Schulenberg --- sys-utils/irqtop.1.adoc | 4 ++-- sys-utils/irqtop.c | 26 +++++++++++++------------- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/sys-utils/irqtop.1.adoc b/sys-utils/irqtop.1.adoc index 04158a0ef..cf258d085 100644 --- a/sys-utils/irqtop.1.adoc +++ b/sys-utils/irqtop.1.adoc @@ -8,7 +8,7 @@ == NAME -irqtop - utility to display kernel interrupt information +irqtop - display kernel interrupt information == SYNOPSIS @@ -16,7 +16,7 @@ irqtop - utility to display kernel interrupt information == DESCRIPTION -Display kernel interrupt counter information in *top*(1) style view. +Display interrupt-counter information from the kernel in the style of *top*(1). The default output is subject to change. So whenever possible, you should avoid using default outputs in your scripts. Always explicitly define expected columns by using *--output*. diff --git a/sys-utils/irqtop.c b/sys-utils/irqtop.c index e0abddd82..3dbd030e0 100644 --- a/sys-utils/irqtop.c +++ b/sys-utils/irqtop.c @@ -303,28 +303,28 @@ static void __attribute__((__noreturn__)) usage(void) printf(_(" %s [options]\n"), program_invocation_short_name); fputs(USAGE_SEPARATOR, stdout); - puts(_("Interactive utility to display kernel interrupt information.")); + puts(_("Display kernel interrupt information.")); fputs(USAGE_OPTIONS, stdout); - fputs(_(" -b, --batch send tables to stdout, not to a static screen\n"), stdout); - fputs(_(" -c, --cpu-stat show per-cpu stat (auto, enable, disable)\n"), stdout); - fputs(_(" -C, --cpu-list specify cpus in list format\n"), stdout); - fputs(_(" -d, --delay wait this number of seconds between updates\n"), stdout); - fputs(_(" -J, --json use JSON output format (implies --batch)\n"), stdout); - fputs(_(" -n, --iter the maximum number of iterations\n"), stdout); - fputs(_(" -o, --output define which output columns to use\n"), stdout); - fputs(_(" -s, --sort specify sort column\n"), stdout); - fputs(_(" -S, --softirq show softirqs instead of interrupts\n"), stdout); - fputs(_(" -t, --threshold only IRQs with counters above \n"), stdout); + fputs(_(" -b, --batch send tables to stdout, not to a static screen\n"), stdout); + fputs(_(" -c, --cpu-stat whether to show the per-cpu stats (auto|enable|disable)\n"), stdout); + fputs(_(" -C, --cpu-list show IRQs only for the specified cpus\n"), stdout); + fputs(_(" -d, --delay wait this number of seconds between updates\n"), stdout); + fputs(_(" -J, --json use JSON output format (implies --batch)\n"), stdout); + fputs(_(" -n, --iter the maximum number of iterations\n"), stdout); + fputs(_(" -o, --output which columns to show, and in which order\n"), stdout); + fputs(_(" -s, --sort sort the table on this column\n"), stdout); + fputs(_(" -S, --softirq show softirqs instead of interrupts\n"), stdout); + fputs(_(" -t, --threshold show only IRQs with counters above this number\n"), stdout); fputs(USAGE_SEPARATOR, stdout); - fprintf(stdout, USAGE_HELP_OPTIONS(22)); + fprintf(stdout, USAGE_HELP_OPTIONS(24)); fputs(_("\nThe following interactive key commands are valid:\n"), stdout); fputs(_(" i sort by IRQ\n"), stdout); fputs(_(" t sort by TOTAL\n"), stdout); fputs(_(" d sort by DELTA\n"), stdout); fputs(_(" n sort by NAME\n"), stdout); - fputs(_(" q Q quit program\n"), stdout); + fputs(_(" q quit program\n"), stdout); fputs(USAGE_COLUMNS, stdout); irq_print_columns(stdout, 0); -- 2.47.2