diff options
author | Chen Liqin | 2009-06-12 16:01:00 +0200 |
---|---|---|
committer | Arnd Bergmann | 2009-06-19 11:38:47 +0200 |
commit | 6bc9a3966f0395419b09b2ec90f89f7f00341b37 (patch) | |
tree | 9c0d9d5376020266f5602501c8376d4a4f13142d /arch/score/include/asm/delay.h | |
parent | Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tyt... (diff) | |
download | kernel-qcow2-linux-6bc9a3966f0395419b09b2ec90f89f7f00341b37.tar.gz kernel-qcow2-linux-6bc9a3966f0395419b09b2ec90f89f7f00341b37.tar.xz kernel-qcow2-linux-6bc9a3966f0395419b09b2ec90f89f7f00341b37.zip |
score: Add support for Sunplus S+core architecture
This is the complete set of new arch Score's files for linux.
Score instruction set support 16bits, 32bits and 64bits instruction,
Score SOC had been used in game machine and LCD TV.
Signed-off-by: Chen Liqin <liqin.chen@sunplusct.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/score/include/asm/delay.h')
-rw-r--r-- | arch/score/include/asm/delay.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/arch/score/include/asm/delay.h b/arch/score/include/asm/delay.h new file mode 100644 index 000000000000..ad716f6d922d --- /dev/null +++ b/arch/score/include/asm/delay.h @@ -0,0 +1,21 @@ +#ifndef _ASM_SCORE_DELAY_H +#define _ASM_SCORE_DELAY_H + +static inline void __delay(unsigned long loops) +{ + __asm__ __volatile__ ( + "1:\tsubi\t%0,1\n\t" + "cmpz.c\t%0\n\t" + "bne\t1b\n\t" + : "=r" (loops) + : "0" (loops)); +} + +static inline void __udelay(unsigned long usecs) +{ + __delay(usecs); +} + +#define udelay(usecs) __udelay(usecs) + +#endif /* _ASM_SCORE_DELAY_H */ |