Hi Biju, On Wed, 2 Apr 2025 at 12:23, Biju Das <biju.das.jz@xxxxxxxxxxxxxx> wrote: > Add rcar_canfd_setrnc() to replace the macro RCANFD_GAFLCFG_SETRNC. > While at it, replace int->unsigned int for local variables offset, page > and num_rules in rcar_canfd_configure_afl_rules(). > > Signed-off-by: Biju Das <biju.das.jz@xxxxxxxxxxxxxx> Thanks for your patch! Reviewed-by: Geert Uytterhoeven <geert+renesas@xxxxxxxxx> One nit below. > --- a/drivers/net/can/rcar/rcar_canfd.c > +++ b/drivers/net/can/rcar/rcar_canfd.c > @@ -676,6 +672,15 @@ static void rcar_canfd_tx_failure_cleanup(struct net_device *ndev) > can_free_echo_skb(ndev, i, NULL); > } > > +static void rcar_canfd_setrnc(struct rcar_canfd_global *gpriv, unsigned int ch, > + unsigned int num_rules) > +{ > + unsigned int shift = reg_gen4(gpriv, 16, 24) - (ch & 1) * reg_gen4(gpriv, 16, 8); > + u32 rnc = num_rules << shift; Unneeded double space. > + > + rcar_canfd_set_bit(gpriv->base, RCANFD_GAFLCFG(ch), rnc); > +} > + > static void rcar_canfd_set_mode(struct rcar_canfd_global *gpriv) > { > if (is_gen4(gpriv)) { Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx 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