From patchwork Mon Mar 23 17:05:44 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 46210 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f199.google.com (mail-lb0-f199.google.com [209.85.217.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id C9F09214B0 for ; Mon, 23 Mar 2015 17:06:36 +0000 (UTC) Received: by lbvn10 with SMTP id n10sf28400342lbv.1 for ; Mon, 23 Mar 2015 10:06:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id:in-reply-to :references:mime-version:content-type:content-transfer-encoding:cc :subject:precedence:list-id:list-unsubscribe:list-archive:list-post :list-help:list-subscribe:errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list; bh=/f82zgzdzb8evKVrln+oR5S/YJ8up8OELoe4zj20Nw4=; b=CUFV3A5LwhnD+P00Xm2SoBhwzQhi6jx/kIhC2UZ13J31h2P57Qi0bEzrOnh7FaIk6F roTIOpam2zWpUGeSnpYfw6w6rRGN2OirvXJy6JLhx2cLFJIOw/58utSMLnrCDUdlo/I3 qbzaHFqPtfySkIzAJGhx5VxHtlmPGKdT2gXjPUxuF3yx/hz/wUEPQRRd69VGCYMWk+By HflGQxq0MOpfi3W8hWtkA5zlhBqkqKvDhg9cLSWMQpBmcPwq3T4/64j+Z0SxUtnPHExj aR7EIhKnhNTeqtstYzPbqtCmOzOEeYHkXIMRK/uXRI0f67nertOhx+RlGiUYIdgAjW2j o6Gg== X-Gm-Message-State: ALoCoQm6qc1QQ700DC+8dZduZho/DsHjnishWgRE8kI93RIyTnYKUbvEweJPjuwjj5g6XGYqjozq X-Received: by 10.112.77.101 with SMTP id r5mr53163lbw.4.1427130395760; Mon, 23 Mar 2015 10:06:35 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.180.75 with SMTP id dm11ls716902lac.70.gmail; Mon, 23 Mar 2015 10:06:35 -0700 (PDT) X-Received: by 10.152.6.34 with SMTP id x2mr48493lax.47.1427130395553; Mon, 23 Mar 2015 10:06:35 -0700 (PDT) Received: from mail-lb0-f171.google.com (mail-lb0-f171.google.com. [209.85.217.171]) by mx.google.com with ESMTPS id e4si1101350lab.13.2015.03.23.10.06.35 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 23 Mar 2015 10:06:35 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.171 as permitted sender) client-ip=209.85.217.171; Received: by lbbug6 with SMTP id ug6so28724414lbb.3 for ; Mon, 23 Mar 2015 10:06:35 -0700 (PDT) X-Received: by 10.112.185.66 with SMTP id fa2mr83296403lbc.117.1427130395469; Mon, 23 Mar 2015 10:06:35 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.57.201 with SMTP id k9csp954184lbq; Mon, 23 Mar 2015 10:06:34 -0700 (PDT) X-Received: by 10.55.31.97 with SMTP id f94mr576789qkf.10.1427130394056; Mon, 23 Mar 2015 10:06:34 -0700 (PDT) Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id w195si1239687qkw.99.2015.03.23.10.06.33 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Mon, 23 Mar 2015 10:06:34 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Received: from localhost ([::1]:57156 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ya5o9-00061U-4U for patch@linaro.org; Mon, 23 Mar 2015 13:06:33 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52153) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ya5n4-00059u-65 for qemu-devel@nongnu.org; Mon, 23 Mar 2015 13:05:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ya5mz-0005zQ-8J for qemu-devel@nongnu.org; Mon, 23 Mar 2015 13:05:26 -0400 Received: from static.88-198-71-155.clients.your-server.de ([88.198.71.155]:35918 helo=socrates.bennee.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ya5my-0005z9-M3 for qemu-devel@nongnu.org; Mon, 23 Mar 2015 13:05:20 -0400 Received: from localhost ([127.0.0.1] helo=zen.linaroharston) by socrates.bennee.com with esmtp (Exim 4.80) (envelope-from ) id 1Ya6rF-0005wQ-Nn; Mon, 23 Mar 2015 19:13:49 +0100 From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Date: Mon, 23 Mar 2015 17:05:44 +0000 Message-Id: <1427130344-27986-7-git-send-email-alex.bennee@linaro.org> X-Mailer: git-send-email 2.3.2 In-Reply-To: <1427130344-27986-1-git-send-email-alex.bennee@linaro.org> References: <1427130344-27986-1-git-send-email-alex.bennee@linaro.org> MIME-Version: 1.0 X-SA-Exim-Connect-IP: 127.0.0.1 X-SA-Exim-Mail-From: alex.bennee@linaro.org X-SA-Exim-Scanned: No (on socrates.bennee.com); SAEximRunCond expanded to false X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 88.198.71.155 Cc: Peter Maydell , kvm@vger.kernel.org, marc.zyngier@arm.com, linux-arm-kernel@lists.infradead.org, =?UTF-8?q?Alex=20Benn=C3=A9e?= , kvmarm@lists.cs.columbia.edu, christoffer.dall@linaro.org Subject: [Qemu-devel] [PATCH v5 6/6] target-arm: cpu.h document why env->spsr exists X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: alex.bennee@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.171 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 I was getting very confused about the duplication of state so wanted to make it explicit. Signed-off-by: Alex Bennée diff --git a/target-arm/cpu.h b/target-arm/cpu.h index 083211c..6dc1799 100644 --- a/target-arm/cpu.h +++ b/target-arm/cpu.h @@ -155,6 +155,11 @@ typedef struct CPUARMState { This contains all the other bits. Use cpsr_{read,write} to access the whole CPSR. */ uint32_t uncached_cpsr; + /* The spsr is a alias for spsr_elN where N is the current + * exception level. It is provided for here so the TCG msr/mrs + * implementation can access one register. Care needs to be taken + * to ensure the banked_spsr[] is also updated. + */ uint32_t spsr; /* Banked registers. */