netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/6] More CAN support for RZ/G2 devices
@ 2019-06-14 11:53 Fabrizio Castro
  2019-06-14 11:53 ` [PATCH 1/6] dt-bindings: can: rcar_canfd: document r8a774a1 support Fabrizio Castro
  2019-06-14 11:53 ` [PATCH 2/6] dt-bindings: can: rcar_can: Complete documentation for RZ/G2[EM] Fabrizio Castro
  0 siblings, 2 replies; 6+ messages in thread
From: Fabrizio Castro @ 2019-06-14 11:53 UTC (permalink / raw)
  To: Simon Horman, Geert Uytterhoeven, Wolfgang Grandegger,
	Marc Kleine-Budde, Rob Herring, Mark Rutland
  Cc: Fabrizio Castro, David S. Miller, Magnus Damm, linux-can, netdev,
	devicetree, linux-renesas-soc, Chris Paterson, Biju Das,
	xu_shunji

Dear All,

This series adds CAN and CANFD support to the HiHope RZ/G2M, and also
improves SoC support for the RZ/G2E.
Please note that I wasn't able to test CAN-FD mode but only classical
CAN mode with the CANFD IP, my unit unfortunately comes with CAN-FD
mode disabled in HW, but the CANFD IP is working and responding
correctly while in classical mode.

Please note that this work depends on:
https://patchwork.kernel.org/cover/10986911/
https://patchwork.kernel.org/cover/10990113/

Thanks,
Fab

Fabrizio Castro (6):
  dt-bindings: can: rcar_canfd: document r8a774a1 support
  dt-bindings: can: rcar_can: Complete documentation for RZ/G2[EM]
  arm64: dts: renesas: r8a774c0: Add missing assigned-clocks for CAN[01]
  arm64: dts: renesas: r8a774a1: Add missing assigned-clocks for CAN[01]
  arm64: dts: renesas: r8a774a1: Add CANFD support
  arm64: dts: renesas: hihope-rzg2-ex: Enable CAN interfaces

 .../devicetree/bindings/net/can/rcar_can.txt       |  2 +-
 .../devicetree/bindings/net/can/rcar_canfd.txt     |  9 ++++---
 arch/arm64/boot/dts/renesas/hihope-rzg2-ex.dtsi    | 22 ++++++++++++++++
 arch/arm64/boot/dts/renesas/r8a774a1.dtsi          | 29 ++++++++++++++++++++++
 arch/arm64/boot/dts/renesas/r8a774c0.dtsi          |  4 +++
 5 files changed, 61 insertions(+), 5 deletions(-)

-- 
2.7.4


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH 1/6] dt-bindings: can: rcar_canfd: document r8a774a1 support
  2019-06-14 11:53 [PATCH 0/6] More CAN support for RZ/G2 devices Fabrizio Castro
