From patchwork Sat Feb 15 16:07:06 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 24704 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ob0-f199.google.com (mail-ob0-f199.google.com [209.85.214.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 9F455203BE for ; Sat, 15 Feb 2014 16:08:23 +0000 (UTC) Received: by mail-ob0-f199.google.com with SMTP id vb8sf51130774obc.2 for ; Sat, 15 Feb 2014 08:08:22 -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=2Z1vpXhzRG8M6Hkmgw1DlTJsVGzsjpI0/iS6ehV3/Ow=; b=QCIBHOgOjop1HCRLYiwMdE4/6spMoRybYzL3wEqDMD4eDcwLITbEBaJNycloxYd2Xa 1yuyxiaKEC3BwDO1LtrhePw2LUbRB5naV5uJZ81KT2Qxkc5dB6GIlyrFClZ4C4mFNNRR oG+FfUqI65j+YbnvVYcDsd0iALQGVhuzHekHbsYkS6bfYbyOsYWzAsLgHjTSdgSGnQFv 8lU/Yoxz+MWManmb028Osn39cckqEpaXCQriZh4+wqcGdiaKdlNNnzwjYaCPrcR7KzcH 5cYnlbSuU09EoSTE4Wh7tkiPCh1GKxWvFSXnb2BddrZyivEkuv04XRZNYoe1WCuT+1ro fLUw== X-Gm-Message-State: ALoCoQkJtnxGnIbanU5vOZwHW/QCHF5FjKpyscTfIgORq4NOirsLhDn/Wypuv/YMketWA7/ex7AO X-Received: by 10.43.14.137 with SMTP id pq9mr5400008icb.12.1392480502748; Sat, 15 Feb 2014 08:08:22 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.87.5 with SMTP id q5ls394617qgd.99.gmail; Sat, 15 Feb 2014 08:08:22 -0800 (PST) X-Received: by 10.220.53.66 with SMTP id l2mr5736660vcg.33.1392480502614; Sat, 15 Feb 2014 08:08:22 -0800 (PST) Received: from mail-vc0-f175.google.com (mail-vc0-f175.google.com [209.85.220.175]) by mx.google.com with ESMTPS id sq4si3003645vdc.54.2014.02.15.08.08.22 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 15 Feb 2014 08:08:22 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.175 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.175; Received: by mail-vc0-f175.google.com with SMTP id ij19so10341935vcb.34 for ; Sat, 15 Feb 2014 08:08:22 -0800 (PST) X-Received: by 10.52.107.35 with SMTP id gz3mr8294315vdb.8.1392480502539; Sat, 15 Feb 2014 08:08:22 -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 u4csp25606vcz; Sat, 15 Feb 2014 08:08:21 -0800 (PST) X-Received: by 10.204.99.136 with SMTP id u8mr9162021bkn.26.1392480496454; Sat, 15 Feb 2014 08:08:16 -0800 (PST) Received: from mnementh.archaic.org.uk (mnementh.archaic.org.uk. [2001:8b0:1d0::1]) by mx.google.com with ESMTPS id xw1si3931419bkb.14.2014.02.15.08.08.14 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sat, 15 Feb 2014 08:08:16 -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 1WEhm1-0006fe-Bg; Sat, 15 Feb 2014 16:07:25 +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 , Rob Herring Subject: [PATCH v3 13/31] target-arm: Implement AArch64 MPIDR Date: Sat, 15 Feb 2014 16:07:06 +0000 Message-Id: <1392480444-25565-14-git-send-email-peter.maydell@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1392480444-25565-1-git-send-email-peter.maydell@linaro.org> References: <1392480444-25565-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.175 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 MPIDR system register. Signed-off-by: Peter Maydell Reviewed-by: Peter Crosthwaite --- target-arm/helper.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/target-arm/helper.c b/target-arm/helper.c index f5d9d2f..c81e73f 100644 --- a/target-arm/helper.c +++ b/target-arm/helper.c @@ -1435,7 +1435,8 @@ static uint64_t mpidr_read(CPUARMState *env, const ARMCPRegInfo *ri) { CPUState *cs = CPU(arm_env_get_cpu(env)); uint32_t mpidr = cs->cpu_index; - /* We don't support setting cluster ID ([8..11]) + /* We don't support setting cluster ID ([8..11]) (known as Aff1 + * in later ARM ARM versions), or any of the higher affinity level fields, * so these bits always RAZ. */ if (arm_feature(env, ARM_FEATURE_V7MP)) { @@ -1450,7 +1451,8 @@ static uint64_t mpidr_read(CPUARMState *env, const ARMCPRegInfo *ri) } static const ARMCPRegInfo mpidr_cp_reginfo[] = { - { .name = "MPIDR", .cp = 15, .crn = 0, .crm = 0, .opc1 = 0, .opc2 = 5, + { .name = "MPIDR", .state = ARM_CP_STATE_BOTH, + .opc0 = 3, .crn = 0, .crm = 0, .opc1 = 0, .opc2 = 5, .access = PL1_R, .readfn = mpidr_read, .type = ARM_CP_NO_MIGRATE }, REGINFO_SENTINEL };