mbox

[GIT,PULL] Third Round of Renesas ARM64 Based SoC DT Updates for v4.5

Message ID cover.1450401186.git.horms+renesas@verge.net.au
State New
Headers show

Pull-request

git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas.git tags/renesas-arm64-dt3-for-v4.5

Message

Simon Horman Dec. 18, 2015, 2:29 a.m. UTC
Hi Olof, Hi Kevin, Hi Arnd,

Please consider these third round of Renesas ARM64 based SoC DT updates
for v4.5.

This pull request is based on the previous round of
such requests, tagged as renesas-arm64-dt2-for-v4.5,
which you have already pulled.


The following changes since commit 672b79312c04016481a11d4b996b4512207ffbd3:

  arm64: renesas: salvator-x: Sound DVC support (2015-11-26 11:31:43 +0900)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas.git tags/renesas-arm64-dt3-for-v4.5

for you to fetch changes up to 2eb2b5066197eab00c55dcd1132f17836e4975b2:

  arm64: renesas: r8a7795: fix SATA clock assignment (2015-12-18 10:07:29 +0900)

----------------------------------------------------------------
Third Round of Renesas ARM64 Based SoC DT Updates for v4.5

* Enable SATA
* Add salvator-x part number to DT bindings documentation
* Enable all four A57 cores instead of just one
* Enhanced audio support:
  - Use CS2000 as AUDIO_CLK_B
  - Set ak4613 In/Out pin as single-end

----------------------------------------------------------------
Gaku Inami (2):
      arm64: dts: r8a7795: Add PSCI node
      arm64: dts: r8a7795: Add Cortex-A57 CPU cores

Geert Uytterhoeven (1):
      arm64: renesas: salvator-x: Add board part number to DT bindings

Kouei Abe (2):
      arm64: dts: r8a7795: Add SATA controller node
      arm64: dts: salvator-x: Enable SATA controller

Kuninori Morimoto (2):
      arm64: renesas: salvator-x: set ak4613 In/Out pin as single-end
      arm64: renesas: salvator-x: use CS2000 as AUDIO_CLK_B

Ulrich Hecht (1):
      arm64: renesas: r8a7795: fix SATA clock assignment

Wolfram Sang (1):
      arm64: renesas: r8a7795: add internal delay for i2c IPs

Yoshifumi Hosoya (1):
      arm64: dts: r8a7795: Add pmu device nodes

 Documentation/devicetree/bindings/arm/shmobile.txt |  2 +-
 arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts | 51 +++++++++++++++++
 arch/arm64/boot/dts/renesas/r8a7795.dtsi           | 64 ++++++++++++++++++++--
 3 files changed, 110 insertions(+), 7 deletions(-)

Comments

