From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Matti Vaittinen <mazziesaccount@gmail.com>
Cc: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>,
Jonathan Cameron <jic23@kernel.org>,
Daniel Scally <djrscally@gmail.com>,
Heikki Krogerus <heikki.krogerus@linux.intel.com>,
Sakari Ailus <sakari.ailus@linux.intel.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
Danilo Krummrich <dakr@kernel.org>,
linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] property: Use tidy for_each_named_* macros
Date: Mon, 14 Apr 2025 09:47:44 +0300 [thread overview]
Message-ID: <Z_yvkKTgI4XSlGya@smile.fi.intel.com> (raw)
In-Reply-To: <Z_yvNl23GcEpOkK1@smile.fi.intel.com>
On Mon, Apr 14, 2025 at 09:46:14AM +0300, Andy Shevchenko wrote:
> On Thu, Apr 10, 2025 at 02:52:00PM +0300, Matti Vaittinen wrote:
> > Implementing if-conditions inside for_each_x() macros requires some
> > thinking to avoid side effects in the calling code. Resulting code
> > may look somewhat awkward, and there are couple of different ways it is
> > usually done.
> >
> > Standardizing this to one way can help making it more obvious for a code
> > reader and writer. The newly added for_each_if() is a way to achieve this.
> >
> > Use for_each_if() to make these macros look like many others which
> > should in the long run help reading the code.
>
> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> Thanks for cleaning these up!
>
> > ---
> > The patch was crafted against the IIO/testing branch, and it depends on
> > the 76125d7801e5 ("property: Add functions to iterate named child").
> > Hence I'd suggest taking this via IIO tree (if this gets accepted).
>
> I'm not sure why. The for_each_if() is part of v6.15-rc1.
Ah, I see, you are trying to fix newly introduced stuff? I would rather suggest
to make this straightforward against the current upstream and ask Jonathan to
rebase the testing to fold the fixes into a new APIs.
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2025-04-14 6:47 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-10 11:52 [PATCH] property: Use tidy for_each_named_* macros Matti Vaittinen
2025-04-10 16:09 ` Sakari Ailus
2025-04-14 6:46 ` Andy Shevchenko
2025-04-14 6:47 ` Andy Shevchenko [this message]
2025-04-14 19:14 ` Jonathan Cameron
2025-04-16 5:55 ` Matti Vaittinen
2025-04-16 6:41 ` Andy Shevchenko
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=Z_yvkKTgI4XSlGya@smile.fi.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=dakr@kernel.org \
--cc=djrscally@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=heikki.krogerus@linux.intel.com \
--cc=jic23@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=matti.vaittinen@fi.rohmeurope.com \
--cc=mazziesaccount@gmail.com \
--cc=rafael@kernel.org \
--cc=sakari.ailus@linux.intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.