From f1a4c1f33319e9d826df0ec040665501c6e8dca8 Mon Sep 17 00:00:00 2001 From: Chanwoo Choi Date: Wed, 24 Aug 2016 22:49:05 +0900 Subject: clocksource: exynos_mct: Add the support for ARM64 This patch allows building and compile-testing the driver also for ARM64. The delay_timer is only supported on ARMv7. Cc: Daniel Lezcano Cc: Thomas Gleixner Cc: Kukjin Kim Cc: Krzysztof Kozlowski Signed-off-by: Chanwoo Choi Acked-by: Daniel Lezcano [k.kozlowski: Adjusted commit msg] Signed-off-by: Krzysztof Kozlowski --- drivers/clocksource/exynos_mct.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'drivers/clocksource/exynos_mct.c') diff --git a/drivers/clocksource/exynos_mct.c b/drivers/clocksource/exynos_mct.c index 41840d02c331..8f3488b80896 100644 --- a/drivers/clocksource/exynos_mct.c +++ b/drivers/clocksource/exynos_mct.c @@ -223,6 +223,7 @@ static u64 notrace exynos4_read_sched_clock(void) return exynos4_read_count_32(); } +#if defined(CONFIG_ARM) static struct delay_timer exynos4_delay_timer; static cycles_t exynos4_read_current_timer(void) @@ -231,14 +232,17 @@ static cycles_t exynos4_read_current_timer(void) "cycles_t needs to move to 32-bit for ARM64 usage"); return exynos4_read_count_32(); } +#endif static int __init exynos4_clocksource_init(void) { exynos4_mct_frc_start(); +#if defined(CONFIG_ARM) exynos4_delay_timer.read_current_timer = &exynos4_read_current_timer; exynos4_delay_timer.freq = clk_rate; register_current_timer_delay(&exynos4_delay_timer); +#endif if (clocksource_register_hz(&mct_frc, clk_rate)) panic("%s: can't register clocksource\n", mct_frc.name); -- cgit v1.2.1