]> git.baikalelectronics.ru Git - kernel.git/commit
ARM: 8300/1: teach __asmeq that r11 == fp and r12 == ip
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Thu, 29 Jan 2015 17:09:13 +0000 (18:09 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 10 Feb 2015 10:23:11 +0000 (10:23 +0000)
commita1291ad794129c784fc1ea45c0f1ea584b035827
tree655ac5b0a4b3e69d1c34d5533c103998891fad27
parent62b87dd5a2305dc07ca42a60d42f9968c68d94a2
ARM: 8300/1: teach __asmeq that r11 == fp and r12 == ip

The __asmeq macro is used inside inline asm statements to ensure that
register asm variables that explicitly specify a register are mapped
correctly onto those registers when used in inline asm input and output
constraints. However, the string based matching fails to take into
account that 'fp' is often referred to as 'r11' and 'ip' is often
referred to as 'r12', (e.g., by clang), causing false negatives.

Fix this by making __asmeq consider the ("fp","r11"), ("r11","fp"),
("ip","r12") and ("r12","ip") cases specifically.

Reviewed-by: Alex Elder <elder@linaro.org>
Acked-by: Nicolas Pitre <nico@linaro.org>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/include/asm/compiler.h