From patchwork Mon Oct 14 12:31:33 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Metin Kaya X-Patchwork-Id: 13834926 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5AFF21A071E for ; Mon, 14 Oct 2024 12:31:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728909109; cv=none; b=DXN5ELuWMROAeXF5V/zTI6weyYp07BKPY1XKtqROEInf9a7UZC7FQuNqmr2hZwfyDRFFkynV1Ct9VxZrUqqCwpB3Yd9L0ADg24hxJ7TtqyjUkJY/a0MTHCIycDGqzTJ+ZHypvaPQZZ25lHx95ZNbcwvxywm1BctIi65YjDeMiho= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728909109; c=relaxed/simple; bh=pRhJ+HxfKK6ioFjQDKdDo7dOuFeprGVHhGzPthqt+II=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=AdaBHJrFYTF7k3xPuEDeOEKsAKNdIYkOIj2zwC5T6Retkl1MaEYpjGQkEd63sXD78n9f61YbzcQ1d3ZDRZXaDJ5QDfjKN4KB38rBBLFYMJWsxGOS+MiZahbE5p1a+KvDSozFKqzv8RbZl14CckGamhdqIDo12fmaQdHZSNpB1Sw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 64C5D1424; Mon, 14 Oct 2024 05:32:16 -0700 (PDT) Received: from e133381.cambridge.arm.com (e133381.arm.com [10.1.198.34]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 2F1373F71E; Mon, 14 Oct 2024 05:31:46 -0700 (PDT) From: Metin Kaya To: linux-trace-devel@vger.kernel.org Cc: metin.kaya@arm.com Subject: [PATCH v2 1/4] trace-cmd reset: Bail out immediately if user provides an invalid option Date: Mon, 14 Oct 2024 13:31:33 +0100 Message-Id: <20241014123136.3890807-2-metin.kaya@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241014123136.3890807-1-metin.kaya@arm.com> References: <20241014123136.3890807-1-metin.kaya@arm.com> Precedence: bulk X-Mailing-List: linux-trace-devel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 trace_reset() does not care invalid command line options and carries on execution. For instance, "trace-cmd reset -x" command successfully completes the reset request (despite of "reset: invalid option -- 'x'" warning). Thus, show the usage message and terminate execution instead of running the reset routine. Signed-off-by: Metin Kaya --- tracecmd/trace-record.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tracecmd/trace-record.c b/tracecmd/trace-record.c index 0063d528..8c0039d4 100644 --- a/tracecmd/trace-record.c +++ b/tracecmd/trace-record.c @@ -6102,6 +6102,9 @@ void trace_reset(int argc, char **argv) instance->flags &= ~BUFFER_FL_KEEP; } break; + default: + usage(argv); + break; } } update_first_instance(instance, topt); From patchwork Mon Oct 14 12:31:34 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Metin Kaya X-Patchwork-Id: 13834927 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 90ADC19340F for ; Mon, 14 Oct 2024 12:31:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728909110; cv=none; b=cLXGFaFmVozm89ugu/m9ayGqUIKX4Pk9X4Yv4vDMHglN7buZRjESvsqS3KIH03i0zRLco2/HTuWCh0DNKm9/rO7NjyNg8wwwE2wV8jiXQo7miqXsx8vMXMNkTSafPEd0ociKhHXkVt0C8xOAtqG1YYNXiEkM+ezvm3Bynw8wop4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728909110; c=relaxed/simple; bh=sacAeAuODOwBlaD9AF61394SmgCzkKDrVoA7kynMOqc=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=ORB9VrM3tgQMO+A2Ts120Hoc4SHjbxqCPruCTG1rlVq3BJd57Z9FxsBBY6IOE2Oea5gjoIsshYtWaK43KXVsYw++0zynCanuiAfATltD7Aank7IGE7yAnNdmlMwjFgCxWEm54mrcQJUZZ6JHax9OQMl38G8goUiTrNtzQoNlrR4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 48A431684; Mon, 14 Oct 2024 05:32:17 -0700 (PDT) Received: from e133381.cambridge.arm.com (e133381.arm.com [10.1.198.34]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 1C2603F71E; Mon, 14 Oct 2024 05:31:46 -0700 (PDT) From: Metin Kaya To: linux-trace-devel@vger.kernel.org Cc: metin.kaya@arm.com Subject: [PATCH v2 2/4] trace-cmd reset: Add option to preserve specific dynamic events Date: Mon, 14 Oct 2024 13:31:34 +0100 Message-Id: <20241014123136.3890807-3-metin.kaya@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241014123136.3890807-1-metin.kaya@arm.com> References: <20241014123136.3890807-1-metin.kaya@arm.com> Precedence: bulk X-Mailing-List: linux-trace-devel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 One may want to preserve some of the dynamic events (e.g., kprobes) during a trace-cmd reset. Thus, provide -k command line option for trace-cmd reset to allow keeping specified events untouched during the reset operation. For example, it's possible to prevent kprobes & kretprobes from being destroyed in trace-cmd reset with this patch: # Add kprobe and kretprobe for sys_open(): $ echo 'p do_sys_open' > /sys/kernel/tracing/kprobe_events $ echo 1 > /sys/kernel/tracing/events/kprobes/p_do_sys_open_0/enable $ echo 'r do_sys_open' >> /sys/kernel/tracing/kprobe_events $ echo 1 > /sys/kernel/tracing/events/kprobes/r_do_sys_open_0/enable $ cat /sys/kernel/tracing/kprobe_events p:kprobes/p_do_sys_open_0 do_sys_open r128:kprobes/r_do_sys_open_0 do_sys_open # Issue reset, but keep kprobes and kretprobes ('-k all' would keep # all existing dynamic events): $ trace-cmd reset -k kprobe -k kretprobe $ cat /sys/kernel/tracing/kprobe_events p:kprobes/p_do_sys_open_0 do_sys_open r128:kprobes/r_do_sys_open_0 do_sys_open # Issue reset, but this time only keep kretprobes: $ trace-cmd reset -k kretprobe $ cat /sys/kernel/tracing/kprobe_events r128:kprobes/r_do_sys_open_0 do_sys_open # Don't preserve any dynamic event: $ trace-cmd reset $ cat /sys/kernel/tracing/kprobe_events $ Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=219302 Signed-off-by: Metin Kaya --- tracecmd/trace-record.c | 59 ++++++++++++++++++++++++++++++++++++----- tracecmd/trace-usage.c | 6 ++++- 2 files changed, 58 insertions(+), 7 deletions(-) diff --git a/tracecmd/trace-record.c b/tracecmd/trace-record.c index 8c0039d4..a008cdfd 100644 --- a/tracecmd/trace-record.c +++ b/tracecmd/trace-record.c @@ -5399,11 +5399,15 @@ static void clear_error_log(void) clear_instance_error_log(instance); } -static void clear_all_dynamic_events(void) +static void clear_all_dynamic_events(unsigned int excluded_types) { - /* Clear event probes first, as they may be attached to other dynamic event */ - tracefs_dynevent_destroy_all(TRACEFS_DYNEVENT_EPROBE, true); - tracefs_dynevent_destroy_all(TRACEFS_DYNEVENT_ALL, true); + /* + * Clear event probes first (if they are not excluded), as they may be + * attached to other dynamic event. + */ + if (!(excluded_types & TRACEFS_DYNEVENT_EPROBE)) + tracefs_dynevent_destroy_all(TRACEFS_DYNEVENT_EPROBE, true); + tracefs_dynevent_destroy_all(~excluded_types & TRACEFS_DYNEVENT_ALL, true); } static void clear_func_filters(void) @@ -6036,11 +6040,51 @@ void trace_restart(int argc, char **argv) exit(0); } +/** + * find_dynevent_type - Find string formatted dynamic event type + * in "enum tracefs_dynevent_type". + * + * @type: Dynamic event type in string format. + * + * Returns an unsigned int value for the event specified in @type. + */ +static unsigned int find_dynevent_type(const char *type) +{ + /* WARN: Should be kept in sync with "enum tracefs_dynevent_type". */ + if (!strcmp(type, "kprobe")) + return TRACEFS_DYNEVENT_KPROBE; + else if (!strcmp(type, "kretprobe")) + return TRACEFS_DYNEVENT_KRETPROBE; + else if (!strcmp(type, "uprobe")) + return TRACEFS_DYNEVENT_UPROBE; + else if (!strcmp(type, "uretprobe")) + return TRACEFS_DYNEVENT_URETPROBE; + else if (!strcmp(type, "eprobe")) + return TRACEFS_DYNEVENT_EPROBE; + else if (!strcmp(type, "synth")) + return TRACEFS_DYNEVENT_SYNTH; + else if (!strcmp(type, "all")) + /* + * Unfortunately TRACEFS_DYNEVENT_ALL does not work here. + * Because tracefs_dynevent_destroy_all() assumes 0 means all + * and destroys all dynamic events. + */ + return TRACEFS_DYNEVENT_KPROBE | + TRACEFS_DYNEVENT_KRETPROBE | + TRACEFS_DYNEVENT_UPROBE | + TRACEFS_DYNEVENT_URETPROBE | + TRACEFS_DYNEVENT_EPROBE | + TRACEFS_DYNEVENT_SYNTH; + else + die("Invalid event type '%s'!\n", type); +} + void trace_reset(int argc, char **argv) { int c; int topt = 0; struct buffer_instance *instance = &top_instance; + unsigned int excluded_types = 0; init_top_instance(); @@ -6048,7 +6092,7 @@ void trace_reset(int argc, char **argv) int last_specified_all = 0; struct buffer_instance *inst; /* iterator */ - while ((c = getopt(argc-1, argv+1, "hab:B:td")) >= 0) { + while ((c = getopt(argc-1, argv+1, "hab:B:tdk:")) >= 0) { switch (c) { case 'h': @@ -6102,6 +6146,9 @@ void trace_reset(int argc, char **argv) instance->flags &= ~BUFFER_FL_KEEP; } break; + case 'k': + excluded_types |= find_dynevent_type(optarg); + break; default: usage(argv); break; @@ -6112,7 +6159,7 @@ void trace_reset(int argc, char **argv) set_buffer_size(); clear_filters(); clear_triggers(); - clear_all_dynamic_events(); + clear_all_dynamic_events(excluded_types); clear_error_log(); /* set clock to "local" */ reset_clock(); diff --git a/tracecmd/trace-usage.c b/tracecmd/trace-usage.c index 8bbf2e3e..7d61a371 100644 --- a/tracecmd/trace-usage.c +++ b/tracecmd/trace-usage.c @@ -193,7 +193,7 @@ static struct usage_help usage_help[] = { { "reset", "disable all kernel tracing and clear the trace buffers", - " %s reset [-b size][-B buf][-a][-d][-t]\n" + " %s reset [-b size][-B buf][-k event][-a][-d][-t]\n" " Disables the tracer (may reset trace file)\n" " Used in conjunction with start\n" " -b change the kernel buffer size (in kilobytes per CPU)\n" @@ -201,6 +201,10 @@ static struct usage_help usage_help[] = { " -B reset the given buffer instance (may specify multiple -B)\n" " -a reset all instances (except top one)\n" " -t reset the top level instance (useful with -B or -a)\n" + " -k keep dynamic event during reset (can be specified multiple times).\n" + " Valid values are:\n" + " 'kprobe', 'kretprobe', 'uprobe', 'uretprobe',\n" + " 'eprobe', 'synth' and 'all'.\n" }, { "clear", From patchwork Mon Oct 14 12:31:35 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Metin Kaya X-Patchwork-Id: 13834928 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2F05E1A3BCB for ; Mon, 14 Oct 2024 12:31:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728909110; cv=none; b=lNfuEH9WxykUQYOaIDtk+y/pBhHoc3szfX09dB+zvzoARzYlWUd7dloEEfxEGtXy1E1qjDJ6PP+LQsa0nyRgO+uNf1io8ykiANSdimZa2WEV2/+QoGyfDeuGpkZUmfsaW8Uc+Z/sdE9gbVJOPiX/ElTVn2+fGRA3R3xfgZEePko= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728909110; c=relaxed/simple; bh=sl/4oEy751i4WZZ6sI0qTlwQwhqnNo2SIYWkS8b0ujk=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=ND/xUYlOtmr1VarkcLfJb+tUSlz5WtY/eIsDIhbD7rYbpu0qFiSziVlTH8RhHkVghhTkFyVBTA+qvzd6OqnMyi12IuTfLknMJ/hOIcygnRcy1rG2Um4yJDtGu4ZiCqxNB+dx52Jc/PMC1JcwjHPQVrnR/ztqt2r4SI6JD7PeAHg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 2CF221688; Mon, 14 Oct 2024 05:32:18 -0700 (PDT) Received: from e133381.cambridge.arm.com (e133381.arm.com [10.1.198.34]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 004743F71E; Mon, 14 Oct 2024 05:31:47 -0700 (PDT) From: Metin Kaya To: linux-trace-devel@vger.kernel.org Cc: metin.kaya@arm.com Subject: [PATCH v2 3/4] trace-cmd reset: Update man page for -k option Date: Mon, 14 Oct 2024 13:31:35 +0100 Message-Id: <20241014123136.3890807-4-metin.kaya@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241014123136.3890807-1-metin.kaya@arm.com> References: <20241014123136.3890807-1-metin.kaya@arm.com> Precedence: bulk X-Mailing-List: linux-trace-devel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Talk about the new -k command line parameter of "trace-cmd reset" in the trace-cmd man page. While we are here, fix typo 'immediatly'. Signed-off-by: Metin Kaya --- Documentation/trace-cmd/trace-cmd-reset.1.txt | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/Documentation/trace-cmd/trace-cmd-reset.1.txt b/Documentation/trace-cmd/trace-cmd-reset.1.txt index eee86751..026232ac 100644 --- a/Documentation/trace-cmd/trace-cmd-reset.1.txt +++ b/Documentation/trace-cmd/trace-cmd-reset.1.txt @@ -60,7 +60,7 @@ significant. See EXAMPLES. *-d*:: This option deletes the instance buffer(s) specified by the most recently preceding *-B* or *-a* option. Because the top-level instance buffer - cannot be deleted, it is invalid to use this immediatly following *-t* or + cannot be deleted, it is invalid to use this immediately following *-t* or prior to any *-B* or *-a* option on the command line. *-t*:: @@ -68,6 +68,12 @@ significant. See EXAMPLES. this is the same as the default. But if *-B* or *-a* is used, this is required if the top level instance buffer should also be reset. +*-k* 'dynevent-name':: + This option allows preserving specified dynamic event during reset. Valid + parameters are *kprobe*, *kretprobe*, *uprobe*, *uretprobe*, *eprobe*, + *synth* and *all* (for keeping all dynamic events). This may be used + multiple times to specify different dynamic event types. + EXAMPLES -------- @@ -94,6 +100,10 @@ instance buffers exist, they will be unaffected: trace-cmd reset -b 1024 +Prevent *kprobes* and *kretprobes* from being destroyed during reset: + + trace-cmd reset -k kprobe -k kretprobe + SEE ALSO -------- From patchwork Mon Oct 14 12:31:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Metin Kaya X-Patchwork-Id: 13834929 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 12BED7E574 for ; Mon, 14 Oct 2024 12:31:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728909111; cv=none; b=fJlCKlw80n9Yod/UTSs1c+a+aqvQ4i72OX/nkl3VNvVVvkgk2G43I2SBm1TTfYM1+JS/nsQRg7/xOAcAweFIZHHtWHyxeY0ritR35v++yvtChmNMxtZJkpql0L0/CoOZqprQVErxb/KkPudIYORoL13YqeLxUG3F45SWCXRcfFo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728909111; c=relaxed/simple; bh=Vaac8EnoeanM/QhzlqKu+YL2y1e0ksBhKZV5ROrzMIY=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Hq2+zRZPjzLOtKuuz7sepkw3DJk1f9bKVex84hgBrRRitmgo5hAXWwQTE7VN4ucmgi+O/+UdMhTaDVY0VjjIBeM7vs1RC9yXCuRAMV/xR028LSRseeeCl3T/53mK15cB5DJQu+EI70tMuVU8A9vUulPFJbKjLuGuEGBGwNcATyc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 119D7168F; Mon, 14 Oct 2024 05:32:19 -0700 (PDT) Received: from e133381.cambridge.arm.com (e133381.arm.com [10.1.198.34]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id D8EE43F71E; Mon, 14 Oct 2024 05:31:48 -0700 (PDT) From: Metin Kaya To: linux-trace-devel@vger.kernel.org Cc: metin.kaya@arm.com Subject: [PATCH v2 4/4] trace-cmd reset: Add bash tab completion for -B and -k Date: Mon, 14 Oct 2024 13:31:36 +0100 Message-Id: <20241014123136.3890807-5-metin.kaya@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241014123136.3890807-1-metin.kaya@arm.com> References: <20241014123136.3890807-1-metin.kaya@arm.com> Precedence: bulk X-Mailing-List: linux-trace-devel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Implement the placeholder for tab completion of "trace-cmd reset". Apparently trace-cmd.bash already has support for instance buffers lookup (which is show_instances()). Employ it for -B option. Regarding -k option, show the list of dynamic event types to ease trace-cmd user's job. Signed-off-by: Metin Kaya --- tracecmd/trace-cmd.bash | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/tracecmd/trace-cmd.bash b/tracecmd/trace-cmd.bash index 66bd6f4b..01a75578 100644 --- a/tracecmd/trace-cmd.bash +++ b/tracecmd/trace-cmd.bash @@ -215,6 +215,33 @@ __trace_cmd_report_complete() esac } +dynevent_options() +{ + local cur="$1" + local opts=("kprobe" "kretprobe" "uprobe" "uretprobe" "eprobe" "synth" "all") + COMPREPLY=( $(compgen -W "${opts[*]}" -- "${cur}") ) +} + +__trace_cmd_reset_complete() +{ + local prev=$1 + local cur=$2 + shift 2 + local words=("$@") + + case "$prev" in + -B) + show_instances "$cur" + ;; + -k) + dynevent_options "$cur" + ;; + *) + cmd_options reset "$cur" + ;; + esac +} + __trace_cmd_dump_complete() { local prev=$1 @@ -329,6 +356,10 @@ _trace_cmd_complete() __trace_cmd_report_complete "${prev}" "${cur}" ${words[@]} return 0 ;; + reset) + __trace_cmd_reset_complete "${prev}" "${cur}" "${words[@]}" + return 0 + ;; dump) __trace_cmd_dump_complete "${prev}" "${cur}" ${words[@]} return 0