arch: raise an error when compiling for an unknown ARM platform
[fio.git] / arch / arch-s390.h
1 #ifndef ARCH_S390_H
2 #define ARCH_S390_H
3
4 #define FIO_ARCH        (arch_s390)
5
6 #define nop             asm volatile("nop" : : : "memory")
7 #define read_barrier()  asm volatile("bcr 15,0" : : : "memory")
8 #define write_barrier() asm volatile("bcr 15,0" : : : "memory")
9
10 static inline unsigned long long get_cpu_clock(void)
11 {
12         unsigned long long clk;
13
14 #ifdef CONFIG_S390_Z196_FACILITIES
15         /*
16          * Fio needs monotonic (never lower), but not strict monotonic (never
17          * the same) so store clock fast is enough.
18          */
19         __asm__ __volatile__("stckf %0" : "=Q" (clk) : : "cc");
20 #else
21         __asm__ __volatile__("stck %0" : "=Q" (clk) : : "cc");
22 #endif
23         return clk>>12;
24 }
25
26 #define ARCH_CPU_CLOCK_CYCLES_PER_USEC 1
27 #define ARCH_HAVE_CPU_CLOCK
28 #undef ARCH_CPU_CLOCK_WRAPS
29
30 #define ARCH_HAVE_INIT
31 extern bool tsc_reliable;
32 static inline int arch_init(char *envp[])
33 {
34         tsc_reliable = true;
35         return 0;
36 }
37
38 #endif