[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aN6N8diBxVk1k9pi@ada.csh.rit.edu>
Date: Thu, 2 Oct 2025 10:36:33 -0400
From: Mary Strodl <mstrodl@....rit.edu>
To: Dan Carpenter <dan.carpenter@...aro.org>
Cc: oe-kbuild@...ts.linux.dev, linux-kernel@...r.kernel.org, lkp@...el.com,
oe-kbuild-all@...ts.linux.dev, linus.walleij@...aro.org,
brgl@...ev.pl, linux-gpio@...r.kernel.org
Subject: Re: [PATCH v2 1/3] gpio: mpsse: use rcu to ensure worker is torn down
Hey Dan,
On Mon, Sep 29, 2025 at 11:48:46AM +0300, Dan Carpenter wrote:
> On Mon, Sep 29, 2025 at 11:46:24AM +0300, Dan Carpenter wrote:
> > a14b0c5e3b0741 Mary Strodl 2025-09-23 339 /* Make sure list consumers are finished before we tear down */
> > a14b0c5e3b0741 Mary Strodl 2025-09-23 340 synchronize_rcu();
> > a14b0c5e3b0741 Mary Strodl 2025-09-23 @341 list_for_each_entry(worker, &destructors, destroy)
> > a14b0c5e3b0741 Mary Strodl 2025-09-23 @342 gpio_mpsse_stop(worker);
> >
> > This needs to be list_for_each_entry_safe() because gpio_mpsse_stop()
> > frees the worker. Or kfree_rcu() inside an rcu lock or something.
Really good catch! The loop above this one has the same problem. Will be fixed next revision :)
Thank you!
Powered by blists - more mailing lists