2020-04-15 22:37:43

by H. Nikolaus Schaller

[permalink] [raw]
Subject: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node

From: Jonathan Bakker <[email protected]>

to add support for SGX540 GPU.

Signed-off-by: Jonathan Bakker <[email protected]>
Signed-off-by: H. Nikolaus Schaller <[email protected]>
---
arch/arm/boot/dts/s5pv210.dtsi | 15 +++++++++++++++
1 file changed, 15 insertions(+)

diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi
index 2ad642f51fd9..e7fc709c0cca 100644
--- a/arch/arm/boot/dts/s5pv210.dtsi
+++ b/arch/arm/boot/dts/s5pv210.dtsi
@@ -512,6 +512,21 @@ vic3: interrupt-controller@f2300000 {
#interrupt-cells = <1>;
};

+ g3d: g3d@f3000000 {
+ compatible = "samsung,s5pv210-sgx540-120";
+ reg = <0xf3000000 0x10000>;
+ interrupt-parent = <&vic2>;
+ interrupts = <10>;
+ clock-names = "sclk";
+ clocks = <&clocks CLK_G3D>;
+
+ power-domains = <&pd S5PV210_PD_G3D>;
+
+ assigned-clocks = <&clocks MOUT_G3D>, <&clocks DOUT_G3D>;
+ assigned-clock-rates = <0>, <66700000>;
+ assigned-clock-parents = <&clocks MOUT_MPLL>;
+ };
+
fimd: fimd@f8000000 {
compatible = "samsung,s5pv210-fimd";
interrupt-parent = <&vic2>;
--
2.25.1


2020-04-15 22:47:57

by Sergei Shtylyov

[permalink] [raw]
Subject: Re: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node

Hello!

On 15.04.2020 11:35, H. Nikolaus Schaller wrote:

> From: Jonathan Bakker <[email protected]>
>
> to add support for SGX540 GPU.
>
> Signed-off-by: Jonathan Bakker <[email protected]>
> Signed-off-by: H. Nikolaus Schaller <[email protected]>
> ---
> arch/arm/boot/dts/s5pv210.dtsi | 15 +++++++++++++++
> 1 file changed, 15 insertions(+)
>
> diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi
> index 2ad642f51fd9..e7fc709c0cca 100644
> --- a/arch/arm/boot/dts/s5pv210.dtsi
> +++ b/arch/arm/boot/dts/s5pv210.dtsi
> @@ -512,6 +512,21 @@ vic3: interrupt-controller@f2300000 {
> #interrupt-cells = <1>;
> };
>
> + g3d: g3d@f3000000 {

Should be named generically, "gpu@f3000000", according to the DT spec 0.2,
section 2.2.2. It's either "gpu" or "display" TTBOMK...

[...]

MBR, Sergei

2020-04-15 22:50:57

by H. Nikolaus Schaller

[permalink] [raw]
Subject: Re: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node

Hi Sergei and Jonathan,

> Am 15.04.2020 um 11:15 schrieb Sergei Shtylyov <[email protected]>:
>
> Hello!
>
> On 15.04.2020 11:35, H. Nikolaus Schaller wrote:
>
>> From: Jonathan Bakker <[email protected]>
>> to add support for SGX540 GPU.
>> Signed-off-by: Jonathan Bakker <[email protected]>
>> Signed-off-by: H. Nikolaus Schaller <[email protected]>
>> ---
>> arch/arm/boot/dts/s5pv210.dtsi | 15 +++++++++++++++
>> 1 file changed, 15 insertions(+)
>> diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi
>> index 2ad642f51fd9..e7fc709c0cca 100644
>> --- a/arch/arm/boot/dts/s5pv210.dtsi
>> +++ b/arch/arm/boot/dts/s5pv210.dtsi
>> @@ -512,6 +512,21 @@ vic3: interrupt-controller@f2300000 {
>> #interrupt-cells = <1>;
>> };
>> + g3d: g3d@f3000000 {
>
> Should be named generically, "gpu@f3000000", according to the DT spec 0.2, section 2.2.2. It's either "gpu" or "display" TTBOMK...

Yes, you are right and we have named it such for all other
devices in this series. I just missed that.

Jonathan, if you are ok, I'll fix that.

>
> [...]
>
> MBR, Sergei

BR and thanks,
Nikolaus

2020-04-15 23:08:11

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node

On Wed, 15 Apr 2020 at 10:36, H. Nikolaus Schaller <[email protected]> wrote:
>
> From: Jonathan Bakker <[email protected]>
>
> to add support for SGX540 GPU.

Do not continue the subject in commit msg like it is one sentence.
These are two separate sentences, so commit msg starts with capital
letter and it is sentence by itself.

> Signed-off-by: Jonathan Bakker <[email protected]>
> Signed-off-by: H. Nikolaus Schaller <[email protected]>
> ---
> arch/arm/boot/dts/s5pv210.dtsi | 15 +++++++++++++++
> 1 file changed, 15 insertions(+)
>
> diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi
> index 2ad642f51fd9..e7fc709c0cca 100644
> --- a/arch/arm/boot/dts/s5pv210.dtsi
> +++ b/arch/arm/boot/dts/s5pv210.dtsi
> @@ -512,6 +512,21 @@ vic3: interrupt-controller@f2300000 {
> #interrupt-cells = <1>;
> };
>
> + g3d: g3d@f3000000 {
> + compatible = "samsung,s5pv210-sgx540-120";
> + reg = <0xf3000000 0x10000>;
> + interrupt-parent = <&vic2>;
> + interrupts = <10>;
> + clock-names = "sclk";
> + clocks = <&clocks CLK_G3D>;

Not part of bindings, please remove or add to the bindings.

> +
> + power-domains = <&pd S5PV210_PD_G3D>;

Ditto

> +
> + assigned-clocks = <&clocks MOUT_G3D>, <&clocks DOUT_G3D>;
> + assigned-clock-rates = <0>, <66700000>;
> + assigned-clock-parents = <&clocks MOUT_MPLL>;

Probably this should have status disabled because you do not set
regulator supply.

Best regards,
Krzysztof

2020-04-15 23:57:00

by H. Nikolaus Schaller

[permalink] [raw]
Subject: Re: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node


> Am 15.04.2020 um 13:49 schrieb Krzysztof Kozlowski <[email protected]>:
>
> On Wed, 15 Apr 2020 at 10:36, H. Nikolaus Schaller <[email protected]> wrote:
>>
>> From: Jonathan Bakker <[email protected]>
>>
>> to add support for SGX540 GPU.
>
> Do not continue the subject in commit msg like it is one sentence.
> These are two separate sentences, so commit msg starts with capital
> letter and it is sentence by itself.
>
>> Signed-off-by: Jonathan Bakker <[email protected]>
>> Signed-off-by: H. Nikolaus Schaller <[email protected]>
>> ---
>> arch/arm/boot/dts/s5pv210.dtsi | 15 +++++++++++++++
>> 1 file changed, 15 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi
>> index 2ad642f51fd9..e7fc709c0cca 100644
>> --- a/arch/arm/boot/dts/s5pv210.dtsi
>> +++ b/arch/arm/boot/dts/s5pv210.dtsi
>> @@ -512,6 +512,21 @@ vic3: interrupt-controller@f2300000 {
>> #interrupt-cells = <1>;
>> };
>>
>> + g3d: g3d@f3000000 {
>> + compatible = "samsung,s5pv210-sgx540-120";
>> + reg = <0xf3000000 0x10000>;
>> + interrupt-parent = <&vic2>;
>> + interrupts = <10>;
>> + clock-names = "sclk";
>> + clocks = <&clocks CLK_G3D>;
>
> Not part of bindings, please remove or add to the bindings.

Well, the bindings should describe what is common for all SoC
and they are quite different in what they need in addition.

Thererfore we have no "additionalProperties: false" in the
bindings [PATCH v6 01/12].

>
>> +
>> + power-domains = <&pd S5PV210_PD_G3D>;
>
> Ditto

In this case it might be possible to add the clock/power-domains
etc. to a wrapper node compatible to "simple-pm-bus" or similar
and make the gpu a child of it.

@Jontahan: can you please give it a try?


>
>> +
>> + assigned-clocks = <&clocks MOUT_G3D>, <&clocks DOUT_G3D>;
>> + assigned-clock-rates = <0>, <66700000>;
>> + assigned-clock-parents = <&clocks MOUT_MPLL>;
>
> Probably this should have status disabled because you do not set
> regulator supply.
>
> Best regards,
> Krzysztof

BR and thanks,
Nikolaus

2020-04-16 00:07:45

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node

On Wed, Apr 15, 2020 at 02:50:31PM +0200, H. Nikolaus Schaller wrote:
>
> > Am 15.04.2020 um 13:49 schrieb Krzysztof Kozlowski <[email protected]>:
> >
> > On Wed, 15 Apr 2020 at 10:36, H. Nikolaus Schaller <[email protected]> wrote:
> >>
> >> From: Jonathan Bakker <[email protected]>
> >>
> >> to add support for SGX540 GPU.
> >
> > Do not continue the subject in commit msg like it is one sentence.
> > These are two separate sentences, so commit msg starts with capital
> > letter and it is sentence by itself.
> >
> >> Signed-off-by: Jonathan Bakker <[email protected]>
> >> Signed-off-by: H. Nikolaus Schaller <[email protected]>
> >> ---
> >> arch/arm/boot/dts/s5pv210.dtsi | 15 +++++++++++++++
> >> 1 file changed, 15 insertions(+)
> >>
> >> diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi
> >> index 2ad642f51fd9..e7fc709c0cca 100644
> >> --- a/arch/arm/boot/dts/s5pv210.dtsi
> >> +++ b/arch/arm/boot/dts/s5pv210.dtsi
> >> @@ -512,6 +512,21 @@ vic3: interrupt-controller@f2300000 {
> >> #interrupt-cells = <1>;
> >> };
> >>
> >> + g3d: g3d@f3000000 {
> >> + compatible = "samsung,s5pv210-sgx540-120";
> >> + reg = <0xf3000000 0x10000>;
> >> + interrupt-parent = <&vic2>;
> >> + interrupts = <10>;
> >> + clock-names = "sclk";
> >> + clocks = <&clocks CLK_G3D>;
> >
> > Not part of bindings, please remove or add to the bindings.
>
> Well, the bindings should describe what is common for all SoC
> and they are quite different in what they need in addition.
>
> Thererfore we have no "additionalProperties: false" in the
> bindings [PATCH v6 01/12].

If these properties are needed for Exynos-specific implementation, they
should be in the bindings. If they are not needed, they should not be
here.

Take a look at midgard bindings for example. This is a nice starting
point for these here.

Best regards,
Krzysztof

2020-04-16 00:44:51

by Jonathan Bakker

[permalink] [raw]
Subject: Re: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node

Hi Nikolaus,

On 2020-04-15 5:50 a.m., H. Nikolaus Schaller wrote:
>
>> Am 15.04.2020 um 13:49 schrieb Krzysztof Kozlowski <[email protected]>:
>>
>> On Wed, 15 Apr 2020 at 10:36, H. Nikolaus Schaller <[email protected]> wrote:
>>>
>>> From: Jonathan Bakker <[email protected]>
>>>
>>> to add support for SGX540 GPU.
>>
>> Do not continue the subject in commit msg like it is one sentence.
>> These are two separate sentences, so commit msg starts with capital
>> letter and it is sentence by itself.
>>

Sorry, that's my fault, I should know better.

Nikolaus took this from my testing tree and I apparently didn't have it in
as good as state as I should have.

>>> Signed-off-by: Jonathan Bakker <[email protected]>
>>> Signed-off-by: H. Nikolaus Schaller <[email protected]>
>>> ---
>>> arch/arm/boot/dts/s5pv210.dtsi | 15 +++++++++++++++
>>> 1 file changed, 15 insertions(+)
>>>
>>> diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi
>>> index 2ad642f51fd9..e7fc709c0cca 100644
>>> --- a/arch/arm/boot/dts/s5pv210.dtsi
>>> +++ b/arch/arm/boot/dts/s5pv210.dtsi
>>> @@ -512,6 +512,21 @@ vic3: interrupt-controller@f2300000 {
>>> #interrupt-cells = <1>;
>>> };
>>>
>>> + g3d: g3d@f3000000 {
>>> + compatible = "samsung,s5pv210-sgx540-120";
>>> + reg = <0xf3000000 0x10000>;
>>> + interrupt-parent = <&vic2>;
>>> + interrupts = <10>;
>>> + clock-names = "sclk";
>>> + clocks = <&clocks CLK_G3D>;
>>
>> Not part of bindings, please remove or add to the bindings.
>
> Well, the bindings should describe what is common for all SoC
> and they are quite different in what they need in addition.
>
> Thererfore we have no "additionalProperties: false" in the
> bindings [PATCH v6 01/12].
>
>>
>>> +
>>> + power-domains = <&pd S5PV210_PD_G3D>;
>>
>> Ditto
>
> In this case it might be possible to add the clock/power-domains
> etc. to a wrapper node compatible to "simple-pm-bus" or similar
> and make the gpu a child of it.
>
> @Jontahan: can you please give it a try?
>
>

The power-domains comes from a (so far) non-upstreamed power domain driver
for s5pv210 that I've been playing around with. It's not necessary for proper
operation as it's on by default.

Looking at simple-pm-bus, I don't really understand its purpose. Is it a way of separating
out a power domain from a main device's node? Or is it designed for when you have multiple
devices under the same power domain?

Nikolaus, I can regenerate a proper patch for you if you want that's not based on my testing tree.

>>
>>> +
>>> + assigned-clocks = <&clocks MOUT_G3D>, <&clocks DOUT_G3D>;
>>> + assigned-clock-rates = <0>, <66700000>;
>>> + assigned-clock-parents = <&clocks MOUT_MPLL>;
>>
>> Probably this should have status disabled because you do not set
>> regulator supply.

I don't believe there is a regulator on s5pv210, if there is, then it is a
fixed regulator with no control on both s5pv210 devices that I have.

The vendor driver did use the regulator framework for its power domain
implementation, but that definitely shouldn't be upstreamed.

> BR and thanks,
> Nikolaus
>

Thanks,
Jonathan

2020-04-16 09:00:24

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node

On Wed, Apr 15, 2020 at 11:17:16AM -0700, Jonathan Bakker wrote:

> >>
> >>> +
> >>> + assigned-clocks = <&clocks MOUT_G3D>, <&clocks DOUT_G3D>;
> >>> + assigned-clock-rates = <0>, <66700000>;
> >>> + assigned-clock-parents = <&clocks MOUT_MPLL>;
> >>
> >> Probably this should have status disabled because you do not set
> >> regulator supply.
>
> I don't believe there is a regulator on s5pv210, if there is, then it is a
> fixed regulator with no control on both s5pv210 devices that I have.
>
> The vendor driver did use the regulator framework for its power domain
> implementation, but that definitely shouldn't be upstreamed.

Starting with Exynos4210 usually they have separate regulator from PMIC
but maybe S5Pv210 indeed is different. Leave it then without it.

Best regards,
Krzysztof

2020-04-17 12:18:12

by H. Nikolaus Schaller

[permalink] [raw]
Subject: Re: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node

Hi Jonathan,

> Am 15.04.2020 um 20:17 schrieb Jonathan Bakker <[email protected]>:
>
> Hi Nikolaus,
>
> On 2020-04-15 5:50 a.m., H. Nikolaus Schaller wrote:
>>
>>> Am 15.04.2020 um 13:49 schrieb Krzysztof Kozlowski <[email protected]>:
>>>
>>> On Wed, 15 Apr 2020 at 10:36, H. Nikolaus Schaller <[email protected]> wrote:
>>>>
>>>> From: Jonathan Bakker <[email protected]>
>>>>
>>>> to add support for SGX540 GPU.
>>>
>>> Do not continue the subject in commit msg like it is one sentence.
>>> These are two separate sentences, so commit msg starts with capital
>>> letter and it is sentence by itself.
>>>
>
> Sorry, that's my fault, I should know better.

Mine as well...

>
> Nikolaus took this from my testing tree and I apparently didn't have it in
> as good as state as I should have.
>
>>>> Signed-off-by: Jonathan Bakker <[email protected]>
>>>> Signed-off-by: H. Nikolaus Schaller <[email protected]>
>>>> ---
>>>> arch/arm/boot/dts/s5pv210.dtsi | 15 +++++++++++++++
>>>> 1 file changed, 15 insertions(+)
>>>>
>>>> diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi
>>>> index 2ad642f51fd9..e7fc709c0cca 100644
>>>> --- a/arch/arm/boot/dts/s5pv210.dtsi
>>>> +++ b/arch/arm/boot/dts/s5pv210.dtsi
>>>> @@ -512,6 +512,21 @@ vic3: interrupt-controller@f2300000 {
>>>> #interrupt-cells = <1>;
>>>> };
>>>>
>>>> + g3d: g3d@f3000000 {
>>>> + compatible = "samsung,s5pv210-sgx540-120";
>>>> + reg = <0xf3000000 0x10000>;
>>>> + interrupt-parent = <&vic2>;
>>>> + interrupts = <10>;
>>>> + clock-names = "sclk";
>>>> + clocks = <&clocks CLK_G3D>;
>>>
>>> Not part of bindings, please remove or add to the bindings.
>>
>> Well, the bindings should describe what is common for all SoC
>> and they are quite different in what they need in addition.
>>
>> Thererfore we have no "additionalProperties: false" in the
>> bindings [PATCH v6 01/12].
>>
>>>
>>>> +
>>>> + power-domains = <&pd S5PV210_PD_G3D>;
>>>
>>> Ditto
>>
>> In this case it might be possible to add the clock/power-domains
>> etc. to a wrapper node compatible to "simple-pm-bus" or similar
>> and make the gpu a child of it.
>>
>> @Jontahan: can you please give it a try?
>>
>>
>
> The power-domains comes from a (so far) non-upstreamed power domain driver
> for s5pv210 that I've been playing around with. It's not necessary for proper
> operation as it's on by default.
>
> Looking at simple-pm-bus, I don't really understand its purpose. Is it a way of separating
> out a power domain from a main device's node? Or is it designed for when you have multiple
> devices under the same power domain?
>
> Nikolaus, I can regenerate a proper patch for you if you want that's not based on my testing tree.

Yes, please.

>
>>>
>>>> +
>>>> + assigned-clocks = <&clocks MOUT_G3D>, <&clocks DOUT_G3D>;
>>>> + assigned-clock-rates = <0>, <66700000>;
>>>> + assigned-clock-parents = <&clocks MOUT_MPLL>;
>>>
>>> Probably this should have status disabled because you do not set
>>> regulator supply.
>
> I don't believe there is a regulator on s5pv210, if there is, then it is a
> fixed regulator with no control on both s5pv210 devices that I have.
>
> The vendor driver did use the regulator framework for its power domain
> implementation, but that definitely shouldn't be upstreamed.

Ok, this means there is no need for regulators in the bindings.

BR,
Nikolaus

2020-04-22 06:04:04

by kernel test robot

[permalink] [raw]
Subject: Re: [PATCH v6 08/12] arm: dts: s5pv210: Add G3D node

Hi Nikolaus,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on robh/for-next]
[also build test ERROR on sunxi/sunxi/for-next v5.7-rc2 next-20200421]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url: https://github.com/0day-ci/linux/commits/H-Nikolaus-Schaller/ARM-MIPS-DTS-add-child-nodes-describing-the-PVRSGX-GPU-present-in-some-OMAP-SoC-and-JZ4780-and-many-more/20200416-022658
base: https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
config: arm-allmodconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=arm

If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <[email protected]>

All errors (new ones prefixed by >>):

>> Error: arch/arm/boot/dts/s5pv210.dtsi:523.25-26 syntax error
FATAL ERROR: Unable to parse input tree

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/[email protected]


Attachments:
(No filename) (1.43 kB)
.config.gz (72.71 kB)
Download all attachments