mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 07:13:54 -06:00
target/ppc: Introduce an mmu_is_64bit() helper
Callers don't really need to know how 64-bit MMU model enums are computed. Hide this in a helper. Signed-off-by: Greg Kurz <groug@kaod.org> Message-Id: <20201209173536.1437351-3-groug@kaod.org> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
d55dfd446c
commit
d57d72a874
7 changed files with 17 additions and 12 deletions
|
@ -266,7 +266,7 @@ static inline void powerpc_excp(PowerPCCPU *cpu, int excp_model, int excp)
|
|||
*/
|
||||
if (excp == POWERPC_EXCP_HV_EMU
|
||||
#if defined(TARGET_PPC64)
|
||||
&& !((env->mmu_model & POWERPC_MMU_64) && (env->msr_mask & MSR_HVB))
|
||||
&& !(mmu_is_64bit(env->mmu_model) && (env->msr_mask & MSR_HVB))
|
||||
#endif /* defined(TARGET_PPC64) */
|
||||
|
||||
) {
|
||||
|
@ -824,7 +824,7 @@ static inline void powerpc_excp(PowerPCCPU *cpu, int excp_model, int excp)
|
|||
vector = (uint32_t)vector;
|
||||
}
|
||||
} else {
|
||||
if (!msr_isf && !(env->mmu_model & POWERPC_MMU_64)) {
|
||||
if (!msr_isf && !mmu_is_64bit(env->mmu_model)) {
|
||||
vector = (uint32_t)vector;
|
||||
} else {
|
||||
new_msr |= (target_ulong)1 << MSR_SF;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue