Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
target/arm: make arm_casq_ptw CONFIG_TCG only
The ptw code is accessed by non-TCG code (specifically arm_pamax and
arm_cpu_get_phys_page_attrs_debug) but most of it is really only for
TCG emulation. Seeing as we already assert for a non TARGET_AARCH64
build lets extend the test rather than further messing with the ifdef
ladder.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20230630180423.558337-19-alex.bennee@linaro.org>
  • Loading branch information
stsquad committed Jul 3, 2023
1 parent 7ea47af commit 465af4d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions target/arm/ptw.c
Expand Up @@ -628,7 +628,7 @@ static uint64_t arm_casq_ptw(CPUARMState *env, uint64_t old_val,
uint64_t new_val, S1Translate *ptw,
ARMMMUFaultInfo *fi)
{
#ifdef TARGET_AARCH64
#if defined(TARGET_AARCH64) && defined(CONFIG_TCG)
uint64_t cur_val;
void *host = ptw->out_host;

Expand Down Expand Up @@ -709,7 +709,7 @@ static uint64_t arm_casq_ptw(CPUARMState *env, uint64_t old_val,

return cur_val;
#else
/* AArch32 does not have FEAT_HADFS. */
/* AArch32 does not have FEAT_HADFS; non-TCG guests only use debug-mode. */
g_assert_not_reached();
#endif
}
Expand Down

0 comments on commit 465af4d

Please sign in to comment.