cpuidle: 4.0-rc3 fixes
Hi Rafael,
this pull request contains a couple of fixes:
- Fix the cpu_pm_enter/exit symmetry in the mvebu driver (Gregory Clement)
- Fix the mvebu drivers latency/residency values to reach an
acceptable tradeoff between perf / power (Sebastian Rannou)
Thanks !
-- Daniel
ps: I took the opportunity to double check the other drivers have their cpu_pm_entry/exit symmetry correct (everything ok).
The following changes since commit 9eccca0843205f87c00404b663188b88eb248051:
Linux 4.0-rc3 (2015-03-08 16:09:09 -0700)
are available in the git repository at:
http://git.linaro.org/people/daniel.lezcano/linux.git cpuidle/4.0-fixes
for you to fetch changes up to ce6031c89a35cffd5a5992b08377b77f49a004b9:
cpuidle: mvebu: Update cpuidle thresholds for Armada XP SOCs
(2015-03-13 18:31:29 +0100)
----------------------------------------------------------------
Gregory CLEMENT (1):
cpuidle: mvebu: Fix the CPU PM notifier usage
Sebastien Rannou (1):
cpuidle: mvebu: Update cpuidle thresholds for Armada XP SOCs
drivers/cpuidle/cpuidle-mvebu-v7.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
Signature · 5 lines
<http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs Follow Linaro: <http://www.facebook.com/pages/Linaro> Facebook | <http://twitter.com/#!/linaroorg> Twitter | <http://www.linaro.org/linaro-blog/> Blog
PATCH 1/2 cpuidle: mvebu: Fix the CPU PM notifier usage
From: Gregory CLEMENT <[email protected]>
As stated in kernel/cpu_pm.c, "Platform is responsible for ensuring that cpu_pm_enter is not called twice on the same CPU before cpu_pm_exit is called.". In the current code in case of failure when calling mvebu_v7_cpu_suspend, the function cpu_pm_exit() is never called whereas cpu_pm_enter() was called just before.
This patch moves the cpu_pm_exit() in order to balance the cpu_pm_enter() calls.
--- drivers/cpuidle/cpuidle-mvebu-v7.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/cpuidle/cpuidle-mvebu-v7.c +2 -2
@@ -37,11 +37,11 @@ static int mvebu_v7_enter_idle(struct cpuidle_device *dev, deepidle = true; ret =mvebu_v7_cpu_suspend (deepidle); +cpu_pm_exit (); +if (ret)return ret; -cpu_pm_exit (); -return index; }
Signature · 1 line
1.9.1
PATCH 2/2 cpuidle: mvebu: Update cpuidle thresholds for Armada XP SOCs
From: Sebastien Rannou <[email protected]>
Originally, the thresholds used in the cpuidle driver for Armada SOCs were temporarily chosen, leaving room for improvements.
This commit updates the thresholds for the Armada XP SOCs with values that positively impact performances:
without patch with patch vendor kernel - iperf localhost (gbit/sec) ~3.7 ~6.4 ~5.4 - ioping tmpfs (iops) ~163k ~206k ~179k - ioping tmpfs (mib/s) ~636 ~805 ~699
The idle power consumption is negatively impacted (proportionally less than the performance gain), and we are still performing better than the vendor kernel here:
without patch with patch vendor kernel - power consumption idle (W) ~2.4 ~3.2 ~4.4 - power consumption busy (W) ~8.6 ~8.3 ~8.6
There is still room for improvement regarding the value of these thresholds, they were chosen to mimic the vendor kernel.
This patch only impacts Armada XP SOCs and was tested on Online Labs C1 boards. A similar approach can be taken to improve the performances of the Armada 370 and Armada 38x SOCs.
Thanks a lot to Thomas Petazzoni, Gregory Clement and Willy Tarreau for the discussions and tips around this topic.
--- drivers/cpuidle/cpuidle-mvebu-v7.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/cpuidle/cpuidle-mvebu-v7.c +4 -4
@@ -50,17 +50,17 @@ static struct cpuidle_driver armadaxp_idle_driver = { .states[0] = ARM_CPUIDLE_WFI_STATE, .states[1] = { .enter = mvebu_v7_enter_idle, - .exit_latency = 10, + .exit_latency = 100, .power_usage = 50, - .target_residency = 100, + .target_residency = 1000, .name = "MV CPU IDLE", .desc = "CPU power down", }, .states[2] = { .enter = mvebu_v7_enter_idle, - .exit_latency = 100, + .exit_latency = 1000, .power_usage = 5, - .target_residency = 1000, + .target_residency = 10000, .flags = MVEBU_V7_FLAG_DEEP_IDLE, .name = "MV CPU DEEP IDLE", .desc = "CPU and L2 Fabric power down",
Signature · 1 line
1.9.1
Quoted 11 lines · Daniel Lezcano
Hi Rafael,
this pull request contains a couple of fixes:
- Fix the cpu_pm_enter/exit symmetry in the mvebu driver (Gregory Clement)
- Fix the mvebu drivers latency/residency values to reach an
acceptable tradeoff between perf / power (Sebastian Rannou)Thanks !
Pulled, but this is a bit too late for 4.0-rc4, so I'll queue it up for -rc5.
Quoted 2 lines
ps: I took the opportunity to double check the other drivers have their cpu_pm_entry/exit symmetry correct (everything ok).
OK, thanks!
BTW, please update the dead linux-pm address you have in your scripts.
Signature · 2 lines
I speak only for myself. Rafael J. Wysocki, Intel Open Source Technology Center.
Quoted 6 lines · Rafael J. Wysocki
Quoted 5 lines · Daniel Lezcano
Hi Rafael,
this pull request contains a couple of fixes:
Quoted 8 lines
Quoted 6 lines
- Fix the cpu_pm_enter/exit symmetry in the mvebu driver (Gregory Clement)
- Fix the mvebu drivers latency/residency values to reach an
acceptable tradeoff between perf / power (Sebastian Rannou)Thanks !
Pulled, but this is a bit too late for 4.0-rc4, so I'll queue it up for -rc5.
Ok, no problem.
Quoted 6 lines
Quoted 2 lines
ps: I took the opportunity to double check the other drivers have their cpu_pm_entry/exit symmetry correct (everything ok).
OK, thanks!
BTW, please update the dead linux-pm address you have in your scripts.
Fixed. Thanks for the head up.
-- Daniel
Signature · 5 lines
<http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs Follow Linaro: <http://www.facebook.com/pages/Linaro> Facebook | <http://twitter.com/#!/linaroorg> Twitter | <http://www.linaro.org/linaro-blog/> Blog
Hi Rafael,
Quoted 11 lines · Rafael J. Wysocki
Quoted 8 lines · Daniel Lezcano
this pull request contains a couple of fixes:
- Fix the cpu_pm_enter/exit symmetry in the mvebu driver (Gregory Clement)
- Fix the mvebu drivers latency/residency values to reach an
acceptable tradeoff between perf / power (Sebastian Rannou)Thanks !
Pulled, but this is a bit too late for 4.0-rc4, so I'll queue it up for -rc5.
Please note commit 43b68879de27b199 ("cpuidle: mvebu: Fix the CPU PM notifier usage") has a "Cc: [email protected]" tag.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
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
Quoted 11 lines · Geert Uytterhoeven
Hi Rafael,
Quoted 8 lines · Rafael J. Wysocki
Quoted 7 lines · Daniel Lezcano
this pull request contains a couple of fixes:
- Fix the cpu_pm_enter/exit symmetry in the mvebu driver (Gregory Clement)
- Fix the mvebu drivers latency/residency values to reach an
acceptable tradeoff between perf / power (Sebastian Rannou)
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Thanks !
Pulled, but this is a bit too late for 4.0-rc4, so I'll queue it up for -rc5.
Please note commit
43b68879de27b199("cpuidle: mvebu: Fix the CPU PM notifier usage") has a "Cc: [email protected]" tag.
Yes, it does, and that's why I've queued it up for 4.0-rc5 and not for 4.1.
Does it require any extra care or something?
Signature · 2 lines
I speak only for myself. Rafael J. Wysocki, Intel Open Source Technology Center.
Hi Rafael,
Quoted 8 lines · Rafael J. Wysocki
Quoted 4 lines
Quoted 1 line
Pulled, but this is a bit too late for 4.0-rc4, so I'll queue it up for -rc5.
Please note commit
43b68879de27b199("cpuidle: mvebu: Fix the CPU PM notifier usage") has a "Cc: [email protected]" tag.Yes, it does, and that's why I've queued it up for 4.0-rc5 and not for 4.1.
Does it require any extra care or something?
Nevermind, I replied too soon after reading "too late for 4.0...".
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
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