diff mbox series

[v5,4/6] ARM: dts: bcm2711: Enable V3D

Message ID 20220601110249.569540-5-pbrobinson@gmail.com (mailing list archive)
State New, archived
Headers show
Series Raspberry PI 4 V3D enablement | expand

Commit Message

Peter Robinson June 1, 2022, 11:02 a.m. UTC
This adds the entry for V3D for bcm2711 (used in the Raspberry Pi 4)
and the associated firmware clock entry.

Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
---
Changes since v5:
- Move the firmware clock to bcm2711-rpi.dtsi

 arch/arm/boot/dts/bcm2711-rpi.dtsi |  4 ++++
 arch/arm/boot/dts/bcm2711.dtsi     | 11 +++++++++++
 2 files changed, 15 insertions(+)

Comments

Stefan Wahren June 2, 2022, 12:04 p.m. UTC | #1
Hi Peter,

Am 01.06.22 um 13:02 schrieb Peter Robinson:
> This adds the entry for V3D for bcm2711 (used in the Raspberry Pi 4)
> and the associated firmware clock entry.
>
> Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
> ---
> Changes since v5:
> - Move the firmware clock to bcm2711-rpi.dtsi
>
>   arch/arm/boot/dts/bcm2711-rpi.dtsi |  4 ++++
>   arch/arm/boot/dts/bcm2711.dtsi     | 11 +++++++++++
>   2 files changed, 15 insertions(+)
>
> diff --git a/arch/arm/boot/dts/bcm2711-rpi.dtsi b/arch/arm/boot/dts/bcm2711-rpi.dtsi
> index ca266c5d9f9b..98817a6675b9 100644
> --- a/arch/arm/boot/dts/bcm2711-rpi.dtsi
> +++ b/arch/arm/boot/dts/bcm2711-rpi.dtsi
> @@ -69,6 +69,10 @@ blconfig: nvram@0 {
>   	};
>   };
>   
> +&v3d {
> +	clocks = <&firmware_clocks 5>;
> +};
> +
>   &vchiq {
>   	interrupts = <GIC_SPI 34 IRQ_TYPE_LEVEL_HIGH>;
>   };
> diff --git a/arch/arm/boot/dts/bcm2711.dtsi b/arch/arm/boot/dts/bcm2711.dtsi
> index 89af57482bc8..177662257b16 100644
> --- a/arch/arm/boot/dts/bcm2711.dtsi
> +++ b/arch/arm/boot/dts/bcm2711.dtsi
> @@ -601,6 +601,17 @@ genet_mdio: mdio@e14 {
>   				#size-cells = <0x0>;
>   			};
>   		};
> +
> +		v3d: gpu@7ec00000 {
> +			compatible = "brcm,bcm2711-v3d";

unfortunately this doesn't match with patch #3 anymore. Except of this 
everything looks good here.

Stefan

> +			reg = <0x0 0x7ec00000 0x4000>,
> +			      <0x0 0x7ec04000 0x4000>;
> +			reg-names = "hub", "core0";
> +
> +			power-domains = <&pm BCM2835_POWER_DOMAIN_GRAFX_V3D>;
> +			resets = <&pm BCM2835_RESET_V3D>;
> +			interrupts = <GIC_SPI 74 IRQ_TYPE_LEVEL_HIGH>;
> +		};
>   	};
>   };
>
Peter Robinson June 2, 2022, 1:32 p.m. UTC | #2
Hi Stefan,

