Re: [PATCH 04/11] pwm: brcmstb: Use DEFINE_SIMPLE_DEV_PM_OPS for PM functions

Uwe Kleine-König
2023-10-11T16:48:16Z

[-- Attachment #1: Type: text/plain, Size: 2107 bytes --]

On Wed, Oct 11, 2023 at 08:42:54AM -0700, Florian Fainelli wrote:
>
>
> On 10/11/2023 8:31 AM, Uwe Kleine-König wrote:
> > On Wed, Oct 11, 2023 at 12:21:52PM +0100, Jonathan Cameron wrote:
> > > On Tue, 10 Oct 2023 09:51:05 +0200
> > > Uwe Kleine-König <u.kleine-koenig@pengutronix.de> wrote:
> > >
> > > > This macro has the advantage over SIMPLE_DEV_PM_OPS that we don't have to
> > > > care about when the functions are actually used, so the corresponding
> > > > #ifdef can be dropped.
> > > >
> > > > Also make use of pm_ptr() to discard all PM related stuff if CONFIG_PM
> > > > isn't enabled.
> > >
> > > The additional change to potentially return an error when not doing so before
> > > wants to be called out in the description.
> >
> > Indeed, good catch. Something like:
> >
> > pwm: brcmstb: Use DEFINE_SIMPLE_DEV_PM_OPS for PM
> >
> > This macro has the advantage over SIMPLE_DEV_PM_OPS that we don't have to
> > care about when the functions are actually used, so the corresponding
> > #ifdef can be dropped.
> >
> > Also make use of pm_ptr() to discard all PM related stuff if CONFIG_PM
> > isn't enabled.
> >
> > While touching brcmstb_pwm_suspend() also propagate the return
> > value of clk_enable() to the caller of .suspend().
> >
> > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> >
> > I fixed that in my tree, so if and when v2 happens, this comment will be
> > addressed.
>
> OK so that makes:
>
> https://lore.kernel.org/all/20231005164728.1846726-1-florian.fainelli@broadcom.com/
>
> void, and now I also need to re-submit:
>
> https://lore.kernel.org/all/20231004175414.1738475-1-florian.fainelli@broadcom.com/
>
> or is Thierry going to resolve that conflict for us?

Oh right, I remember.

@Thierry: Please drop my patch and take Florian's instead. I mark my
patch as rejected.

@Florian: Sorry!

Best regards
Uwe

--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]