Sudeep Holla Dec. 18, 2015, 10:16 a.m. UTC | #1
On 18/12/15 02:29, Simon Horman wrote:
> From: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
>
> Enabling the performance monitor unit on r8a7795.
>
> Signed-off-by: Masaru Nagai <masaru.nagai.vx@renesas.com>
> Signed-off-by: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
> Signed-off-by: Dirk Behme <dirk.behme@gmail.com>
> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
> ---
>   arch/arm64/boot/dts/renesas/r8a7795.dtsi | 12 ++++++++++++
>   1 file changed, 12 insertions(+)
>
> diff --git a/arch/arm64/boot/dts/renesas/r8a7795.dtsi b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> index 4d43cf31418f..b9229a49dabc 100644
> --- a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> +++ b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> @@ -230,6 +230,18 @@
>   			power-domains = <&cpg>;
>   		};
>
> +		pmu {
> +			compatible = "arm,armv8-pmuv3";

Please use arm,cortex-a57-pmu to be more specific. IIRC I mentioned this
for some shmobile platform recently.
Dirk Behme Dec. 18, 2015, 10:44 a.m. UTC | #2
On 18.12.2015 11:16, Sudeep Holla wrote:
>
>
> On 18/12/15 02:29, Simon Horman wrote:
>> From: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
>>
>> Enabling the performance monitor unit on r8a7795.
>>
>> Signed-off-by: Masaru Nagai <masaru.nagai.vx@renesas.com>
>> Signed-off-by: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
>> Signed-off-by: Dirk Behme <dirk.behme@gmail.com>
>> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
>> ---
>>   arch/arm64/boot/dts/renesas/r8a7795.dtsi | 12 ++++++++++++
>>   1 file changed, 12 insertions(+)
>>
>> diff --git a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>> b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>> index 4d43cf31418f..b9229a49dabc 100644
>> --- a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>> +++ b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>> @@ -230,6 +230,18 @@
>>               power-domains = <&cpg>;
>>           };
>>
>> +        pmu {
>> +            compatible = "arm,armv8-pmuv3";
>
> Please use arm,cortex-a57-pmu to be more specific. IIRC I mentioned this
> for some shmobile platform recently.


Yes. But as this patch has been applied already to some branches, I 
incorporated your a57-pmu hint with an additional update patch:

http://marc.info/?l=linux-sh&m=145011467914857

Feel free to squash if still possible.

Best regards

Dirk
Sudeep Holla Dec. 18, 2015, 10:47 a.m. UTC | #3
On 18/12/15 10:44, Dirk Behme wrote:
> On 18.12.2015 11:16, Sudeep Holla wrote:
>>
>>
>> On 18/12/15 02:29, Simon Horman wrote:
>>> From: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
>>>
>>> Enabling the performance monitor unit on r8a7795.
>>>
>>> Signed-off-by: Masaru Nagai <masaru.nagai.vx@renesas.com>
>>> Signed-off-by: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
>>> Signed-off-by: Dirk Behme <dirk.behme@gmail.com>
>>> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
>>> ---
>>>   arch/arm64/boot/dts/renesas/r8a7795.dtsi | 12 ++++++++++++
>>>   1 file changed, 12 insertions(+)
>>>
>>> diff --git a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>> b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>> index 4d43cf31418f..b9229a49dabc 100644
>>> --- a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>> +++ b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>> @@ -230,6 +230,18 @@
>>>               power-domains = <&cpg>;
>>>           };
>>>
>>> +        pmu {
>>> +            compatible = "arm,armv8-pmuv3";
>>
>> Please use arm,cortex-a57-pmu to be more specific. IIRC I mentioned this
>> for some shmobile platform recently.
>
>
> Yes. But as this patch has been applied already to some branches, I
> incorporated your a57-pmu hint with an additional update patch:
>
> http://marc.info/?l=linux-sh&m=145011467914857
>
> Feel free to squash if still possible.
>

Ah OK, I didn't know the exact dts name, sorry for the noise.
Better if it was posted as part of this series :)
Olof Johansson Dec. 22, 2015, 8:52 p.m. UTC | #4
On Fri, Dec 18, 2015 at 11:29:14AM +0900, Simon Horman wrote:
> Hi Olof, Hi Kevin, Hi Arnd,
> 
> Please consider these third round of Renesas ARM64 based SoC DT updates
> for v4.5.
> 
> This pull request is based on the previous round of
> such requests, tagged as renesas-arm64-dt2-for-v4.5,
> which you have already pulled.
> 
> 
> The following changes since commit 672b79312c04016481a11d4b996b4512207ffbd3:
> 
>   arm64: renesas: salvator-x: Sound DVC support (2015-11-26 11:31:43 +0900)
> 
> are available in the git repository at:
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas.git tags/renesas-arm64-dt3-for-v4.5

Merged, but:

>       arm64: dts: r8a7795: Add PSCI node
>       arm64: dts: r8a7795: Add Cortex-A57 CPU cores
>       arm64: renesas: salvator-x: Add board part number to DT bindings
>       arm64: dts: r8a7795: Add SATA controller node
>       arm64: dts: salvator-x: Enable SATA controller
>       arm64: renesas: salvator-x: set ak4613 In/Out pin as single-end
>       arm64: renesas: salvator-x: use CS2000 as AUDIO_CLK_B
>       arm64: renesas: r8a7795: fix SATA clock assignment
>       arm64: renesas: r8a7795: add internal delay for i2c IPs
>       arm64: dts: r8a7795: Add pmu device nodes

Please me more consistent in patch description prefixes.


