Re: Linux 6.18
From: Brian Norris
Date: Tue Dec 02 2025 - 14:37:04 EST
On Tue, Dec 02, 2025 at 03:37:58PM +0100, Wysocki, Rafael J wrote:
> On 12/2/2025 5:50 AM, Brian Norris wrote:
> > Looking closer at this part of the API, I think checking the return code
> > of pm_runtime_barrier() is a bad idea, since it's inherently racy, and
> > there's really no way to control that race. On the plus side, this test
> > is the only one that does it. So I can probably just go ahead and make
> > pm_runtime_barrier() a void function, and stop pretending it's part of
> > the API surface. One fewer weird part of the runtime PM API to think
> > about...
>
> Yes, pm_runtime_barrier() should be void, the return value is a leftover
> thing.
Thanks for the confirmation.
> > Maybe I can get around to that tomorrow.
>
> I can do it unless you specifically want to take care of it yourself.
I wrote the (bad) test, so I figured it's good citizenship to fix it.
And anyway, I drafted it most of it yesterday already.
I've submitted a version here
Subject: [PATCH 1/3] PM: runtime: Stop checking pm_runtime_barrier() return code
https://lore.kernel.org/all/20251202193129.1411419-1-briannorris@xxxxxxxxxxxx/
Feel free to tweak it or do it in your preferred way though, if you'd
like.
Brian