From: Steven Rostedt <rostedt@goodmis.org>
To: Daniel Bristot de Oliveira <bristot@kernel.org>
Cc: Jonathan Corbet <corbet@lwn.net>,
Juri Lelli <juri.lelli@redhat.com>,
Clark Williams <williams@redhat.com>,
Bagas Sanjaya <bagasdotme@gmail.com>,
linux-trace-devel@vger.kernel.org, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH V2 1/6] rtla/osnoise: Add helper functions to manipulate osnoise/options
Date: Wed, 1 Feb 2023 14:25:30 -0500 [thread overview]
Message-ID: <20230201142530.61b5ac00@gandalf.local.home> (raw)
In-Reply-To: <930c4ef71c7bcb1158d2a8cad905f4de425b8d1e.1675181734.git.bristot@kernel.org>
On Tue, 31 Jan 2023 17:30:02 +0100
Daniel Bristot de Oliveira <bristot@kernel.org> wrote:
> +#define OSNOISE_OPTION(name, option_str) \
> +static int osnoise_get_##name(struct osnoise_context *context) \
> +{ \
> + if (context->opt_##name != OSNOISE_OPTION_INIT_VAL) \
> + return context->opt_##name; \
> + \
> + if (context->orig_opt_##name != OSNOISE_OPTION_INIT_VAL) \
> + return context->orig_opt_##name; \
> + \
> + context->orig_opt_##name = osnoise_options_get_option(option_str); \
> + \
> + return context->orig_opt_##name; \
> +} \
> + \
What you could have done is not make this into a super macro (as there's
only one instance of it). And then add a patch that turns it into this
macro as the first patch of a series that adds another user.
Because I don't understand why this exists when it only has one user.
-- Steve
next prev parent reply other threads:[~2023-02-01 19:25 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-31 16:30 [PATCH V2 0/6] rtla: Add hwnoise tool Daniel Bristot de Oliveira
2023-01-31 16:30 ` [PATCH V2 1/6] rtla/osnoise: Add helper functions to manipulate osnoise/options Daniel Bristot de Oliveira
2023-02-01 19:23 ` Steven Rostedt
2023-02-07 20:04 ` Daniel Bristot de Oliveira
2023-02-01 19:25 ` Steven Rostedt [this message]
2023-01-31 16:30 ` [PATCH V2 2/6] rtla/osnoise: Add OSNOISE_IRQ_DISABLE option Daniel Bristot de Oliveira
2023-01-31 16:30 ` [PATCH V2 3/6] rtla/osnoise: Add the mode abstraction Daniel Bristot de Oliveira
2023-01-31 16:30 ` [PATCH V2 4/6] rtla/osnoise_top: Pass the params to the usage function Daniel Bristot de Oliveira
2023-01-31 16:30 ` [PATCH V2 5/6] rtla: Add hwnoise tool Daniel Bristot de Oliveira
2023-01-31 16:30 ` [PATCH V2 6/6] Documentation/rtla: Add hwnoise man page Daniel Bristot de Oliveira
2023-02-01 9:10 ` Bagas Sanjaya
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=20230201142530.61b5ac00@gandalf.local.home \
--to=rostedt@goodmis.org \
--cc=bagasdotme@gmail.com \
--cc=bristot@kernel.org \
--cc=corbet@lwn.net \
--cc=juri.lelli@redhat.com \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-trace-devel@vger.kernel.org \
--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).