linux-samsung-soc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Question about Odroid XU4 cpuidle
@ 2020-06-10 13:18 Lukasz Luba
  2020-06-10 14:02 ` Krzysztof Kozlowski
  0 siblings, 1 reply; 7+ messages in thread
From: Lukasz Luba @ 2020-06-10 13:18 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Bartlomiej Zolnierkiewicz
  Cc: linux-samsung-soc, Andrzej Hajda, Marek Szyprowski, s.nawrocki

Hi Krzysztof, Bartek,

I recall that you have been working on some cpuidle code for Exynos(4?).

I have a question regarding CPUIdle driver for Odroid XU4.
I use the board with LISA tests for EAS, but missing at
least idle state 0 cause errors (please see the log below).

Currently the system does not report any idle driver and the state 0
is missing in: /sys/devices/system/cpu/cpu0/cpuidle/state0/

I am using driver CONFIG_ARM_BIG_LITTLE_CPUIDLE but the
boot stops silently while trying to init the cpu idle devices in there.
I carry on with a workaround that just removes idle state[1] and set
state_count=1 in the big and little structures.

Could you tell me if it needs some out-of-tree patches or maybe special
bootloader or it is not possible at all to have this driver working
properly? Or maybe I should use different driver on that board?

----------------->8--------------------------------
EXCEPTION (KeyError): 'No idle state with index 0'
----------------------------------------

################################################################################
[2020-06-08 17:53:51,333][EXEKALL] INFO  Artifacts dir: 
/data/llu/lisa/results/20200608_17:47:19_02627c97a1de40588d800f5b777eb9e3
[2020-06-08 17:53:51,334][EXEKALL] INFO  Result summary:
EnergyModelWakeMigration[board=odroidxu4]:test_task_placement 
UUID=b264d606c7164c8192eae59eb26d5104 EXCEPTION (KeyError): 'No idle 
state with index 0'
OneSmallTask[board=odroidxu4]:test_task_placement 
UUID=c95afb9d5ab84d4f9f945e8e9b87aaea EXCEPTION (KeyError): 'No idle 
state with index 0'
RampDown[board=odroidxu4]:test_task_placement 
UUID=6b9d7be94a43441c94d87543d612fde0 EXCEPTION (KeyError): 'No idle 
state with index 0'
RampUp[board=odroidxu4]:test_task_placement 
UUID=7a60af8c17344214bd8602ac24767976 EXCEPTION (KeyError): 'No idle 
state with index 0'
ThreeSmallTasks[board=odroidxu4]:test_task_placement 
UUID=25ec227753ce4ac3b409c88e7a8f9d78 EXCEPTION (KeyError): 'No idle 
state with index 0'
TwoBigTasks[board=odroidxu4]:test_task_placement 
UUID=9e8b9148685748ed9d632912fc83f4ba EXCEPTION (KeyError): 'No idle 
state with index 0'
TwoBigThreeSmall[board=odroidxu4]:test_task_placement 
UUID=a0c98621f160400fb5487d8db1c69f95 EXCEPTION (KeyError): 'No idle 
state with index 0'

----------------8<--------------------------------------------------

I appreciate your advice.

Regards,
Lukasz

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

* Re: Question about Odroid XU4 cpuidle
  2020-06-10 13:18 Question about Odroid XU4 cpuidle Lukasz Luba
@ 2020-06-10 14:02 ` Krzysztof Kozlowski
  2020-06-10 14:09   ` Marek Szyprowski
  2020-06-10 14:27   ` Lukasz Luba
  0 siblings, 2 replies; 7+ messages in thread
From: Krzysztof Kozlowski @ 2020-06-10 14:02 UTC (permalink / raw)
  To: Lukasz Luba
  Cc: Bartlomiej Zolnierkiewicz, linux-samsung-soc, Andrzej Hajda,
	Marek Szyprowski, s.nawrocki

