RE: [PATCH 2/2] clk: renesas: rzv2h: Deassert reset on assert timeout
From: Biju Das
Date: Thu Jan 08 2026 - 07:53:35 EST
Hi Geert,
Thanks for the feedback
> -----Original Message-----
> From: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>
> Sent: 07 January 2026 11:18
> Subject: Re: [PATCH 2/2] clk: renesas: rzv2h: Deassert reset on assert timeout
>
> Hi Biju,
>
> On Mon, 8 Dec 2025 at 11:14, Biju <biju.das.au@xxxxxxxxx> wrote:
> > From: Biju Das <biju.das.jz@xxxxxxxxxxxxxx>
> >
> > If the assert() fails due to timeout error, set the reset register bit
> > back to deasserted state. This change is needed especially for
> > handling assert error in suspend() callback that expect the device to
> > be in operational state in case of failure.
> >
> > Signed-off-by: Biju Das <biju.das.jz@xxxxxxxxxxxxxx>
>
> Thanks for your patch!
>
> Reviewed-by: Geert Uytterhoeven <geert+renesas@xxxxxxxxx>
>
> > --- a/drivers/clk/renesas/rzv2h-cpg.c
> > +++ b/drivers/clk/renesas/rzv2h-cpg.c
> > @@ -1366,8 +1366,11 @@ static int __rzv2h_cpg_assert(struct
> > reset_controller_dev *rcdev,
> >
> > ret = readl_poll_timeout_atomic(priv->base + reg, value,
> > assert == !!(value & mask), 10, 200);
> > - if (ret && !assert) {
> > + if (ret) {
> > value = mask << 16;
> > + if (assert)
> > + value |= mask;
> > +
>
> Same here: if readl_poll_timeout_atomic() would use its own
> variable:
OK will do in next version.
Cheers,
Biju