Skip to content

alpha, avr, or1k, rx, tricore: Convert to translate_for_debug

Peter Maydell qemu-devel 1 version Applied

Status from this message: Queued, thanks.

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest5 patches 12 repliesApplied

Patches in v1 Applied

#Subject and filesSizeRepliesApplied
1/5target/alpha: Convert to translate_for_debugtarget/alpha/cpu.c target/alpha/cpu.h target/alpha/helper.c+16 -42 replies
2/5target/avr: Convert to translate_for_debugtarget/avr/cpu.c target/avr/cpu.h target/avr/helper.c+12 -42 replies
3/5target/or1k: Convert to translate_for_debugtarget/or1k/cpu.c target/or1k/cpu.h target/or1k/mmu.c+19 -72 replies
4/5target/rx: Convert to translate_for_debugtarget/rx/cpu.c target/rx/cpu.h target/rx/helper.c+11 -43 replies
5/5target/tricore: Convert to translate_for_debugtarget/tricore/cpu.c target/tricore/cpu.h target/tricore/helper.c+13 -52 replies

Reviews trailers per patch

All 5 patches have a Reviewed-by or Acked-by.

PatchRichard HendersonPhilippe Mathieu-DaudéYoshinori Sato
1/5R-b R-b
2/5R-b R-b
3/5R-b R-b
4/5R-b R-b R-b
5/5R-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v1 thread

Cover letter [PATCH 0/5] alpha, avr, or1k, rx, tricore: Convert to translate_for_debug

Earlier this year I did some work on the API that target CPUs use to provide "translate this virtual address to physical for a debug access". We now have a new method, translate_for_debug, but still support the old get_phys_addr_debug method as well.

This series does a bit of cleanup by converting five target architectures from the legacy method to the new one. Conversion is straightforward.

I have opted to follow the riscv translate_for_debug implementation in having the returned attrs set .debug and not also .unspecified (via MEMTXATTRS_UNSPECIFIED or otherwise), since on a per-architecture basis we can see that we don't want to set any of the other attributes in MemTxAttrs. This is a minor behaviour change from using the fallback codepath in cpu_translate_for_debug(), which starts with MEMTXATTRS_UNSPECIFIED and adds .debug, since it can't know whether the target architecture makes use of the various attribute fields. The only thing that we use the .unspecified field for is that the IOMMUs check it to see if they can look at attrs.requester_id etc, and debug accesses aren't going to be going through an IOMMU anyway, so this isn't a behaviour change in practice.

(There are another 10 archs still to convert, but I figured I'd just start with these five and see if there were review comments before doing the rest of them.)

thanks
--PMM

Peter Maydell (5):
target/alpha: Convert to translate_for_debug
target/avr: Convert to translate_for_debug
target/or1k: Convert to translate_for_debug
target/rx: Convert to translate_for_debug
target/tricore: Convert to translate_for_debug

 target/alpha/cpu.h      |  3 ++-
 target/avr/cpu.h        |  3 ++-
 target/or1k/cpu.h       |  3 ++-
 target/rx/cpu.h         |  3 ++-
 target/tricore/cpu.h    |  3 ++-
 target/alpha/cpu.c      |  2 +-
 target/alpha/helper.c   | 15 +++++++++++++--
 target/avr/cpu.c        |  2 +-
 target/avr/helper.c     | 11 +++++++++--
 target/or1k/cpu.c       |  2 +-
 target/or1k/mmu.c       | 21 ++++++++++++++++-----
 target/rx/cpu.c         |  2 +-
 target/rx/helper.c      | 10 ++++++++--
 target/tricore/cpu.c    |  2 +-
 target/tricore/helper.c | 13 ++++++++++---
 15 files changed, 71 insertions(+), 24 deletions(-)
Signature · 1 line
2.43.0