Re: [PATCH v2 1/5] pwm: core: add pwm_get_waveform_step_might_sleep()
From: Nicolae-Daniel Deaconescu
Date: Fri Nov 06 2026 - 11:18:17 EST
Hi Andy,
Thanks for the review. v3 addresses these:
https://lore.kernel.org/all/20261106160529.876251-1-Nicolae-daniel.Deaconescu@xxxxxxxxxx/
On Wed, Nov 04, 2026 at 09:51:31PM +0200, Andy Shevchenko wrote:
> On Wed, Nov 04, 2026 at 03:21:39PM +0200, Nicolae-Daniel Deaconescu wrote:
>
> > + *
> > + * Returns: 0 on success, -EOPNOTSUPP if the provider doesn't report it or a
> > + * negative errno
> > + * Context: May sleep.
>
> This is incorrect. The Returns section has to be the last one in the
> kernel-doc. It's documented.
Done. Context: is now before Return:, and Return: is last.
>
> > + if (ret)
> > + return ret;
> > +
> > + if (!step->clk_rate_hz || !step->clk_cycles_per_step ||
>
> The second check is unneeded, the third one covers it.
Removed the clk_cycles_per_step check, the rate check covers it.
>
> > + * nanosecond resolution of struct pwm_waveform.
> > + */
> > +struct pwm_waveform_step {
> > + unsigned long clk_rate_hz;
>
> _Hz ?
Renamed it to clk_rate_Hz.
Thanks,
Daniel