[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Z688uKdqVDaQhm5V@hovoldconsulting.com>
Date: Fri, 14 Feb 2025 13:53:12 +0100
From: Johan Hovold <johan@...nel.org>
To: Ulf Hansson <ulf.hansson@...aro.org>
Cc: Johan Hovold <johan+linaro@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
"Rafael J. Wysocki" <rafael@...nel.org>,
Geert Uytterhoeven <geert+renesas@...der.be>,
linux-pm@...r.kernel.org, linux-kernel@...r.kernel.org,
Liu Ying <victor.liu@....com>
Subject: Re: [PATCH] bus: simple-pm-bus: fix forced runtime PM use
On Fri, Feb 14, 2025 at 01:36:48PM +0100, Ulf Hansson wrote:
> On Fri, 14 Feb 2025 at 11:21, Johan Hovold <johan+linaro@...nel.org> wrote:
> >
> > The simple-pm-bus driver only enables runtime PM for some buses
> > ('simple-pm-bus') yet has started calling pm_runtime_force_suspend() and
> > pm_runtime_force_resume() during system suspend unconditionally.
> >
> > This currently works, but that is not obvious and depends on
> > implementation details which may change at some point.
> >
> > Add dedicated system sleep ops and only call pm_runtime_force_suspend()
> > and pm_runtime_force_resume() for buses that use runtime PM to avoid any
> > future surprises.
> >
> > Fixes: c45839309c3d ("drivers: bus: simple-pm-bus: Use clocks")
>
> This doesn't look like it is needed to me. It isn't broken, right?
I didn't add a CC stable tag since this currently works, but I still
consider it a bug to call these helpers unconditionally when not using
runtime PM.
[ And during rc1 these callbacks were suddenly called and triggered a
NULL-pointer dereference as you know. [1] ]
Johan
[1] https://lore.kernel.org/lkml/Z6YcjFBWAVVVANf2@hovoldconsulting.com/
Powered by blists - more mailing lists