ARM/ARM64: ipipe: Enable access to arch timer from user-space
Subsystems (2)
PATCH 1/1 ARM/ARM64: ipipe: Enable access to arch timer from user-space
From: Jan Kiszka <[email protected]>
This allows to expose the timer as clocksource directly to user-space by memory-mapping its registers.
Signed-off-by Jan Kiszka <[email protected]>
---
To be applied when splitting b597d0dec360 or after importing the partial revert of it from noarch.
arch/arm/include/asm/arch_timer.h | 4 ++++ 1 file changed, 4 insertions(+)
arch/arm/include/asm/arch_timer.h +4 -0
@@ -106,6 +106,10 @@ static inline u32 arch_timer_get_cntkctl(void)static inline void arch_timer_set_cntkctl (u32 cntkctl) { +#ifdef CONFIG_IPIPE +/* Enable access to user-space (may not be needed) */ + cntkctl |=ARCH_TIMER_USR_PCT_ACCESS_EN ; +#endif asmvolatile ("mcr p15, 0, %0, c14, c1, 0" : :"r" (cntkctl)); }
Signature · 1 line
2.16.4