> Am 01.06.22 um 13:02 schrieb Peter Robinson:
> > This adds the entry for V3D for bcm2711 (used in the Raspberry Pi 4)
> > and the associated firmware clock entry.
> >
> > Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> > Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
> > ---
> > Changes since v5:
> > - Move the firmware clock to bcm2711-rpi.dtsi
> >
> >   arch/arm/boot/dts/bcm2711-rpi.dtsi |  4 ++++
> >   arch/arm/boot/dts/bcm2711.dtsi     | 11 +++++++++++
> >   2 files changed, 15 insertions(+)
> >
> > diff --git a/arch/arm/boot/dts/bcm2711-rpi.dtsi b/arch/arm/boot/dts/bcm2711-rpi.dtsi
> > index ca266c5d9f9b..98817a6675b9 100644
> > --- a/arch/arm/boot/dts/bcm2711-rpi.dtsi
> > +++ b/arch/arm/boot/dts/bcm2711-rpi.dtsi
> > @@ -69,6 +69,10 @@ blconfig: nvram@0 {
> >       };
> >   };
> >
> > +&v3d {
> > +     clocks = <&firmware_clocks 5>;
> > +};
> > +
> >   &vchiq {
> >       interrupts = <GIC_SPI 34 IRQ_TYPE_LEVEL_HIGH>;
> >   };
> > diff --git a/arch/arm/boot/dts/bcm2711.dtsi b/arch/arm/boot/dts/bcm2711.dtsi
> > index 89af57482bc8..177662257b16 100644
> > --- a/arch/arm/boot/dts/bcm2711.dtsi
> > +++ b/arch/arm/boot/dts/bcm2711.dtsi
> > @@ -601,6 +601,17 @@ genet_mdio: mdio@e14 {
> >                               #size-cells = <0x0>;
> >                       };
> >               };
> > +
> > +             v3d: gpu@7ec00000 {
> > +                     compatible = "brcm,bcm2711-v3d";
>
> unfortunately this doesn't match with patch #3 anymore. Except of this
> everything looks good here.

Good catch, have updated locally, I'll send out a new rev tomorrow,
will give it a day to see if there's other feedback,

P

> Stefan
>
> > +                     reg = <0x0 0x7ec00000 0x4000>,
> > +                           <0x0 0x7ec04000 0x4000>;
> > +                     reg-names = "hub", "core0";
> > +
> > +                     power-domains = <&pm BCM2835_POWER_DOMAIN_GRAFX_V3D>;
> > +                     resets = <&pm BCM2835_RESET_V3D>;
> > +                     interrupts = <GIC_SPI 74 IRQ_TYPE_LEVEL_HIGH>;
> > +             };
> >       };
> >   };
> >
Javier Martinez Canillas June 2, 2022, 11:07 p.m. UTC | #3
On 6/1/22 13:02, Peter Robinson wrote:
> This adds the entry for V3D for bcm2711 (used in the Raspberry Pi 4)
> and the associated firmware clock entry.
> 
> Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
> ---

Once you fix the typo mentioned by Stefan already:

Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
diff mbox series

Patch

diff --git a/arch/arm/boot/dts/bcm2711-rpi.dtsi b/arch/arm/boot/dts/bcm2711-rpi.dtsi
index ca266c5d9f9b..98817a6675b9 100644
--- a/arch/arm/boot/dts/bcm2711-rpi.dtsi
+++ b/arch/arm/boot/dts/bcm2711-rpi.dtsi
@@ -69,6 +69,10 @@  blconfig: nvram@0 {
 	};
 };
 
+&v3d {
+	clocks = <&firmware_clocks 5>;
+};
+
 &vchiq {
 	interrupts = <GIC_SPI 34 IRQ_TYPE_LEVEL_HIGH>;
 };
diff --git a/arch/arm/boot/dts/bcm2711.dtsi b/arch/arm/boot/dts/bcm2711.dtsi
index 89af57482bc8..177662257b16 100644
--- a/arch/arm/boot/dts/bcm2711.dtsi
+++ b/arch/arm/boot/dts/bcm2711.dtsi
@@ -601,6 +601,17 @@  genet_mdio: mdio@e14 {
 				#size-cells = <0x0>;
 			};
 		};
+
+		v3d: gpu@7ec00000 {
+			compatible = "brcm,bcm2711-v3d";
+			reg = <0x0 0x7ec00000 0x4000>,
+			      <0x0 0x7ec04000 0x4000>;
+			reg-names = "hub", "core0";
+
+			power-domains = <&pm BCM2835_POWER_DOMAIN_GRAFX_V3D>;
+			resets = <&pm BCM2835_RESET_V3D>;
+			interrupts = <GIC_SPI 74 IRQ_TYPE_LEVEL_HIGH>;
+		};
 	};
 };