-Olof
Simon Horman Dec. 28, 2015, 4:55 a.m. UTC | #5
On Tue, Dec 22, 2015 at 12:52:08PM -0800, Olof Johansson wrote:
> On Fri, Dec 18, 2015 at 11:29:14AM +0900, Simon Horman wrote:
> > Hi Olof, Hi Kevin, Hi Arnd,
> > 
> > Please consider these third round of Renesas ARM64 based SoC DT updates
> > for v4.5.
> > 
> > This pull request is based on the previous round of
> > such requests, tagged as renesas-arm64-dt2-for-v4.5,
> > which you have already pulled.
> > 
> > 
> > The following changes since commit 672b79312c04016481a11d4b996b4512207ffbd3:
> > 
> >   arm64: renesas: salvator-x: Sound DVC support (2015-11-26 11:31:43 +0900)
> > 
> > are available in the git repository at:
> > 
> >   git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas.git tags/renesas-arm64-dt3-for-v4.5
> 
> Merged, but:
> 
> >       arm64: dts: r8a7795: Add PSCI node
> >       arm64: dts: r8a7795: Add Cortex-A57 CPU cores
> >       arm64: renesas: salvator-x: Add board part number to DT bindings
> >       arm64: dts: r8a7795: Add SATA controller node
> >       arm64: dts: salvator-x: Enable SATA controller
> >       arm64: renesas: salvator-x: set ak4613 In/Out pin as single-end
> >       arm64: renesas: salvator-x: use CS2000 as AUDIO_CLK_B
> >       arm64: renesas: r8a7795: fix SATA clock assignment
> >       arm64: renesas: r8a7795: add internal delay for i2c IPs
> >       arm64: dts: r8a7795: Add pmu device nodes
> 
> Please me more consistent in patch description prefixes.

Sure, sorry for not being more attentive to that.
Dirk Behme Jan. 9, 2016, 6:36 a.m. UTC | #6
On 18.12.2015 11:47, Sudeep Holla wrote:
>
>
> On 18/12/15 10:44, Dirk Behme wrote:
>> On 18.12.2015 11:16, Sudeep Holla wrote:
>>>
>>>
>>> On 18/12/15 02:29, Simon Horman wrote:
>>>> From: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
>>>>
>>>> Enabling the performance monitor unit on r8a7795.
>>>>
>>>> Signed-off-by: Masaru Nagai <masaru.nagai.vx@renesas.com>
>>>> Signed-off-by: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
>>>> Signed-off-by: Dirk Behme <dirk.behme@gmail.com>
>>>> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
>>>> ---
>>>>   arch/arm64/boot/dts/renesas/r8a7795.dtsi | 12 ++++++++++++
>>>>   1 file changed, 12 insertions(+)
>>>>
>>>> diff --git a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>>> b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>>> index 4d43cf31418f..b9229a49dabc 100644
>>>> --- a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>>> +++ b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>>> @@ -230,6 +230,18 @@
>>>>               power-domains = <&cpg>;
>>>>           };
>>>>
>>>> +        pmu {
>>>> +            compatible = "arm,armv8-pmuv3";
>>>
>>> Please use arm,cortex-a57-pmu to be more specific. IIRC I mentioned
>>> this
>>> for some shmobile platform recently.
>>
>>
>> Yes. But as this patch has been applied already to some branches, I
>> incorporated your a57-pmu hint with an additional update patch:
>>
>> http://marc.info/?l=linux-sh&m=145011467914857
>>
>> Feel free to squash if still possible.
>>
>
> Ah OK, I didn't know the exact dts name, sorry for the noise.
> Better if it was posted as part of this series :)


I finally found some time to test this

http://marc.info/?l=linux-sh&m=145011467914857

and surprisingly it doesn't seem to work:

Using "arm,cortex-a57-pmu" results in

hw perfevents: enabled with armv8_cortex_a57 PMU driver, 7 counters 
available
hw perfevents: failed to probe PMU!
hw perfevents: failed to register PMU devices!

while switching back to "arm,armv8-pmuv3" successfully gives

hw perfevents: enabled with armv8_pmuv3 PMU driver, 7 counters available

without any further error messages.

Any idea?

Best regards

