Re: [PATCH v2] staging: nvec: use guard(mutex) in nvec_write_sync()

From: Julia Lawall

Date: Thu Oct 15 2026 - 14:04:48 EST




On Thu, 15 Oct 2026, Jeremy Dean Clifton wrote:

> On 10/13/26 12:15 AM, Greg Kroah-Hartman wrote:
> > On Mon, Oct 12, 2026 at 10:29:26PM +0000, Jeremy Dean Clifton wrote:
> > > The three return paths of nvec_write_sync() each release
> > > sync_write_mutex with explicit unlock calls.
> > >
> > > Use guard(mutex) to unlock the lock automatically on any return
> > > path.
> > >
> > > This removes the three mutex_unlock() calls.
> > >
> > > No functional change.
> > >
> > > Signed-off-by: Jeremy Dean Clifton <deaner92@xxxxxxxxx>
> > > ---
> > > v2:
> > > - Reword the commit message to state the motivation and to make
> > > clear that removing the mutex_unlock() calls is the result of
> > > the change (Julia Lawall).
> > > v1: https://lore.kernel.org/all/20261012171312.5998-1-deaner92@xxxxxxxxx/
> >
> > Please read the archives for why I will not take guard() rewrites of
> > staging drivers (nor do I want to see you use a LLM in here either.)
> >
> > sorry,
> >
> > greg k-h
>
> Hello Greg + Everyone,
>
>
> It turns out that I was unknowingly subscribed to this list and started
> creating patches for the Outreachy group without ever having submitted an
> application to Outreachy. I just wanted to learn how to contribute to the
> Linux Kernel and I saw https://kernelnewbies.org/ as a direct connection to
> Outreachy.
>
> While I am technically not part of this cohort, I can still review patches.
> What is preferred?
>
> I assume that the same rules apply outside of Outreachy? No LLMs and no
> guard() rewrites.

Yes, to my understanding.

julia

>
> Jeremy
>
>
>