Files
linux/arch/mips/include/asm
Kees Cook b847bd64ea MIPS: Only use current_stack_pointer on GCC
Unfortunately, Clang did not have support for "sp" as a global register
definition, and was crashing after the addition of current_stack_pointer.
This has been fixed in Clang 14, but earlier Clang versions need to
avoid this code, so add a versioned test and revert back to the
open-coded asm instances. Fixes Clang build error:

fatal error: error in backend: Invalid register name global variable

Fixes: 200ed341b8 ("mips: Implement "current_stack_pointer"")
Reported-by: Nathan Chancellor <nathan@kernel.org>
Reviewed-by: Nathan Chancellor <nathan@kernel.org>
Link: https://lore.kernel.org/lkml/YikTQRql+il3HbrK@dev-arch.thelio-3990X
Cc: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Cc: Marc Zyngier <maz@kernel.org>
Cc: Guenter Roeck <linux@roeck-us.net>
Cc: Yanteng Si <siyanteng01@gmail.com>
Cc: linux-mips@vger.kernel.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
2022-03-14 15:02:53 +01:00
..
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2020-09-07 22:25:27 +02:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2020-09-07 22:25:27 +02:00
2022-03-01 10:07:22 +01:00
2021-01-22 11:40:00 +01:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2020-09-07 22:25:27 +02:00
2020-09-07 22:25:27 +02:00
2021-12-14 10:03:45 +01:00
2022-03-01 10:07:22 +01:00
2022-01-05 11:16:35 +01:00
2021-11-17 10:36:15 -05:00
2022-01-05 11:16:35 +01:00
2021-09-08 15:32:35 -07:00
2020-11-11 23:49:22 +01:00
2021-10-24 17:24:47 +02:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2021-07-13 15:08:15 -05:00
2022-02-22 09:35:49 +01:00
2021-09-23 11:23:35 +02:00
2021-10-24 17:24:47 +02:00
2021-05-07 00:26:34 -07:00
2021-01-04 11:37:27 +01:00
2022-03-01 10:07:22 +01:00
2020-05-19 17:39:32 +02:00
2021-11-29 12:43:06 +01:00
2022-02-22 09:35:49 +01:00
2022-02-22 09:35:49 +01:00
2019-02-04 10:56:41 -08:00
2020-05-22 09:10:53 +02:00
2021-09-23 11:23:35 +02:00
2018-08-01 13:20:15 -07:00
2022-03-01 10:07:22 +01:00
2019-04-03 10:32:54 +02:00
2022-03-01 10:07:22 +01:00
2022-03-01 10:07:22 +01:00
2021-09-08 15:32:35 -07:00
2019-07-25 21:45:05 -07:00
2022-03-01 10:07:22 +01:00
2021-01-27 21:49:16 +01:00