Re: [PATCH v3 2/4] clk: microchip: core: correct return value on *_get_parent()
From: Brian Masney
Date: Sat Dec 06 2025 - 17:38:30 EST
On Sat, Dec 06, 2025 at 04:31:03PM +0200, Claudiu Beznea wrote:
>
>
> On 12/5/25 21:46, Brian Masney wrote:
> > roclk_get_parent() and sclk_get_parent() has the possibility of
> > returning -EINVAL, however the framework expects this call to always
> > succeed since the return value is unsigned.
> >
> > If there is no parent map defined, then the current value programmed in
> > the hardware is used. Let's use that same value in the case where
> > -EINVAL is currently returned.
> >
> > This index is only used by clk_core_get_parent_by_index(), and it
> > validates that it doesn't overflow the number of available parents.
> >
> > Reported-by: kernel test robot <lkp@xxxxxxxxx>
>
> I'm getting this from checkpatch:
>
> Applying: clk: microchip: core: correct return value on *_get_parent()
> [Checking commit] 910546c58dc2 clk: microchip: core: correct return value
> on *_get_parent()
> [Checkpatch] WARNING: Reported-by: should be immediately followed by
> Closes: with a URL to the report
> #17:
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> Reported-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
That's a false positive from checkpatch. It doesn't like the two
Reported-by lines, with a single Closes. The warning goes away if I do
this:
Reported-by: kernel test robot <lkp@xxxxxxxxx>
Closes: https://lore.kernel.org/r/202512050233.R9hAWsJN-lkp@xxxxxxxxx/
Reported-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
Closes: https://lore.kernel.org/r/202512050233.R9hAWsJN-lkp@xxxxxxxxx/
> > Reported-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> > Closes: https://lore.kernel.org/r/202512050233.R9hAWsJN-lkp@xxxxxxxxx/
> > Signed-off-by: Brian Masney <bmasney@xxxxxxxxxx>
>
> Other than the above:
> Reviewed-by: Claudiu Beznea <claudiu.beznea@xxxxxxxxx>
Thanks!
Brian