Add qemu 2.4.0
[kvmfornfv.git] / qemu / tests / tcg / mips / mips64-dspr2 / io.h
1 #ifndef _ASM_IO_H
2 #define _ASM_IO_H
3 extern int printf(const char *fmt, ...);
4 extern unsigned long get_ticks(void);
5
6 #define _read(source)                \
7 ({ unsigned long __res;                \
8     __asm__ __volatile__(            \
9         "mfc0\t%0, " #source "\n\t"    \
10         : "=r" (__res));        \
11     __res;                    \
12 })
13
14 #define __read(source)                \
15 ({ unsigned long __res;                \
16     __asm__ __volatile__(            \
17         "move\t%0, " #source "\n\t"    \
18         : "=r" (__res));        \
19     __res;                    \
20 })
21
22 #endif