Skip to content

Commit

Permalink
Reland "CHROMIUM: riscv: Hack riscv arch flags"
Browse files Browse the repository at this point in the history
This reverts commit 002281f.

Reason for revert: ARM boot loops with GCC 14.2 b/376074511

Original change's description:
> Revert "CHROMIUM: riscv: Hack riscv arch flags"
>
> This reverts commit a15a310.
>
> Reason for revert: Updating to GCC 14.2
>
> Original change's description:
> > CHROMIUM: riscv: Hack riscv arch flags
> >
> > When using the coreboot-sdk, don't append zicsr or zifencei to the
> > -march flag. Once coreboot-sdk supports isa-spec=20191213 or upgrades
> > to gcc 12, then revert this cl.
> >
> > BRANCH=None
> > BUG=b:245409408
> > TEST=zmake build -a
> >
> > Signed-off-by: Jeremy Bettis <jbettis@google.com>
> > Change-Id: Ia712f6d97dace15bdb5cb7d36bbf864db046c0d0
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/3884659
> > Tested-by: Jeremy Bettis <jbettis@chromium.org>
> > Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
> > Reviewed-by: Aaron Massey <aaronmassey@google.com>
>
> BUG=b:245409408
>
> Change-Id: I6b0ab35c43fac0f635bc8bf3a5da5f960dd77508
> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/5949063
> Commit-Queue: Jonathon Murphy <jpmurphy@google.com>
> Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
> Tested-by: Jonathon Murphy <jpmurphy@google.com>

BUG=b:245409408
BUG=b:376074511

Cq-Depend: chromium:5972409
Cq-Depend: chromium:5972715

Change-Id: I84362cfbeddf446508cb53b28c1021eae065229e
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/5973373
Tested-by: Jonathon Murphy <jpmurphy@google.com>
Commit-Queue: Jonathon Murphy <jpmurphy@google.com>
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
  • Loading branch information
jpmurphy-google authored and Chromeos LUCI committed Oct 29, 2024
1 parent fcd9b0a commit 0870f0b
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions cmake/compiler/gcc/target_riscv.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,15 @@ if(CONFIG_RISCV_ISA_EXT_C)
string(CONCAT riscv_march ${riscv_march} "c")
endif()

if(CONFIG_RISCV_ISA_EXT_ZICSR)
string(CONCAT riscv_march ${riscv_march} "_zicsr")
endif()
# TODO(b/245409408): Revert this when coreboot-sdk supports isa-spec=20191213
if (NOT ZEPHYR_TOOLCHAIN_VARIANT STREQUAL "coreboot-sdk")
if(CONFIG_RISCV_ISA_EXT_ZICSR)
string(CONCAT riscv_march ${riscv_march} "_zicsr")
endif()

if(CONFIG_RISCV_ISA_EXT_ZIFENCEI)
string(CONCAT riscv_march ${riscv_march} "_zifencei")
if(CONFIG_RISCV_ISA_EXT_ZIFENCEI)
string(CONCAT riscv_march ${riscv_march} "_zifencei")
endif()
endif()

if(CONFIG_RISCV_ISA_EXT_ZBA)
Expand Down

0 comments on commit 0870f0b

Please sign in to comment.