From 196b933d295975ada570dd8cc6e10b420cc83882 Mon Sep 17 00:00:00 2001 From: Chen Gang Date: Tue, 19 Nov 2013 11:10:43 +0800 Subject: arch: hexagon: kernel: add export symbol function __delay() Need add __delay() implementation, or can not pass allmodconfig in next-20131118 tree. The related error: CC kernel/locking/spinlock_debug.o kernel/locking/spinlock_debug.c: In function '__spin_lock_debug': kernel/locking/spinlock_debug.c:114:3: error: implicit declaration of function '__delay' [-Werror=implicit-function-declaration] Signed-off-by: Chen Gang Signed-off-by: Richard Kuo --- arch/hexagon/kernel/time.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'arch/hexagon/kernel') diff --git a/arch/hexagon/kernel/time.c b/arch/hexagon/kernel/time.c index d0c4f5a04b7b..17fbf45bf150 100644 --- a/arch/hexagon/kernel/time.c +++ b/arch/hexagon/kernel/time.c @@ -229,6 +229,15 @@ void __init time_init(void) late_time_init = time_init_deferred; } +void __delay(unsigned long cycles) +{ + unsigned long long start = __vmgettime(); + + while ((__vmgettime() - start) < cycles) + cpu_relax(); +} +EXPORT_SYMBOL(__delay); + /* * This could become parametric or perhaps even computed at run-time, * but for now we take the observed simulator jitter. -- cgit v1.2.1