mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-08 02:03:56 -06:00
hw/arm/smmu: Introduce CACHED_ENTRY_TO_ADDR
Soon, smmuv3_do_translate() will be used to translate the CD and the TTBx, instead of re-writting the same logic to convert the returned cached entry to an address, add a new macro CACHED_ENTRY_TO_ADDR. Reviewed-by: Eric Auger <eric.auger@redhat.com> Signed-off-by: Mostafa Saleh <smostafa@google.com> Reviewed-by: Jean-Philippe Brucker <jean-philippe@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Message-id: 20240715084519.1189624-8-smostafa@google.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
d883822641
commit
ec31ef9115
2 changed files with 4 additions and 2 deletions
|
@ -951,8 +951,7 @@ epilogue:
|
|||
switch (status) {
|
||||
case SMMU_TRANS_SUCCESS:
|
||||
entry.perm = cached_entry->entry.perm;
|
||||
entry.translated_addr = cached_entry->entry.translated_addr +
|
||||
(addr & cached_entry->entry.addr_mask);
|
||||
entry.translated_addr = CACHED_ENTRY_TO_ADDR(cached_entry, addr);
|
||||
entry.addr_mask = cached_entry->entry.addr_mask;
|
||||
trace_smmuv3_translate_success(mr->parent_obj.name, sid, addr,
|
||||
entry.translated_addr, entry.perm,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue