1*b2441318SGreg Kroah-Hartman /* SPDX-License-Identifier: GPL-2.0 */ 29f97da78SDavid Howells #ifndef __ASM_ARM_COMPILER_H 39f97da78SDavid Howells #define __ASM_ARM_COMPILER_H 49f97da78SDavid Howells 59f97da78SDavid Howells /* 69f97da78SDavid Howells * This is used to ensure the compiler did actually allocate the register we 79f97da78SDavid Howells * asked it for some inline assembly sequences. Apparently we can't trust 89f97da78SDavid Howells * the compiler from one version to another so a bit of paranoia won't hurt. 99f97da78SDavid Howells * This string is meant to be concatenated with the inline asm string and 109f97da78SDavid Howells * will cause compilation to stop on mismatch. 119f97da78SDavid Howells * (for details, see gcc PR 15089) 12ada63d40SArd Biesheuvel * For compatibility with clang, we have to specifically take the equivalence 13ada63d40SArd Biesheuvel * of 'r11' <-> 'fp' and 'r12' <-> 'ip' into account as well. 149f97da78SDavid Howells */ 15ada63d40SArd Biesheuvel #define __asmeq(x, y) \ 16ada63d40SArd Biesheuvel ".ifnc " x "," y "; " \ 17ada63d40SArd Biesheuvel ".ifnc " x y ",fpr11; " \ 18ada63d40SArd Biesheuvel ".ifnc " x y ",r11fp; " \ 19ada63d40SArd Biesheuvel ".ifnc " x y ",ipr12; " \ 20ada63d40SArd Biesheuvel ".ifnc " x y ",r12ip; " \ 21ada63d40SArd Biesheuvel ".err; " \ 22ada63d40SArd Biesheuvel ".endif; " \ 23ada63d40SArd Biesheuvel ".endif; " \ 24ada63d40SArd Biesheuvel ".endif; " \ 25ada63d40SArd Biesheuvel ".endif; " \ 26ada63d40SArd Biesheuvel ".endif\n\t" 279f97da78SDavid Howells 289f97da78SDavid Howells 299f97da78SDavid Howells #endif /* __ASM_ARM_COMPILER_H */ 30