Dirk
Sudeep Holla Jan. 11, 2016, 10:18 a.m. UTC | #7
On 09/01/16 06:36, Dirk Behme wrote:
> On 18.12.2015 11:47, Sudeep Holla wrote:
>>
>>
>> On 18/12/15 10:44, Dirk Behme wrote:
>>> On 18.12.2015 11:16, Sudeep Holla wrote:

[...]

>>>>
>>>> Please use arm,cortex-a57-pmu to be more specific. IIRC I mentioned
>>>> this for some shmobile platform recently.
>>>
>>> Yes. But as this patch has been applied already to some branches, I
>>> incorporated your a57-pmu hint with an additional update patch:
>>>
>>> http://marc.info/?l=linux-sh&m=145011467914857
>>>
>>> Feel free to squash if still possible.
>>>
>>
>> Ah OK, I didn't know the exact dts name, sorry for the noise.
>> Better if it was posted as part of this series :)
>
>
> I finally found some time to test this
>
> http://marc.info/?l=linux-sh&m=145011467914857
>
> and surprisingly it doesn't seem to work:
>
> Using "arm,cortex-a57-pmu" results in
>
> hw perfevents: enabled with armv8_cortex_a57 PMU driver, 7 counters available

I had a quick look at the DT in the link above and IIUC A57 PMU's are
successfully probed.

> hw perfevents: failed to probe PMU!
> hw perfevents: failed to register PMU devices!
>

This must be for A53 PMUs. So I suspect if the update DT is passed
correctly to the kernel.

> while switching back to "arm,armv8-pmuv3" successfully gives
>
> hw perfevents: enabled with armv8_pmuv3 PMU driver, 7 counters available
>
> without any further error messages.
>
> Any idea?

You need to check if of_pmu_irq_cfg is failing.
Is the updated DT picked up correctly ?
Mark Rutland Jan. 11, 2016, 10:39 a.m. UTC | #8
On Sat, Jan 09, 2016 at 07:36:42AM +0100, Dirk Behme wrote:
> On 18.12.2015 11:47, Sudeep Holla wrote:
> >
> >
> >On 18/12/15 10:44, Dirk Behme wrote:
> >>On 18.12.2015 11:16, Sudeep Holla wrote:
> >>>
> >>>
> >>>On 18/12/15 02:29, Simon Horman wrote:
> >>>>From: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
> >>>>
> >>>>Enabling the performance monitor unit on r8a7795.
> >>>>
> >>>>Signed-off-by: Masaru Nagai <masaru.nagai.vx@renesas.com>
> >>>>Signed-off-by: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
> >>>>Signed-off-by: Dirk Behme <dirk.behme@gmail.com>
> >>>>Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
> >>>>---
> >>>>  arch/arm64/boot/dts/renesas/r8a7795.dtsi | 12 ++++++++++++
> >>>>  1 file changed, 12 insertions(+)
> >>>>
> >>>>diff --git a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> >>>>b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> >>>>index 4d43cf31418f..b9229a49dabc 100644
> >>>>--- a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> >>>>+++ b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> >>>>@@ -230,6 +230,18 @@
> >>>>              power-domains = <&cpg>;
> >>>>          };
> >>>>
> >>>>+        pmu {
> >>>>+            compatible = "arm,armv8-pmuv3";
> >>>
> >>>Please use arm,cortex-a57-pmu to be more specific. IIRC I mentioned
> >>>this
> >>>for some shmobile platform recently.
> >>
> >>
> >>Yes. But as this patch has been applied already to some branches, I
> >>incorporated your a57-pmu hint with an additional update patch:
> >>
> >>http://marc.info/?l=linux-sh&m=145011467914857
> >>
> >>Feel free to squash if still possible.
> >>
> >
> >Ah OK, I didn't know the exact dts name, sorry for the noise.
> >Better if it was posted as part of this series :)
> 
> 
> I finally found some time to test this
> 
> http://marc.info/?l=linux-sh&m=145011467914857
> 
> and surprisingly it doesn't seem to work:
> 
> Using "arm,cortex-a57-pmu" results in
> 
> hw perfevents: enabled with armv8_cortex_a57 PMU driver, 7 counters
> available

