public inbox for cip-dev@lists.cip-project.org
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@nabladev.com>
To: Biju <biju.das.au@gmail.com>
Cc: cip-dev@lists.cip-project.org,
	Nobuhiro Iwamatsu <nobuhiro.iwamatsu.x90@mail.toshiba>,
	Pavel Machek <pavel@nabladev.com>,
	Biju Das <biju.das.jz@bp.renesas.com>,
	Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Subject: Re: [PATCH 6.12.y-cip 6/6] can: rcar_canfd: Add support for FD-Only mode
Date: Mon, 9 Mar 2026 09:16:30 +0100	[thread overview]
Message-ID: <aa6B3tuP6oufeYb6@duo.ucw.cz> (raw)
In-Reply-To: <20260309075112.35445-7-biju.das.jz@bp.renesas.com>

[-- Attachment #1: Type: text/plain, Size: 1895 bytes --]

Hi!
> From: Biju Das <biju.das.jz@bp.renesas.com>
> 
> [ Upstream commit 9a2b56a48c219d189366dd9bf4c2b42afde2f361 ]
> 
> The RZ/{G2L,G3E} and R-Car Gen4 SoCs support additional CAN FD mode called
> FD-only mode. In this mode, communication in Classical CAN frame format is
> disabled.
> 
> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
> Link: https://patch.msgid.link/20251126155911.320563-3-biju.das.jz@bp.renesas.com
> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
> ---
>  drivers/net/can/rcar/rcar_canfd.c | 14 +++++++++++++-
>  1 file changed, 13 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/net/can/rcar/rcar_canfd.c b/drivers/net/can/rcar/rcar_canfd.c
> index 68e6c7ac6649..4bfc7b5ac0ae 100644
> --- a/drivers/net/can/rcar/rcar_canfd.c
> +++ b/drivers/net/can/rcar/rcar_canfd.c
> @@ -829,12 +830,20 @@ static int rcar_canfd_reset_controller(struct rcar_canfd_global *gpriv)
>  							 RCANFD_GEN4_FDCFG_FDOE);
>  				rcar_canfd_set_bit_reg(&gpriv->fcbase[ch].cfdcfg,
>  						       RCANFD_GEN4_FDCFG_CLOE);
> +			} else if (gpriv->fd_only_mode) {
> +				rcar_canfd_clear_bit_reg(&gpriv->fcbase[ch].cfdcfg,
> +							 RCANFD_GEN4_FDCFG_CLOE);
> +				rcar_canfd_set_bit_reg(&gpriv->fcbase[ch].cfdcfg,
> +						       RCANFD_GEN4_FDCFG_FDOE);
>  			} else {
>  				rcar_canfd_clear_bit_reg(&gpriv->fcbase[ch].cfdcfg,
>  							 RCANFD_GEN4_FDCFG_FDOE);
>  				rcar_canfd_clear_bit_reg(&gpriv->fcbase[ch].cfdcfg,
>  							 RCANFD_GEN4_FDCFG_CLOE);
>  			}
> +		} else if (gpriv->fd_only_mode) {
> +			rcar_canfd_set_bit_reg(&gpriv->fcbase[ch].cfdcfg,
> +					       RCANFD_GEN4_FDCFG_FDOE);
>  		}
>  	}
>

For the record, this part is way too confusing. Long term, it really
needs to go to separate functions... and be refactored.

Best regards,
								Pavel

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

  reply	other threads:[~2026-03-09  8:16 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-09  7:51 [PATCH 6.12.y-cip 0/6] Add suspend/resume support for RZ/G3E ICU Biju
2026-03-09  7:51 ` [PATCH 6.12.y-cip 1/6] irqchip/renesas-rzv2h: Prevent TINT spurious interrupt during resume Biju
2026-03-09  7:51 ` [PATCH 6.12.y-cip 2/6] irqchip/renesas-rzv2h: Remove unneeded includes Biju
2026-03-09  7:51 ` [PATCH 6.12.y-cip 3/6] irqchip/renesas-rzv2h: Add suspend/resume support Biju
2026-03-09  7:51 ` [PATCH 6.12.y-cip 4/6] dt-bindings: can: renesas,rcar-canfd: Document renesas,fd-only property Biju
2026-03-09  7:51 ` [PATCH 6.12.y-cip 5/6] dt-bindings: can: renesas,rcar-canfd: Specify reset-names Biju
2026-03-09  7:51 ` [PATCH 6.12.y-cip 6/6] can: rcar_canfd: Add support for FD-Only mode Biju
2026-03-09  8:16   ` Pavel Machek [this message]
2026-03-09  8:29     ` [cip-dev] " Biju Das
2026-03-09  8:17 ` [PATCH 6.12.y-cip 0/6] Add suspend/resume support for RZ/G3E ICU Pavel Machek
2026-03-12  1:53   ` [cip-dev] " nobuhiro.iwamatsu.x90

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aa6B3tuP6oufeYb6@duo.ucw.cz \
    --to=pavel@nabladev.com \
    --cc=biju.das.au@gmail.com \
    --cc=biju.das.jz@bp.renesas.com \
    --cc=cip-dev@lists.cip-project.org \
    --cc=nobuhiro.iwamatsu.x90@mail.toshiba \
    --cc=prabhakar.mahadev-lad.rj@bp.renesas.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox