aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOlof Johansson <olof@lixom.net>2017-11-29 20:55:18 -0500
committerPalmer Dabbelt <palmer@sifive.com>2017-11-30 13:12:21 -0500
commit4a41d5dbb0bbd0c3faffb2ccd8ef1a7aeb12f978 (patch)
tree7be1afce63369d5a6caf0ff85e15af36b7b53dc0
parent4bde63286a6c7c76fe05ff0e03ad253f5260b104 (diff)
RISC-V: Use define for get_cycles like other architectures
Signed-off-by: Olof Johansson <olof@lixom.net> Signed-off-by: Palmer Dabbelt <palmer@sifive.com>
-rw-r--r--arch/riscv/include/asm/timex.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/riscv/include/asm/timex.h b/arch/riscv/include/asm/timex.h
index 3df4932d8964..2f26989cb864 100644
--- a/arch/riscv/include/asm/timex.h
+++ b/arch/riscv/include/asm/timex.h
@@ -18,7 +18,7 @@
18 18
19typedef unsigned long cycles_t; 19typedef unsigned long cycles_t;
20 20
21static inline cycles_t get_cycles(void) 21static inline cycles_t get_cycles_inline(void)
22{ 22{
23 cycles_t n; 23 cycles_t n;
24 24
@@ -27,6 +27,7 @@ static inline cycles_t get_cycles(void)
27 : "=r" (n)); 27 : "=r" (n));
28 return n; 28 return n;
29} 29}
30#define get_cycles get_cycles_inline
30 31
31#ifdef CONFIG_64BIT 32#ifdef CONFIG_64BIT
32static inline uint64_t get_cycles64(void) 33static inline uint64_t get_cycles64(void)