Use architected timers for delay loop
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest2 patches 0 repliesNew
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | ARM: arch timer: implement read_current_timer and get_cyclesarch/ arch/ arch/ | +15 | 1 reply | |
| 1/2 | ARM: arch timer: implement read_current_timer and get_cycles | +0 | 1 reply | |
| 2/2 | ARM: delay: allow timer-based delay implementation to be selectedarch/ arch/ arch/ +4 more | +97 | 1 reply | |
| 2/2 | ARM: delay: allow timer-based delay implementation to be selected | +0 | 1 reply | |
| 2/2 | ARM: delay: allow timer-based delay implementation to be selectedarch/ arch/ arch/ | +16 | 1 reply | |
| 2/2 | ARM: delay: allow timer-based delay implementation to be selected | +0 | 0 replies | |
| 2/2 | ARM: delay: allow timer-based delay implementation to be selected | +0 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 0/2] Use architected timers for delay loop
Hello,
This patch series reworks our delay loop implementation to allow the busy-loop to be replaced with the physical counter included as part of the architected timer on recent CPUs. The polling implementation is still maintained to support cores without the timers and we use the same maths and upper delay bound of 2ms.
Russell - I think my maths is correct, but why can't we increase the
precision by using a magic constant of 4398046U and a right shift of 31?
As usual, all feedback is welcome,
Will
Will Deacon (2):
ARM: arch timer: implement read_current_timer and get_cycles
ARM: delay: allow timer-based delay implementation to be selected
arch/arm/include/asm/arch_timer.h | 1 +
arch/arm/include/asm/delay.h | 19 +++++++--
arch/arm/include/asm/timex.h | 10 +++--
arch/arm/kernel/arch_timer.c | 11 +++++
arch/arm/kernel/armksyms.c | 3 +-
arch/arm/lib/Makefile | 2 +-
arch/arm/lib/{delay.S => delay-loop.S} | 16 +++----
arch/arm/lib/delay.c | 66 ++++++++++++++++++++++++++++++++
arch/arm/mach-sa1100/sleep.S | 8 ++--
9 files changed, 112 insertions(+), 24 deletions(-)
rename arch/arm/lib/{delay.S => delay-loop.S} (85%)
create mode 100644 arch/arm/lib/delay.cSignature · 1 line
1.7.4.1