diff options
author | Chris Packham <judge.packham@gmail.com> | 2023-09-13 17:10:20 +1200 |
---|---|---|
committer | Chris Packham <judge.packham@gmail.com> | 2023-09-17 15:41:50 +1200 |
commit | c175b21ce470a07875a5db86f21439f02f93df0e (patch) | |
tree | fb9e2da6156e247142f9c67fe21edd5a5978f66a /packages/gcc/11.4.0/0023-aarch64-Minor-initial-adjustment-tweak.patch | |
parent | 977ed69427889a09f8e77ff9b60a6d50a18d8417 (diff) | |
download | crosstool-ng-c175b21ce470a07875a5db86f21439f02f93df0e.tar.gz crosstool-ng-c175b21ce470a07875a5db86f21439f02f93df0e.tar.bz2 crosstool-ng-c175b21ce470a07875a5db86f21439f02f93df0e.zip |
gcc: Bring in upstream fixes for CVE-2023-4039
Bring in the fixes for GCC 7 through 13.
https://rtx.meta.security/mitigation/2023/09/12/CVE-2023-4039.html
https://developer.arm.com/Arm%20Security%20Center/GCC%20Stack%20Protector%20Vulnerability%20AArch64
Signed-off-by: Chris Packham <judge.packham@gmail.com>
Diffstat (limited to 'packages/gcc/11.4.0/0023-aarch64-Minor-initial-adjustment-tweak.patch')
-rw-r--r-- | packages/gcc/11.4.0/0023-aarch64-Minor-initial-adjustment-tweak.patch | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/packages/gcc/11.4.0/0023-aarch64-Minor-initial-adjustment-tweak.patch b/packages/gcc/11.4.0/0023-aarch64-Minor-initial-adjustment-tweak.patch new file mode 100644 index 00000000..89ee42e6 --- /dev/null +++ b/packages/gcc/11.4.0/0023-aarch64-Minor-initial-adjustment-tweak.patch @@ -0,0 +1,38 @@ +From bb4600071acc3a02db4f37ffb95c8495ad76a140 Mon Sep 17 00:00:00 2001 +From: Richard Sandiford <richard.sandiford@arm.com> +Date: Tue, 12 Sep 2023 16:19:49 +0100 +Subject: [PATCH 23/29] aarch64: Minor initial adjustment tweak + +This patch just changes a calculation of initial_adjust +to one that makes it slightly more obvious that the total +adjustment is frame.frame_size. + +gcc/ + * config/aarch64/aarch64.c (aarch64_layout_frame): Tweak + calculation of initial_adjust for frames in which all saves + are SVE saves. +--- + gcc/config/aarch64/aarch64.c | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) + +diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c +index 779547d03447..0b8992ada747 100644 +--- a/gcc/config/aarch64/aarch64.c ++++ b/gcc/config/aarch64/aarch64.c +@@ -7645,11 +7645,10 @@ aarch64_layout_frame (void) + { + /* Frame in which all saves are SVE saves: + +- sub sp, sp, hard_fp_offset + below_hard_fp_saved_regs_size ++ sub sp, sp, frame_size - bytes_below_saved_regs + save SVE registers relative to SP + sub sp, sp, bytes_below_saved_regs */ +- frame.initial_adjust = (frame.bytes_above_hard_fp +- + frame.below_hard_fp_saved_regs_size); ++ frame.initial_adjust = frame.frame_size - frame.bytes_below_saved_regs; + frame.final_adjust = frame.bytes_below_saved_regs; + } + else if (frame.bytes_above_hard_fp.is_constant (&const_above_fp) +-- +2.42.0 + |