On Wed, Jun 10, 2020 at 02:18:12PM +0100, Lukasz Luba wrote:
> Hi Krzysztof, Bartek,
> 
> I recall that you have been working on some cpuidle code for Exynos(4?).
> 
> I have a question regarding CPUIdle driver for Odroid XU4.
> I use the board with LISA tests for EAS, but missing at
> least idle state 0 cause errors (please see the log below).
> 
> Currently the system does not report any idle driver and the state 0
> is missing in: /sys/devices/system/cpu/cpu0/cpuidle/state0/

The state 0 long time ago was WFI. It was kind of meaningless so it it
was dropped.

> 
> I am using driver CONFIG_ARM_BIG_LITTLE_CPUIDLE but the
> boot stops silently while trying to init the cpu idle devices in there.
> I carry on with a workaround that just removes idle state[1] and set
> state_count=1 in the big and little structures.

Try earlyprintk.

In general, the big-little cpuidle driver should work... or rather: long
time ago it was working.  It requires proper support from early stages
(BL1, secure monitor) but this should be already in standard Odroid.

I just saw there:
	/* Start at index 1, index 0 standard WFI */
so maybe it was not updated properly to removal of WFI?

I think no one uses this driver so it might be not well tested and not
that useful.

Best regards,
Krzysztof

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

* Re: Question about Odroid XU4 cpuidle
  2020-06-10 14:02 ` Krzysztof Kozlowski
@ 2020-06-10 14:09   ` Marek Szyprowski
  2020-06-10 14:30     ` Lukasz Luba
  2020-06-10 14:27   ` Lukasz Luba
  1 sibling, 1 reply; 7+ messages in thread
From: Marek Szyprowski @ 2020-06-10 14:09 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Lukasz Luba
  Cc: Bartlomiej Zolnierkiewicz, linux-samsung-soc, Andrzej Hajda, s.nawrocki

Hi

On 10.06.2020 16:02, Krzysztof Kozlowski wrote:
> On Wed, Jun 10, 2020 at 02:18:12PM +0100, Lukasz Luba wrote:
>> Hi Krzysztof, Bartek,
>>
>> I recall that you have been working on some cpuidle code for Exynos(4?).
>>
>> I have a question regarding CPUIdle driver for Odroid XU4.
>> I use the board with LISA tests for EAS, but missing at
>> least idle state 0 cause errors (please see the log below).
>>
>> Currently the system does not report any idle driver and the state 0
>> is missing in: /sys/devices/system/cpu/cpu0/cpuidle/state0/
> The state 0 long time ago was WFI. It was kind of meaningless so it it
> was dropped.
>
>> I am using driver CONFIG_ARM_BIG_LITTLE_CPUIDLE but the
>> boot stops silently while trying to init the cpu idle devices in there.
>> I carry on with a workaround that just removes idle state[1] and set
>> state_count=1 in the big and little structures.
> Try earlyprintk.
>
> In general, the big-little cpuidle driver should work... or rather: long
> time ago it was working.  It requires proper support from early stages
> (BL1, secure monitor) but this should be already in standard Odroid.
>
> I just saw there:
> 	/* Start at index 1, index 0 standard WFI */
> so maybe it was not updated properly to removal of WFI?
>
> I think no one uses this driver so it might be not well tested and not
> that useful.

I think it never worked on Odroid XU3/XU4. Afair it was developed on 
PeachPi Chromebook, which use different bootloader (and doesn't use 
trustzone).

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland


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

* Re: Question about Odroid XU4 cpuidle
  2020-06-10 14:02 ` Krzysztof Kozlowski
  2020-06-10 14:09   ` Marek Szyprowski
