qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2 0/8] target-arm/linux-user-arm: implement set


From: Peter Maydell
Subject: Re: [Qemu-devel] [PATCH v2 0/8] target-arm/linux-user-arm: implement setend, CPSR.E, SCTLR.EE
Date: Thu, 5 Feb 2015 17:49:03 +0000

On 5 February 2015 at 17:33, Paolo Bonzini <address@hidden> wrote:
> Peter, I'm rebasing this and I'm unsure how SCTLR.EE should behave wrt
> EL2.  When setting CPSR_E from SCTLR.EE, should I use
> A32_BANKED_CURRENT_REG_GET or env->sctlr[MAX(arm_current_el(env), 1])?

This is for exception entry, yes? In the 32-bit exception entry
code path (arm_cpu_do_interrupt()) you want A32_BANKED_CURRENT_REG_GET
(and make sure you do it after we've switched mode/EL, not before).
In the 64-bit exception entry path there's no equivalent thing to
do because there's no CPSR.E in AArch64 (endianness is always
determined by the currently operative SCTLR.EE or SCTLR.E0E bit);
but your patchset isn't trying to address AArch64 in any case.

> And similarly, for the page-table walks does EL2 use the EL3 (sctlr_s)
> or EL2 (hsctlr) value?

For pagetable walks see the patchseries I just committed to master.
Table D4-1 in the v8 ARM ARM defines the semantics required, which
in QEMU terms is to check regime_sctlr(env, mmu_idx) & SCTLR_EE.

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]