All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] arm64: build CONFIG_ARM64_LSE_ATOMICS without -ffixed- flags
@ 2018-08-02 23:17 Tri Vo
  2018-08-03  8:43 ` Ard Biesheuvel
  0 siblings, 1 reply; 11+ messages in thread
From: Tri Vo @ 2018-08-02 23:17 UTC (permalink / raw)
  To: linux-arm-kernel

Remove -ffixed- compile flags as they are not required for correct
behavior of out-of-line ll/sc implementations of atomic functions.
Registers (except x0 which contains return value) only need to be
callee-saved, not necessarily fixed.

For readability purposes, represent "callee-saves-all-registers" calling
convention with a combination of -fcall-used- and -fcall-saved- flags only.

Signed-off-by: Tri Vo <trong@android.com>
---
 arch/arm64/lib/Makefile | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/arm64/lib/Makefile b/arch/arm64/lib/Makefile
index c86b7909ef31..05ba3d276c15 100644
--- a/arch/arm64/lib/Makefile
+++ b/arch/arm64/lib/Makefile
@@ -11,9 +11,9 @@ lib-y		:= bitops.o clear_user.o delay.o copy_from_user.o	\
 # when supported by the CPU. Result and argument registers are handled
 # correctly, based on the function prototype.
 lib-$(CONFIG_ARM64_LSE_ATOMICS) += atomic_ll_sc.o
-CFLAGS_atomic_ll_sc.o	:= -fcall-used-x0 -ffixed-x1 -ffixed-x2		\
-		   -ffixed-x3 -ffixed-x4 -ffixed-x5 -ffixed-x6		\
-		   -ffixed-x7 -fcall-saved-x8 -fcall-saved-x9		\
-		   -fcall-saved-x10 -fcall-saved-x11 -fcall-saved-x12	\
-		   -fcall-saved-x13 -fcall-saved-x14 -fcall-saved-x15	\
-		   -fcall-saved-x18
+CFLAGS_atomic_ll_sc.o	:= -fcall-used-x0 -fcall-saved-x1		\
+		   -fcall-saved-x2 -fcall-saved-x3 -fcall-saved-x4	\
+		   -fcall-saved-x5 -fcall-saved-x6 -fcall-saved-x7	\
+		   -fcall-saved-x8 -fcall-saved-x9 -fcall-saved-x10	\
+		   -fcall-saved-x11 -fcall-saved-x12 -fcall-saved-x13	\
+		   -fcall-saved-x14 -fcall-saved-x15 -fcall-saved-x18
--
2.18.0.597.ga71716f1ad-goog

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2018-08-06 22:00 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-02 23:17 [PATCH] arm64: build CONFIG_ARM64_LSE_ATOMICS without -ffixed- flags Tri Vo
2018-08-03  8:43 ` Ard Biesheuvel
2018-08-03 17:17   ` Nick Desaulniers
2018-08-03 17:27     ` Ard Biesheuvel
2018-08-03 19:08       ` Tri Vo
2018-08-03 19:13         ` Ard Biesheuvel
2018-08-03 19:34           ` Ard Biesheuvel
2018-08-04  1:05             ` Tri Vo
2018-08-04  7:21               ` Ard Biesheuvel
2018-08-06 21:54                 ` Tri Vo
2018-08-06 22:00                   ` Ard Biesheuvel

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.