diff options
| author | Ross Burton <ross.burton@arm.com> | 2023-07-13 12:01:19 +0100 |
|---|---|---|
| committer | Steve Sakoman <steve@sakoman.com> | 2023-07-26 05:20:36 -1000 |
| commit | a2bf83842a72c3dfe24a824c650a2f64d3fdf1b0 (patch) | |
| tree | 99fa2a9e79b6e86785c73afce1f7fb68fbed6c67 | |
| parent | 8585e789650d1c55d9ed8074976ae3229d6d9a39 (diff) | |
| download | poky-a2bf83842a72c3dfe24a824c650a2f64d3fdf1b0.tar.gz | |
machine/arch-arm64: add -mbranch-protection=standard
Enable branch protection (PAC/BTI) for all aarch64 builds. This was
previously enabled at a global level in the GCC build, but that breaks
the gcc test suite.
(From OE-Core rev: a1119750e9b3b9fae4fa9698d2ea3710a5a73768)
Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 8905639d1cdc5ce809cc5ecd9672f5e86bf8a579)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
| -rw-r--r-- | meta/conf/machine/include/arm/arch-arm64.inc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/meta/conf/machine/include/arm/arch-arm64.inc b/meta/conf/machine/include/arm/arch-arm64.inc index 0e2efb5a40..832d0000ac 100644 --- a/meta/conf/machine/include/arm/arch-arm64.inc +++ b/meta/conf/machine/include/arm/arch-arm64.inc | |||
| @@ -37,3 +37,8 @@ TUNE_ARCH = "${@bb.utils.contains('TUNE_FEATURES', 'aarch64', '${TUNE_ARCH_64}', | |||
| 37 | TUNE_PKGARCH = "${@bb.utils.contains('TUNE_FEATURES', 'aarch64', '${TUNE_PKGARCH_64}', '${TUNE_PKGARCH_32}', d)}" | 37 | TUNE_PKGARCH = "${@bb.utils.contains('TUNE_FEATURES', 'aarch64', '${TUNE_PKGARCH_64}', '${TUNE_PKGARCH_32}', d)}" |
| 38 | ABIEXTENSION = "${@bb.utils.contains('TUNE_FEATURES', 'aarch64', '${ABIEXTENSION_64}', '${ABIEXTENSION_32}', d)}" | 38 | ABIEXTENSION = "${@bb.utils.contains('TUNE_FEATURES', 'aarch64', '${ABIEXTENSION_64}', '${ABIEXTENSION_32}', d)}" |
| 39 | TARGET_FPU = "${@bb.utils.contains('TUNE_FEATURES', 'aarch64', '${TARGET_FPU_64}', '${TARGET_FPU_32}', d)}" | 39 | TARGET_FPU = "${@bb.utils.contains('TUNE_FEATURES', 'aarch64', '${TARGET_FPU_64}', '${TARGET_FPU_32}', d)}" |
| 40 | |||
| 41 | # Emit branch protection (PAC/BTI) instructions. On hardware that doesn't | ||
| 42 | # support these they're meaningless NOP instructions, so there's very little | ||
| 43 | # reason not to. | ||
| 44 | TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'aarch64', ' -mbranch-protection=standard', '', d)}" | ||