@ 2020-06-10 14:27   ` Lukasz Luba
  1 sibling, 0 replies; 7+ messages in thread
From: Lukasz Luba @ 2020-06-10 14:27 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Bartlomiej Zolnierkiewicz, linux-samsung-soc, Andrzej Hajda,
	Marek Szyprowski, s.nawrocki



On 6/10/20 3:02 PM, Krzysztof Kozlowski wrote:
> On Wed, Jun 10, 2020 at 02:18:12PM +0100, Lukasz Luba wrote:
>> Hi Krzysztof, Bartek,
>>
>> I recall that you have been working on some cpuidle code for Exynos(4?).
>>
>> I have a question regarding CPUIdle driver for Odroid XU4.
>> I use the board with LISA tests for EAS, but missing at
>> least idle state 0 cause errors (please see the log below).
>>
>> Currently the system does not report any idle driver and the state 0
>> is missing in: /sys/devices/system/cpu/cpu0/cpuidle/state0/
> 
> The state 0 long time ago was WFI. It was kind of meaningless so it it
> was dropped.

I see.

> 
>>
>> I am using driver CONFIG_ARM_BIG_LITTLE_CPUIDLE but the
>> boot stops silently while trying to init the cpu idle devices in there.
>> I carry on with a workaround that just removes idle state[1] and set
>> state_count=1 in the big and little structures.
> 
> Try earlyprintk.
I've tried and printed some dbg in that driver and just simply
dropped the deeper idle and system runs. Idle driver account properly
the residency time for this WFI in the state0 dir. That's enough for
what I need in testing - accounting wfi from that dir location.

> 
> In general, the big-little cpuidle driver should work... or rather: long
> time ago it was working.  It requires proper support from early stages
> (BL1, secure monitor) but this should be already in standard Odroid.
> 
> I just saw there:
> 	/* Start at index 1, index 0 standard WFI */
> so maybe it was not updated properly to removal of WFI?
> 
> I think no one uses this driver so it might be not well tested and not
> that useful.

OK, good to know, I just found this driver by compatibility string and
thought it could be used.

Thank you Krzysztof for you instant response.

Regards,
Lukasz

> 
> Best regards,
> Krzysztof
> 

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

* Re: Question about Odroid XU4 cpuidle
  2020-06-10 14:09   ` Marek Szyprowski
@ 2020-06-10 14:30     ` Lukasz Luba
  2020-06-15 12:45       ` Marek Szyprowski
  0 siblings, 1 reply; 7+ messages in thread
From: Lukasz Luba @ 2020-06-10 14:30 UTC (permalink / raw)
  To: Marek Szyprowski, Krzysztof Kozlowski
  Cc: Bartlomiej Zolnierkiewicz, linux-samsung-soc, Andrzej Hajda, s.nawrocki

Hi Marek,

On 6/10/20 3:09 PM, Marek Szyprowski wrote:
> Hi
> 
> On 10.06.2020 16:02, Krzysztof Kozlowski wrote:
>> On Wed, Jun 10, 2020 at 02:18:12PM +0100, Lukasz Luba wrote:
>>> Hi Krzysztof, Bartek,
>>>
>>> I recall that you have been working on some cpuidle code for Exynos(4?).
>>>
>>> I have a question regarding CPUIdle driver for Odroid XU4.
>>> I use the board with LISA tests for EAS, but missing at
>>> least idle state 0 cause errors (please see the log below).
>>>
>>> Currently the system does not report any idle driver and the state 0
>>> is missing in: /sys/devices/system/cpu/cpu0/cpuidle/state0/
>> The state 0 long time ago was WFI. It was kind of meaningless so it it
>> was dropped.
>>
>>> I am using driver CONFIG_ARM_BIG_LITTLE_CPUIDLE but the
>>> boot stops silently while trying to init the cpu idle devices in there.
>>> I carry on with a workaround that just removes idle state[1] and set
>>> state_count=1 in the big and little structures.
>> Try earlyprintk.
>>
>> In general, the big-little cpuidle driver should work... or rather: long
>> time ago it was working.  It requires proper support from early stages
>> (BL1, secure monitor) but this should be already in standard Odroid.
>>
>> I just saw there:
>> 	/* Start at index 1, index 0 standard WFI */
>> so maybe it was not updated properly to removal of WFI?
>>
>> I think no one uses this driver so it might be not well tested and not
>> that useful.
> 
> I think it never worked on Odroid XU3/XU4. Afair it was developed on
> PeachPi Chromebook, which use different bootloader (and doesn't use
> trustzone).