@ 2019-06-14 11:53 ` Fabrizio Castro
  2019-06-17  9:30   ` Simon Horman
  2019-06-14 11:53 ` [PATCH 2/6] dt-bindings: can: rcar_can: Complete documentation for RZ/G2[EM] Fabrizio Castro
  1 sibling, 1 reply; 6+ messages in thread
From: Fabrizio Castro @ 2019-06-14 11:53 UTC (permalink / raw)
  To: Simon Horman, Geert Uytterhoeven, Wolfgang Grandegger,
	Marc Kleine-Budde, Rob Herring, Mark Rutland
  Cc: Fabrizio Castro, David S. Miller, linux-can, netdev, devicetree,
	Chris Paterson, Biju Das, linux-renesas-soc

Document the support for rcar_canfd on R8A774A1 SoC devices.

Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>
---
Hello Simon,

I think it would make more sense if this patch went through you as it
sits on series:
https://lkml.org/lkml/2019/5/9/941

Do you think that's doable?

Thanks,
Fab

 Documentation/devicetree/bindings/net/can/rcar_canfd.txt | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/Documentation/devicetree/bindings/net/can/rcar_canfd.txt b/Documentation/devicetree/bindings/net/can/rcar_canfd.txt
index 32f051f..00afaff 100644
--- a/Documentation/devicetree/bindings/net/can/rcar_canfd.txt
+++ b/Documentation/devicetree/bindings/net/can/rcar_canfd.txt
@@ -4,6 +4,7 @@ Renesas R-Car CAN FD controller Device Tree Bindings
 Required properties:
 - compatible: Must contain one or more of the following:
   - "renesas,rcar-gen3-canfd" for R-Car Gen3 and RZ/G2 compatible controllers.
+  - "renesas,r8a774a1-canfd" for R8A774A1 (RZ/G2M) compatible controller.
   - "renesas,r8a774c0-canfd" for R8A774C0 (RZ/G2E) compatible controller.
   - "renesas,r8a7795-canfd" for R8A7795 (R-Car H3) compatible controller.
   - "renesas,r8a7796-canfd" for R8A7796 (R-Car M3-W) compatible controller.
@@ -32,10 +33,10 @@ enable/disable the respective channel.
 Required properties for "renesas,r8a774c0-canfd", "renesas,r8a7795-canfd",
 "renesas,r8a7796-canfd", "renesas,r8a77965-canfd", and "renesas,r8a77990-canfd"
 compatible:
-In R8A774C0, R8A7795, R8A7796, R8A77965, and R8A77990 SoCs, canfd clock is a
-div6 clock and can be used by both CAN and CAN FD controller at the same time.
-It needs to be scaled to maximum frequency if any of these controllers use it.
-This is done using the below properties:
+In R8A774A1, R8A774C0, R8A7795, R8A7796, R8A77965, and R8A77990 SoCs, canfd
+clock is a div6 clock and can be used by both CAN and CAN FD controller at the
+same time. It needs to be scaled to maximum frequency if any of these
+controllers use it. This is done using the below properties:
 
 - assigned-clocks: phandle of canfd clock.
 - assigned-clock-rates: maximum frequency of this clock.
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/6] dt-bindings: can: rcar_can: Complete documentation for RZ/G2[EM]
  2019-06-14 11:53 [PATCH 0/6] More CAN support for RZ/G2 devices Fabrizio Castro
  2019-06-14 11:53 ` [PATCH 1/6] dt-bindings: can: rcar_canfd: document r8a774a1 support Fabrizio Castro
@ 2019-06-14 11:53 ` Fabrizio Castro
  2019-07-08 12:56   ` Geert Uytterhoeven
  1 sibling, 1 reply; 6+ messages in thread
From: Fabrizio Castro @ 2019-06-14 11:53 UTC (permalink / raw)
  To: Simon Horman, Geert Uytterhoeven, Wolfgang Grandegger,
	Marc Kleine-Budde, Rob Herring, Mark Rutland
  Cc: Fabrizio Castro, David S. Miller, linux-can, netdev, devicetree,
	Chris Paterson, Biju Das, linux-renesas-soc

Add missing RZ/G2[EM] CANFD clock specific documentation.

Fixes: 868b7c0f43e6 ("dt-bindings: can: rcar_can: Add r8a774a1 support")
Fixes: 0c11e7d0f51c ("dt-bindings: can: rcar_can: Add r8a774c0 support")
Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>
---
Hello Simon,

I think it would make more sense if this patch went through you as it
sits on series:
https://lkml.org/lkml/2019/5/9/941

Do you think that's doable?

Thanks,
Fab

 Documentation/devicetree/bindings/net/can/rcar_can.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/net/can/rcar_can.txt b/Documentation/devicetree/bindings/net/can/rcar_can.txt
index b463e12..e1f315a 100644
--- a/Documentation/devicetree/bindings/net/can/rcar_can.txt
+++ b/Documentation/devicetree/bindings/net/can/rcar_can.txt
@@ -33,7 +33,7 @@ Required properties:
 - pinctrl-0: pin control group to be used for this controller.
 - pinctrl-names: must be "default".
 
