From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52363) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YzRfh-0006sH-Ho for qemu-devel@nongnu.org; Mon, 01 Jun 2015 11:30:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YzRfd-0005vD-ME for qemu-devel@nongnu.org; Mon, 01 Jun 2015 11:30:37 -0400 Received: from mail-ie0-f173.google.com ([209.85.223.173]:36278) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YzRfd-0005uz-Hp for qemu-devel@nongnu.org; Mon, 01 Jun 2015 11:30:33 -0400 Received: by ieclw1 with SMTP id lw1so16537601iec.3 for ; Mon, 01 Jun 2015 08:30:32 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <1432881807-18164-8-git-send-email-edgar.iglesias@gmail.com> References: <1432881807-18164-1-git-send-email-edgar.iglesias@gmail.com> <1432881807-18164-8-git-send-email-edgar.iglesias@gmail.com> From: Peter Maydell Date: Mon, 1 Jun 2015 16:30:12 +0100 Message-ID: Content-Type: text/plain; charset=UTF-8 Subject: Re: [Qemu-devel] [PATCH v3 07/15] target-arm: Add TTBR0_EL2 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Edgar E. Iglesias" Cc: Edgar Iglesias , Sergey Fedorov , =?UTF-8?B?QWxleCBCZW5uw6ll?= , QEMU Developers , Alexander Graf On 29 May 2015 at 07:43, Edgar E. Iglesias wrote: > From: "Edgar E. Iglesias" > > Signed-off-by: Edgar E. Iglesias > --- > target-arm/helper.c | 14 ++++++++++++++ > 1 file changed, 14 insertions(+) > > diff --git a/target-arm/helper.c b/target-arm/helper.c > index df07a6a..193750b 100644 > --- a/target-arm/helper.c > +++ b/target-arm/helper.c > @@ -2533,6 +2533,12 @@ static const ARMCPRegInfo v8_el3_no_el2_cp_reginfo[] = { > { .name = "TPIDR_EL2", .state = ARM_CP_STATE_BOTH, > .opc0 = 3, .opc1 = 4, .opc2 = 2, .crn = 13, .crm = 0, > .access = PL2_RW, .type = ARM_CP_CONST, .resetvalue = 0 }, > + { .name = "TTBR0_EL2", .state = ARM_CP_STATE_AA64, > + .opc0 = 3, .opc1 = 4, .crn = 2, .crm = 0, .opc2 = 0, > + .access = PL2_RW, .type = ARM_CP_CONST, .resetvalue = 0 }, > + { .name = "HTTBR", .cp = 15, .crm = 2, .opc1 = 4, Preferred order: opc1, crm. Will fixup. > + { .name = "TTBR0_EL2", .state = ARM_CP_STATE_AA64, > + .opc0 = 3, .opc1 = 4, .crn = 2, .crm = 0, .opc2 = 0, > + .access = PL2_RW, .writefn = vmsa_ttbr_write, .resetvalue = 0, > + .fieldoffset = offsetof(CPUARMState, cp15.ttbr0_el[2]) }, > + { .name = "HTTBR", .cp = 15, .crm = 2, .opc1 = 4, > + .access = PL2_RW, .type = ARM_CP_64BIT | ARM_CP_ALIAS, > + .writefn = vmsa_ttbr_write, .resetvalue = 0, > + .fieldoffset = offsetof(CPUARMState, cp15.ttbr0_el[2]) }, There's no ASID in a TTBR0_EL2/HTTBR, so we don't need to use the vmsa_ttbr_write function. Will drop that field setting. -- PMM