That would explain the compatibility string in that driver. Good to
know. Thank you for your response.

Regards,
Lukasz

> 
> Best regards
> 

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

* Re: Question about Odroid XU4 cpuidle
  2020-06-10 14:30     ` Lukasz Luba
@ 2020-06-15 12:45       ` Marek Szyprowski
  2020-06-15 15:39         ` Lukasz Luba
  0 siblings, 1 reply; 7+ messages in thread
From: Marek Szyprowski @ 2020-06-15 12:45 UTC (permalink / raw)
  To: Lukasz Luba, Krzysztof Kozlowski
  Cc: Bartlomiej Zolnierkiewicz, linux-samsung-soc, Andrzej Hajda, s.nawrocki

Hi Lukasz

On 10.06.2020 16:30, Lukasz Luba wrote:
> On 6/10/20 3:09 PM, Marek Szyprowski wrote:
>> On 10.06.2020 16:02, Krzysztof Kozlowski wrote:
>>> On Wed, Jun 10, 2020 at 02:18:12PM +0100, Lukasz Luba wrote:
>>>> Hi Krzysztof, Bartek,
>>>>
>>>> I recall that you have been working on some cpuidle code for 
>>>> Exynos(4?).
>>>>
>>>> I have a question regarding CPUIdle driver for Odroid XU4.
>>>> I use the board with LISA tests for EAS, but missing at
>>>> least idle state 0 cause errors (please see the log below).
>>>>
>>>> Currently the system does not report any idle driver and the state 0
>>>> is missing in: /sys/devices/system/cpu/cpu0/cpuidle/state0/
>>> The state 0 long time ago was WFI. It was kind of meaningless so it it
>>> was dropped.
>>>
>>>> I am using driver CONFIG_ARM_BIG_LITTLE_CPUIDLE but the
>>>> boot stops silently while trying to init the cpu idle devices in 
>>>> there.
>>>> I carry on with a workaround that just removes idle state[1] and set
>>>> state_count=1 in the big and little structures.
>>> Try earlyprintk.
>>>
>>> In general, the big-little cpuidle driver should work... or rather: 
>>> long
>>> time ago it was working.  It requires proper support from early stages
>>> (BL1, secure monitor) but this should be already in standard Odroid.
>>>
>>> I just saw there:
>>>     /* Start at index 1, index 0 standard WFI */
>>> so maybe it was not updated properly to removal of WFI?
>>>
>>> I think no one uses this driver so it might be not well tested and not
>>> that useful.
>>
>> I think it never worked on Odroid XU3/XU4. Afair it was developed on
>> PeachPi Chromebook, which use different bootloader (and doesn't use
>> trustzone).
>
> That would explain the compatibility string in that driver. Good to
> know. Thank you for your response.
>
I've just digged a bit in the old kernels and indeed, the big-little 
cpuidle driver worked only on Samsung Exynos 5420/5800 Chromebooks 
(Peach Pit/Pi). The last release which worked fine (although it was 
still not enabled in the exynos_defconfig) is v4.2. Then it got broken 
by the commit 833b5794e330 ("ARM: EXYNOS: reset Little cores when cpu is 
up"). It never worked on the Odroid XU3/XU4.

Do you have any plans to fix it?

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland


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

* Re: Question about Odroid XU4 cpuidle
  2020-06-15 12:45       ` Marek Szyprowski
