Merge tag 'for-linus-5.9-rc3-tag' of git://git.kernel.org/pub/scm/linux/kernel/git...
[linux-2.6-microblaze.git] / arch / arm / include / asm / vdso / processor.h
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3  * Copyright (C) 2020 ARM Ltd.
4  */
5 #ifndef __ASM_VDSO_PROCESSOR_H
6 #define __ASM_VDSO_PROCESSOR_H
7
8 #ifndef __ASSEMBLY__
9
10 #if __LINUX_ARM_ARCH__ == 6 || defined(CONFIG_ARM_ERRATA_754327)
11 #define cpu_relax()                                             \
12         do {                                                    \
13                 smp_mb();                                       \
14                 __asm__ __volatile__("nop; nop; nop; nop; nop; nop; nop; nop; nop; nop;");      \
15         } while (0)
16 #else
17 #define cpu_relax()                     barrier()
18 #endif
19
20 #endif /* __ASSEMBLY__ */
21
22 #endif /* __ASM_VDSO_PROCESSOR_H */