This means all the probing logic worked for the A57 PMU.

> hw perfevents: failed to probe PMU!
> hw perfevents: failed to register PMU devices!

These are printed in arm_pmu_device_probe, and following the logic we
must have succesfully allocated the struct pmu, but failed in either
of_pmu_irq_cfg or init_fn (AKA armv8_a53_pmu_init).

In armv8_a53_pmu_init we call armv8pmu_probe_num_events, which will try
to SMP cross-call to an A53 core to probe the number of countesr
implemented. Perhaps the cross-call is failing.

Were the A53s online at this point?

Thanks,
Mark.
Behme Dirk (CM/ESO2) Jan. 12, 2016, 8:37 a.m. UTC | #9
On 11.01.2016 11:39, Mark Rutland wrote:
> On Sat, Jan 09, 2016 at 07:36:42AM +0100, Dirk Behme wrote:
>> On 18.12.2015 11:47, Sudeep Holla wrote:
>>>
>>>
>>> On 18/12/15 10:44, Dirk Behme wrote:
>>>> On 18.12.2015 11:16, Sudeep Holla wrote:
>>>>>
>>>>>
>>>>> On 18/12/15 02:29, Simon Horman wrote:
>>>>>> From: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
>>>>>>
>>>>>> Enabling the performance monitor unit on r8a7795.
>>>>>>
>>>>>> Signed-off-by: Masaru Nagai <masaru.nagai.vx@renesas.com>
>>>>>> Signed-off-by: Yoshifumi Hosoya <yoshifumi.hosoya.wj@renesas.com>
>>>>>> Signed-off-by: Dirk Behme <dirk.behme@gmail.com>
>>>>>> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
>>>>>> ---
>>>>>>   arch/arm64/boot/dts/renesas/r8a7795.dtsi | 12 ++++++++++++
>>>>>>   1 file changed, 12 insertions(+)
>>>>>>
>>>>>> diff --git a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>>>>> b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>>>>> index 4d43cf31418f..b9229a49dabc 100644
>>>>>> --- a/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>>>>> +++ b/arch/arm64/boot/dts/renesas/r8a7795.dtsi
>>>>>> @@ -230,6 +230,18 @@
>>>>>>               power-domains = <&cpg>;
>>>>>>           };
>>>>>>
>>>>>> +        pmu {
>>>>>> +            compatible = "arm,armv8-pmuv3";
>>>>>
>>>>> Please use arm,cortex-a57-pmu to be more specific. IIRC I mentioned
>>>>> this
>>>>> for some shmobile platform recently.
>>>>
>>>>
>>>> Yes. But as this patch has been applied already to some branches, I
>>>> incorporated your a57-pmu hint with an additional update patch:
>>>>
>>>> http://marc.info/?l=linux-sh&m=145011467914857
>>>>
>>>> Feel free to squash if still possible.
>>>>
>>>
>>> Ah OK, I didn't know the exact dts name, sorry for the noise.
>>> Better if it was posted as part of this series :)
>>
>>
>> I finally found some time to test this
>>
>> http://marc.info/?l=linux-sh&m=145011467914857
>>
>> and surprisingly it doesn't seem to work:
>>
>> Using "arm,cortex-a57-pmu" results in
>>
>> hw perfevents: enabled with armv8_cortex_a57 PMU driver, 7 counters
>> available
>
> This means all the probing logic worked for the A57 PMU.
>
>> hw perfevents: failed to probe PMU!
>> hw perfevents: failed to register PMU devices!
>
> These are printed in arm_pmu_device_probe, and following the logic we
> must have succesfully allocated the struct pmu, but failed in either
> of_pmu_irq_cfg or init_fn (AKA armv8_a53_pmu_init).
>
> In armv8_a53_pmu_init we call armv8pmu_probe_num_events, which will try
> to SMP cross-call to an A53 core to probe the number of countesr
> implemented. Perhaps the cross-call is failing.
>
> Were the A53s online at this point?


Ah, indeed, the A53s failed to run.

Maybe anything like

http://lists.infradead.org/pipermail/linux-arm-kernel/2016-January/398773.html

helps to make this more obvious, then?

Thanks!

Best regards

Dirk