-Required properties for R8A7795, R8A7796 and R8A77965:
+Required properties for R8A774A1, R8A774C0, R8A7795, R8A7796 and R8A77965:
 For the denoted SoCs, "clkp2" can be CANFD clock. This is a div6 clock and can
 be used by both CAN and CAN FD controller at the same time. It needs to be
 scaled to maximum frequency if any of these controllers use it. This is done
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/6] dt-bindings: can: rcar_canfd: document r8a774a1 support
  2019-06-14 11:53 ` [PATCH 1/6] dt-bindings: can: rcar_canfd: document r8a774a1 support Fabrizio Castro
@ 2019-06-17  9:30   ` Simon Horman
  2019-07-08 12:55     ` Geert Uytterhoeven
  0 siblings, 1 reply; 6+ messages in thread
From: Simon Horman @ 2019-06-17  9:30 UTC (permalink / raw)
  To: Fabrizio Castro, David S. Miller
  Cc: Geert Uytterhoeven, Wolfgang Grandegger, Marc Kleine-Budde,
	Rob Herring, Mark Rutland, linux-can, netdev, devicetree,
	Chris Paterson, Biju Das, linux-renesas-soc

On Fri, Jun 14, 2019 at 12:53:29PM +0100, Fabrizio Castro wrote:
> Document the support for rcar_canfd on R8A774A1 SoC devices.
> 
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>
> ---
> Hello Simon,
> 
> I think it would make more sense if this patch went through you as it
> sits on series:
> https://lkml.org/lkml/2019/5/9/941
> 
> Do you think that's doable?

That seems reasonable to me.

Dave are you happy with me taking this, and 2/6, through
the renesas tree?

> 
> Thanks,
> Fab
> 
>  Documentation/devicetree/bindings/net/can/rcar_canfd.txt | 9 +++++----
>  1 file changed, 5 insertions(+), 4 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/net/can/rcar_canfd.txt b/Documentation/devicetree/bindings/net/can/rcar_canfd.txt
> index 32f051f..00afaff 100644
> --- a/Documentation/devicetree/bindings/net/can/rcar_canfd.txt
> +++ b/Documentation/devicetree/bindings/net/can/rcar_canfd.txt
> @@ -4,6 +4,7 @@ Renesas R-Car CAN FD controller Device Tree Bindings
>  Required properties:
>  - compatible: Must contain one or more of the following:
>    - "renesas,rcar-gen3-canfd" for R-Car Gen3 and RZ/G2 compatible controllers.
> +  - "renesas,r8a774a1-canfd" for R8A774A1 (RZ/G2M) compatible controller.
>    - "renesas,r8a774c0-canfd" for R8A774C0 (RZ/G2E) compatible controller.
>    - "renesas,r8a7795-canfd" for R8A7795 (R-Car H3) compatible controller.
>    - "renesas,r8a7796-canfd" for R8A7796 (R-Car M3-W) compatible controller.
> @@ -32,10 +33,10 @@ enable/disable the respective channel.
>  Required properties for "renesas,r8a774c0-canfd", "renesas,r8a7795-canfd",
>  "renesas,r8a7796-canfd", "renesas,r8a77965-canfd", and "renesas,r8a77990-canfd"
>  compatible:
> -In R8A774C0, R8A7795, R8A7796, R8A77965, and R8A77990 SoCs, canfd clock is a
> -div6 clock and can be used by both CAN and CAN FD controller at the same time.
> -It needs to be scaled to maximum frequency if any of these controllers use it.
> -This is done using the below properties:
> +In R8A774A1, R8A774C0, R8A7795, R8A7796, R8A77965, and R8A77990 SoCs, canfd
> +clock is a div6 clock and can be used by both CAN and CAN FD controller at the
> +same time. It needs to be scaled to maximum frequency if any of these
> +controllers use it. This is done using the below properties:
>  
>  - assigned-clocks: phandle of canfd clock.
>  - assigned-clock-rates: maximum frequency of this clock.
> -- 
> 2.7.4
> 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/6] dt-bindings: can: rcar_canfd: document r8a774a1 support
  2019-06-17  9:30   ` Simon Horman
