From: Nam Cao <namcao@linutronix.de>
To: Gabriele Monaco <gmonaco@redhat.com>,
linux-kernel@vger.kernel.org,
Steven Rostedt <rostedt@goodmis.org>,
Gabriele Monaco <gmonaco@redhat.com>,
linux-trace-kernel@vger.kernel.org
Cc: Tomas Glozar <tglozar@redhat.com>, Juri Lelli <jlelli@redhat.com>,
Clark Williams <williams@redhat.com>,
John Kacur <jkacur@redhat.com>
Subject: Re: [PATCH v3 01/13] rv: Unify DA event handling functions across monitor types
Date: Thu, 18 Dec 2025 08:04:15 +0700 [thread overview]
Message-ID: <871pksk3cg.fsf@yellow.woof> (raw)
In-Reply-To: <20251205131621.135513-2-gmonaco@redhat.com>
Gabriele Monaco <gmonaco@redhat.com> writes:
> The DA event handling functions are mostly duplicated because the
> per-task monitors need to propagate the task to use the pid in the trace
> events. This is a maintenance burden for a little advantage.
> The task can be obtained with some pointer arithmetic from the da_mon,
> hence only the function tracing events really need to differ.
>
> Unify all code handling the events, create da_trace_event() and
> da_trace_error() that only call the tracepoint function.
> Propagate the monitor id through the calls, the do_trace_ functions use
> the id (pid) in case of per-task monitors but ignore it for implicit
> monitors.
I think this overexplains. I would just explain the "WHY", then the
general idea how the patch solves the problem. Let the diff speaks for
the rest.
Perhaps something like:
The DA event handling functions are mostly duplicated for
differerent monitor types, because per-task monitors' functions
require a task_struct parameter while the others do not.
Unify the functions, handle the difference by always passing a
da_id_type which is the task's pid for per-task monitor but is
ignored for the other types.
Regardless:
Reviewed-by: Nam Cao <namcao@linutronix.de>
Nam
next prev parent reply other threads:[~2025-12-18 1:04 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-05 13:16 [PATCH v3 00/13] rv: Add Hybrid Automata monitor type, per-object and deadline monitors Gabriele Monaco
2025-12-05 13:16 ` [PATCH v3 01/13] rv: Unify DA event handling functions across monitor types Gabriele Monaco
2025-12-18 1:04 ` Nam Cao [this message]
2025-12-22 14:45 ` Gabriele Monaco
2025-12-05 13:16 ` [PATCH v3 02/13] rv: Add Hybrid Automata monitor type Gabriele Monaco
2025-12-18 5:57 ` Nam Cao
2025-12-22 15:26 ` Gabriele Monaco
2025-12-05 13:16 ` [PATCH v3 03/13] verification/rvgen: Allow spaces in and events strings Gabriele Monaco
2025-12-05 13:16 ` [PATCH v3 04/13] verification/rvgen: Add support for Hybrid Automata Gabriele Monaco
2025-12-25 1:05 ` Nam Cao
2025-12-05 13:16 ` [PATCH v3 05/13] Documentation/rv: Add documentation about hybrid automata Gabriele Monaco
2025-12-25 1:16 ` Nam Cao
2025-12-05 13:16 ` [PATCH v3 06/13] rv: Add sample hybrid monitors stall Gabriele Monaco
2025-12-18 6:32 ` Nam Cao
2025-12-05 13:16 ` [PATCH v3 07/13] rv: Convert the opid monitor to a hybrid automaton Gabriele Monaco
2025-12-18 6:50 ` Nam Cao
2025-12-05 13:16 ` [PATCH v3 08/13] sched: Export hidden tracepoints to modules Gabriele Monaco
2025-12-05 13:35 ` Phil Auld
2025-12-11 22:36 ` Phil Auld
2025-12-05 13:16 ` [PATCH v3 09/13] sched: Add deadline tracepoints Gabriele Monaco
2025-12-05 13:41 ` Phil Auld
2025-12-05 13:16 ` [PATCH v3 10/13] rv: Add support for per-object monitors in DA/HA Gabriele Monaco
2025-12-18 7:26 ` Nam Cao
2025-12-05 13:16 ` [PATCH v3 11/13] verification/rvgen: Add support for per-obj monitors Gabriele Monaco
2025-12-05 13:16 ` [PATCH v3 12/13] rv: Add deadline monitors Gabriele Monaco
2025-12-25 1:35 ` Nam Cao
2025-12-25 1:58 ` Nam Cao
2025-12-29 7:00 ` Gabriele Monaco
2025-12-05 13:16 ` [PATCH v3 13/13] rv: Add dl_server specific monitors Gabriele Monaco
2025-12-25 1:51 ` Nam Cao
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=871pksk3cg.fsf@yellow.woof \
--to=namcao@linutronix.de \
--cc=gmonaco@redhat.com \
--cc=jkacur@redhat.com \
--cc=jlelli@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-trace-kernel@vger.kernel.org \
--cc=rostedt@goodmis.org \
--cc=tglozar@redhat.com \
--cc=williams@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).