From patchwork Tue Jan 21 20:12:22 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 23455 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vc0-f198.google.com (mail-vc0-f198.google.com [209.85.220.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 4D9F5202DA for ; Tue, 21 Jan 2014 20:12:47 +0000 (UTC) Received: by mail-vc0-f198.google.com with SMTP id lf12sf14284044vcb.9 for ; Tue, 21 Jan 2014 12:12:46 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=GJFuRtl9bfESVLreY++CCST083QdynUFxHvFgap/PdA=; b=bJnUTRx/dPix+Mg+y6huRB57aJlOiQKQFq/aDX8sClmqUbxfN7wsLE5LqUJAHD6gDO gC9sE1qk1yLEDJ5/o+q1EAWQCNNLhzoX7Oz9m0qlfv1NO2Ljcs1bABA7TZoQxAGTPqvI IyMRriLeCzud79sZmty/bR25PyB/TYrI3SQJRMg/sWwkTpuub8Q78Grlf3pblgHRb7UT +iI3xWXTL/NS8dTrzod82pjE3BZkG3ob7WiwwevrHEigpGFk2XiSTTTMlK4Gr5EE0K2U fPZp3esP737dhJLVxs8HaUq4suBfjqh4ZA+HpnOnR7szHOt0wcCmJBhe9i9HDXLbuO1p Wx3g== X-Gm-Message-State: ALoCoQl65xKgf4eGPjUVS7li1FdJZe8DPT39QHgimwUXJ+VUoNV+oQJlaLbECp4Z7rkPseHJm6nu X-Received: by 10.58.43.132 with SMTP id w4mr9066542vel.20.1390335166547; Tue, 21 Jan 2014 12:12:46 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.36.229 with SMTP id t5ls1925709qej.61.gmail; Tue, 21 Jan 2014 12:12:46 -0800 (PST) X-Received: by 10.58.66.137 with SMTP id f9mr10063063vet.11.1390335166464; Tue, 21 Jan 2014 12:12:46 -0800 (PST) Received: from mail-vc0-f173.google.com (mail-vc0-f173.google.com [209.85.220.173]) by mx.google.com with ESMTPS id df13si2770554vec.148.2014.01.21.12.12.46 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 21 Jan 2014 12:12:46 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.173 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.173; Received: by mail-vc0-f173.google.com with SMTP id ld13so3883486vcb.32 for ; Tue, 21 Jan 2014 12:12:46 -0800 (PST) X-Received: by 10.58.85.133 with SMTP id h5mr15315380vez.4.1390335166397; Tue, 21 Jan 2014 12:12:46 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp138958vcz; Tue, 21 Jan 2014 12:12:45 -0800 (PST) X-Received: by 10.194.219.132 with SMTP id po4mr13023583wjc.7.1390335165541; Tue, 21 Jan 2014 12:12:45 -0800 (PST) Received: from mnementh.archaic.org.uk (mnementh.archaic.org.uk. [2001:8b0:1d0::1]) by mx.google.com with ESMTPS id jy10si4249990wjc.173.2014.01.21.12.12.43 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Tue, 21 Jan 2014 12:12:45 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of pm215@archaic.org.uk designates 2001:8b0:1d0::1 as permitted sender) client-ip=2001:8b0:1d0::1; Received: from pm215 by mnementh.archaic.org.uk with local (Exim 4.80) (envelope-from ) id 1W5hgV-0003Wl-Me; Tue, 21 Jan 2014 20:12:31 +0000 From: Peter Maydell To: qemu-devel@nongnu.org Cc: patches@linaro.org, Alexander Graf , Michael Matz , Claudio Fontana , Dirk Mueller , Laurent Desnogues , kvmarm@lists.cs.columbia.edu, Richard Henderson , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Christoffer Dall , Will Newton , Peter Crosthwaite Subject: [PATCH 16/24] target-arm: Implement AArch64 SCTLR_EL1 Date: Tue, 21 Jan 2014 20:12:22 +0000 Message-Id: <1390335150-13470-17-git-send-email-peter.maydell@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1390335150-13470-1-git-send-email-peter.maydell@linaro.org> References: <1390335150-13470-1-git-send-email-peter.maydell@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: peter.maydell@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.173 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Implement the AArch64 view of the system control register SCTLR_EL1. Signed-off-by: Peter Maydell --- target-arm/cpu.h | 2 +- target-arm/helper.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/target-arm/cpu.h b/target-arm/cpu.h index c8b6cdb..16f1d27 100644 --- a/target-arm/cpu.h +++ b/target-arm/cpu.h @@ -169,7 +169,7 @@ typedef struct CPUARMState { struct { uint32_t c0_cpuid; uint64_t c0_cssel; /* Cache size selection. */ - uint32_t c1_sys; /* System control register. */ + uint64_t c1_sys; /* System control register. */ uint32_t c1_coproc; /* Coprocessor access register. */ uint32_t c1_xscaleauxcr; /* XScale auxiliary control register. */ uint32_t c1_scr; /* secure config register. */ diff --git a/target-arm/helper.c b/target-arm/helper.c index d03c0cd..f8f034c 100644 --- a/target-arm/helper.c +++ b/target-arm/helper.c @@ -2055,7 +2055,8 @@ void register_cp_regs_for_features(ARMCPU *cpu) /* Generic registers whose values depend on the implementation */ { ARMCPRegInfo sctlr = { - .name = "SCTLR", .cp = 15, .crn = 1, .crm = 0, .opc1 = 0, .opc2 = 0, + .name = "SCTLR", .state = ARM_CP_STATE_BOTH, + .opc0 = 3, .crn = 1, .crm = 0, .opc1 = 0, .opc2 = 0, .access = PL1_RW, .fieldoffset = offsetof(CPUARMState, cp15.c1_sys), .writefn = sctlr_write, .resetvalue = cpu->reset_sctlr, .raw_writefn = raw_write,