@ 2019-07-08 12:55     ` Geert Uytterhoeven
  0 siblings, 0 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2019-07-08 12:55 UTC (permalink / raw)
  To: Simon Horman
  Cc: Fabrizio Castro, David S. Miller, Geert Uytterhoeven,
	Wolfgang Grandegger, Marc Kleine-Budde, Rob Herring,
	Mark Rutland, linux-can, netdev,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Chris Paterson, Biju Das, Linux-Renesas

On Mon, Jun 17, 2019 at 11:30 AM Simon Horman <horms@verge.net.au> wrote:
> On Fri, Jun 14, 2019 at 12:53:29PM +0100, Fabrizio Castro wrote:
> > Document the support for rcar_canfd on R8A774A1 SoC devices.
> >
> > Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> > Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

> > ---
> > Hello Simon,
> >
> > I think it would make more sense if this patch went through you as it
> > sits on series:
> > https://lkml.org/lkml/2019/5/9/941
> >
> > Do you think that's doable?
>
> That seems reasonable to me.
>
> Dave are you happy with me taking this, and 2/6, through
> the renesas tree?

As the previous change to this file was acked by Dave, and went in through
the Renesas tree, have I applied this patch and patch 2/6, and queued
it for v5.4.

Thanks!

> >  Documentation/devicetree/bindings/net/can/rcar_canfd.txt | 9 +++++----
> >  1 file changed, 5 insertions(+), 4 deletions(-)
> >
> > diff --git a/Documentation/devicetree/bindings/net/can/rcar_canfd.txt b/Documentation/devicetree/bindings/net/can/rcar_canfd.txt
> > index 32f051f..00afaff 100644
> > --- a/Documentation/devicetree/bindings/net/can/rcar_canfd.txt
> > +++ b/Documentation/devicetree/bindings/net/can/rcar_canfd.txt
> > @@ -4,6 +4,7 @@ Renesas R-Car CAN FD controller Device Tree Bindings
> >  Required properties:
> >  - compatible: Must contain one or more of the following:
> >    - "renesas,rcar-gen3-canfd" for R-Car Gen3 and RZ/G2 compatible controllers.
> > +  - "renesas,r8a774a1-canfd" for R8A774A1 (RZ/G2M) compatible controller.
> >    - "renesas,r8a774c0-canfd" for R8A774C0 (RZ/G2E) compatible controller.
> >    - "renesas,r8a7795-canfd" for R8A7795 (R-Car H3) compatible controller.
> >    - "renesas,r8a7796-canfd" for R8A7796 (R-Car M3-W) compatible controller.
> > @@ -32,10 +33,10 @@ enable/disable the respective channel.
> >  Required properties for "renesas,r8a774c0-canfd", "renesas,r8a7795-canfd",
> >  "renesas,r8a7796-canfd", "renesas,r8a77965-canfd", and "renesas,r8a77990-canfd"
> >  compatible:
> > -In R8A774C0, R8A7795, R8A7796, R8A77965, and R8A77990 SoCs, canfd clock is a
> > -div6 clock and can be used by both CAN and CAN FD controller at the same time.
> > -It needs to be scaled to maximum frequency if any of these controllers use it.
> > -This is done using the below properties:
> > +In R8A774A1, R8A774C0, R8A7795, R8A7796, R8A77965, and R8A77990 SoCs, canfd
> > +clock is a div6 clock and can be used by both CAN and CAN FD controller at the
> > +same time. It needs to be scaled to maximum frequency if any of these
> > +controllers use it. This is done using the below properties:
> >
> >  - assigned-clocks: phandle of canfd clock.
> >  - assigned-clock-rates: maximum frequency of this clock.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 2/6] dt-bindings: can: rcar_can: Complete documentation for RZ/G2[EM]
  2019-06-14 11:53 ` [PATCH 2/6] dt-bindings: can: rcar_can: Complete documentation for RZ/G2[EM] Fabrizio Castro
@ 2019-07-08 12:56   ` Geert Uytterhoeven
  0 siblings, 0 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2019-07-08 12:56 UTC (permalink / raw)
  To: Fabrizio Castro
  Cc: Simon Horman, Geert Uytterhoeven, Wolfgang Grandegger,
	Marc Kleine-Budde, Rob Herring, Mark Rutland, David S. Miller,
	linux-can, netdev,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Chris Paterson, Biju Das, Linux-Renesas

On Fri, Jun 14, 2019 at 1:53 PM Fabrizio Castro
<fabrizio.castro@bp.renesas.com> wrote:
> Add missing RZ/G2[EM] CANFD clock specific documentation.
>
> Fixes: 868b7c0f43e6 ("dt-bindings: can: rcar_can: Add r8a774a1 support")
> Fixes: 0c11e7d0f51c ("dt-bindings: can: rcar_can: Add r8a774c0 support")
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
I.e. applied and queued for v5.4.

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-07-08 12:56 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-14 11:53 [PATCH 0/6] More CAN support for RZ/G2 devices Fabrizio Castro
2019-06-14 11:53 ` [PATCH 1/6] dt-bindings: can: rcar_canfd: document r8a774a1 support Fabrizio Castro
2019-06-17  9:30   ` Simon Horman
2019-07-08 12:55     ` Geert Uytterhoeven
2019-06-14 11:53 ` [PATCH 2/6] dt-bindings: can: rcar_can: Complete documentation for RZ/G2[EM] Fabrizio Castro
2019-07-08 12:56   ` Geert Uytterhoeven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).