[PATCH] soc: renesas: rcar-sysc: Use readl_poll_timeout_atomic()
Geert Uytterhoeven
geert at linux-m68k.org
Mon Jan 25 08:12:17 EST 2021
Hi Niklas,
On Fri, Jan 22, 2021 at 8:04 PM Niklas Söderlund
<niklas.soderlund at ragnatech.se> wrote:
> On 2021-01-22 12:36:37 +0100, Geert Uytterhoeven wrote:
> > Replace the open-coded polling loops by calls to the
> > readl_poll_timeout_atomic() helper macro.
> >
> > Signed-off-by: Geert Uytterhoeven <geert+renesas at glider.be>
> > --- a/drivers/soc/renesas/rcar-sysc.c
> > +++ b/drivers/soc/renesas/rcar-sysc.c
> > @@ -101,8 +100,7 @@ static int rcar_sysc_power(const struct rcar_sysc_ch *sysc_ch, bool on)
> > unsigned int chan_mask = BIT(sysc_ch->chan_bit);
> > unsigned int status;
> > unsigned long flags;
> > - int ret = 0;
> > - int k;
> > + int k, ret;
>
> nit: I would make k an unsigned as it's now only used in incremental
> loops starting at 0.
That was the case before, too, wasn't it? ;-)
> With or without this unrelated nit,
>
> Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas at ragnatech.se>
Thanks, will make the change.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
More information about the linux-arm-kernel
mailing list