@ 2020-06-15 15:39         ` Lukasz Luba
  0 siblings, 0 replies; 7+ messages in thread
From: Lukasz Luba @ 2020-06-15 15:39 UTC (permalink / raw)
  To: Marek Szyprowski, Krzysztof Kozlowski
  Cc: Bartlomiej Zolnierkiewicz, linux-samsung-soc, Andrzej Hajda, s.nawrocki



On 6/15/20 1:45 PM, Marek Szyprowski wrote:
> Hi Lukasz
> 
> On 10.06.2020 16:30, Lukasz Luba wrote:
>> On 6/10/20 3:09 PM, Marek Szyprowski wrote:
>>> On 10.06.2020 16:02, Krzysztof Kozlowski wrote:
>>>> On Wed, Jun 10, 2020 at 02:18:12PM +0100, Lukasz Luba wrote:
>>>>> Hi Krzysztof, Bartek,
>>>>>
>>>>> I recall that you have been working on some cpuidle code for
>>>>> Exynos(4?).
>>>>>
>>>>> I have a question regarding CPUIdle driver for Odroid XU4.
>>>>> I use the board with LISA tests for EAS, but missing at
>>>>> least idle state 0 cause errors (please see the log below).
>>>>>
>>>>> Currently the system does not report any idle driver and the state 0
>>>>> is missing in: /sys/devices/system/cpu/cpu0/cpuidle/state0/
>>>> The state 0 long time ago was WFI. It was kind of meaningless so it it
>>>> was dropped.
>>>>
>>>>> I am using driver CONFIG_ARM_BIG_LITTLE_CPUIDLE but the
>>>>> boot stops silently while trying to init the cpu idle devices in
>>>>> there.
>>>>> I carry on with a workaround that just removes idle state[1] and set
>>>>> state_count=1 in the big and little structures.
>>>> Try earlyprintk.
>>>>
>>>> In general, the big-little cpuidle driver should work... or rather:
>>>> long
>>>> time ago it was working.  It requires proper support from early stages
>>>> (BL1, secure monitor) but this should be already in standard Odroid.
>>>>
>>>> I just saw there:
>>>>      /* Start at index 1, index 0 standard WFI */
>>>> so maybe it was not updated properly to removal of WFI?
>>>>
>>>> I think no one uses this driver so it might be not well tested and not
>>>> that useful.
>>>
>>> I think it never worked on Odroid XU3/XU4. Afair it was developed on
>>> PeachPi Chromebook, which use different bootloader (and doesn't use
>>> trustzone).
>>
>> That would explain the compatibility string in that driver. Good to
>> know. Thank you for your response.
>>
> I've just digged a bit in the old kernels and indeed, the big-little
> cpuidle driver worked only on Samsung Exynos 5420/5800 Chromebooks
> (Peach Pit/Pi). The last release which worked fine (although it was
> still not enabled in the exynos_defconfig) is v4.2. Then it got broken
> by the commit 833b5794e330 ("ARM: EXYNOS: reset Little cores when cpu is
> up"). It never worked on the Odroid XU3/XU4.

Thank you Marek for your time to investigate it. In this case I think
there is no way to fix idle state 1 for Odroid xu3/xu4. I don't have
Peach Pit/Pi so I have to pass, but I can help you in reviewing
if you or someone else have time (and board) to work on it.

> 
> Do you have any plans to fix it?

I'm baking some patch internally which might help Odroid XU3/4 though.
If that won't be killed, I'll post it soon.
If failed internally, I will also let you know.

Regards,
Lukasz

> 
> Best regards
> 

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

end of thread, other threads:[~2020-06-15 15:39 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-10 13:18 Question about Odroid XU4 cpuidle Lukasz Luba
2020-06-10 14:02 ` Krzysztof Kozlowski
2020-06-10 14:09   ` Marek Szyprowski
2020-06-10 14:30     ` Lukasz Luba
2020-06-15 12:45       ` Marek Szyprowski
2020-06-15 15:39         ` Lukasz Luba
2020-06-10 14:27   ` Lukasz Luba

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).