Skip to content

target/arm: Allow compilation without CONFIG_ARM_V7M

Thomas Huth qemu-arm qemu-devel 3 versions – Applied

Status from this message: I've applied patch 1 to target-arm.next; thanks.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest3 patches 1 replyApplied
  2. v23 patches 13 repliesSuperseded
  3. v13 patches 3 repliesSuperseded

Changes in v3 from the cover letter

- Rebase to current master branch
- Make sure that the stubs use g_assert_not_reached() in the second patch

Patches in v3 Applied

#Subject and filesSizeRepliesApplied
1/3target/arm: Move v7m-related code from cpu32.c into a separate filetarget/arm/meson.build target/arm/tcg/cpu-v7m.c target/arm/tcg/cpu32.c +1 more+296 -2610 replies
2/3target/arm/tcg/m_helper.c: Include the full helpers only with CONFIG_ARM_V7Mtarget/arm/tcg/m_helper.c+61 -320 replies
3/3target/arm/Kconfig: Stop requiring CONFIG_ARM_V7Mtarget/arm/Kconfig+0 -40 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v3 yet.

Read the v3 thread

Cover letter [PATCH v3 0/3] target/arm: Allow compilation without CONFIG_ARM_V7M

We've got a switch to disable v7m code since a long time - but it currently cannot be disabled since linking then fails due to missing functions. But thanks to the clean-ups that have been done during the past years, it's not that difficult anymore to finally make it possible to disable CONFIG_ARM_V7M: We just have to move some v7m-related code out of cpu32.c to a separate file (that we only compile if the switch CONFIG_ARM_V7M is enabled) and make sure to use the stub functions in m_helper.c if it is disabled. Then we can finally remove the hard-coded "select ARM_V7M" from the Kconfig file.

v3:
- Rebase to current master branch
- Make sure that the stubs use g_assert_not_reached() in the second patch

v2:
- Updated a comment
- Avoid #ifdef in cpu-v7m.c, handle it via meson.build instead

Thomas Huth (3):
target/arm: Move v7m-related code from cpu32.c into a separate file target/arm/tcg/m_helper.c: Include the full helpers only with
CONFIG_ARM_V7M
target/arm/Kconfig: Stop requiring CONFIG_ARM_V7M

 target/arm/tcg/cpu-v7m.c   | 290 +++++++++++++++++++++++++++++++++++++
 target/arm/tcg/cpu32.c     | 261 ---------------------------------
 target/arm/tcg/m_helper.c  |  93 ++++++++----
 target/arm/Kconfig         |   4 -
 target/arm/meson.build     |   3 +
 target/arm/tcg/meson.build |   3 +
 6 files changed, 357 insertions(+), 297 deletions(-)
 create mode 100644 target/arm/tcg/cpu-v7m.c
Signature · 1 line
2.44.0