[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <6712b717a9610_10a0a2942e@dwillia2-mobl3.amr.corp.intel.com.notmuch>
Date: Fri, 18 Oct 2024 12:29:27 -0700
From: Dan Williams <dan.j.williams@...el.com>
To: Peter Zijlstra <peterz@...radead.org>, David Lechner
<dlechner@...libre.com>
CC: Dan Williams <dan.j.williams@...el.com>, Linus Torvalds
<torvalds@...ux-foundation.org>, Jonathan Cameron <jic23@...nel.org>, Nuno
Sá <nuno.sa@...log.com>, Michael Hennerich
<michael.hennerich@...log.com>, <linux-kernel@...r.kernel.org>,
<linux-iio@...r.kernel.org>, <linux-cxl@...r.kernel.org>,
<przemyslaw.kitszel@...el.com>
Subject: Re: [PATCH 1/3] cleanup: add conditional guard helper
Peter Zijlstra wrote:
> On Tue, Oct 01, 2024 at 05:30:18PM -0500, David Lechner wrote:
> > Add a new if_not_cond_guard() macro to cleanup.h for handling
> > conditional guards such as mutext_trylock().
> >
> > This is more ergonomic than scoped_cond_guard() for most use cases.
> > Instead of hiding the error handling statement in the macro args, it
> > works like a normal if statement and allow the error path to be indented
> > while the normal code flow path is not indented. And it avoid unwanted
> > side-effect from hidden for loop in scoped_cond_guard().
> >
> > Signed-off-by: David Lechner <dlechner@...libre.com>
> > ---
> > include/linux/cleanup.h | 11 +++++++++++
> > 1 file changed, 11 insertions(+)
> >
[..]
> I've queued these two patches:
>
> git://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git locking/core
>
> But lacking if_not_guard() users, the robot isn't really going to give
> me much feedback there, I suppose...
Looks good. If that branch is rebase-able it would be nice to add some
credit tags to "cleanup: Add conditional guard helper":
Co-developed-by: Fabio M. De Francesco <fabio.m.de.francesco@...ux.intel.com>
Signed-off-by: Fabio M. De Francesco <fabio.m.de.francesco@...ux.intel.com>
David and I talked about that here:
http://lore.kernel.org/f4cc471a-b602-48d8-8323-15efcd602814@baylibre.com
Also feel free to add:
Reviewed-by: Dan Williams <dan.j.williams@...el.com>
Thanks, Peter!
Powered by blists - more mailing lists