From patchwork Thu Jul 30 18:36:37 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 51726 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f72.google.com (mail-la0-f72.google.com [209.85.215.72]) by patches.linaro.org (Postfix) with ESMTPS id BA07B22E7D for ; Thu, 30 Jul 2015 18:36:48 +0000 (UTC) Received: by lahh5 with SMTP id h5sf15076887lah.0 for ; Thu, 30 Jul 2015 11:36:47 -0700 (PDT) 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=pmZseinqnWc7aA8f8oEPnUAwBDzu2wpvf5urUQID/Zc=; b=G///pab9abTOfNh7G7nw2gU0X2aA2bOqaYn0g3bDF+tTdXd3CRnYeLAeHZXFLPVfZ/ jcFDVNOUBxY1wR3Y1H/eTr5kzB0zuEvCPrjbSn3uOuwK3DRJmpaN2PEMdCj5dFG4XQPq ZrgNcXrDTw7yYiZfDYjnTC+ir7Bt2JEyFw2mu95Yq9bedgCPwpyyaz3V6xDdyPMsDSJe F/Y3qD45TB3rUQzPH+N1xBQ7M6BsxczLB7HD/8Bx+3SmV2u9LQYyRkk7qI56o6no9UJV TsoG3KeNbQdk3BFX80kld1p4Y/CG46xSNZc30OSe4lZovLdr2Bk9YiZiAZzZakAUfwNz 9taw== X-Gm-Message-State: ALoCoQnLAxN4+612x4NIwLbYHKyKZfh231Hox7T99IQalBL5NZpWzP18KLU62sb45WvVEkiULe7y X-Received: by 10.180.106.10 with SMTP id gq10mr1496546wib.0.1438281407723; Thu, 30 Jul 2015 11:36:47 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.6.196 with SMTP id d4ls238566laa.91.gmail; Thu, 30 Jul 2015 11:36:47 -0700 (PDT) X-Received: by 10.112.124.33 with SMTP id mf1mr46178323lbb.66.1438281407568; Thu, 30 Jul 2015 11:36:47 -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 b8si1467414lbg.101.2015.07.30.11.36.47 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 30 Jul 2015 11:36:47 -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 lbbud7 with SMTP id ud7so28725662lbb.3 for ; Thu, 30 Jul 2015 11:36:47 -0700 (PDT) X-Received: by 10.112.219.70 with SMTP id pm6mr44758787lbc.41.1438281407479; Thu, 30 Jul 2015 11:36:47 -0700 (PDT) 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.112.7.198 with SMTP id l6csp784821lba; Thu, 30 Jul 2015 11:36:46 -0700 (PDT) X-Received: by 10.70.0.71 with SMTP id 7mr109134855pdc.157.1438281405520; Thu, 30 Jul 2015 11:36:45 -0700 (PDT) Received: from mnementh.archaic.org.uk (mnementh.archaic.org.uk. [2001:8b0:1d0::1]) by mx.google.com with ESMTPS id p5si4048471par.165.2015.07.30.11.36.43 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 30 Jul 2015 11:36:45 -0700 (PDT) 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 1ZKsh4-0004t0-9H; Thu, 30 Jul 2015 19:36:38 +0100 From: Peter Maydell To: qemu-devel@nongnu.org Cc: patches@linaro.org, "Edgar E. Iglesias" Subject: [PATCH 3/4] target-arm: Implement missing AFSR registers Date: Thu, 30 Jul 2015 19:36:37 +0100 Message-Id: <1438281398-18746-4-git-send-email-peter.maydell@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1438281398-18746-1-git-send-email-peter.maydell@linaro.org> References: <1438281398-18746-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=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 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: , The AFSR registers are implementation dependent auxiliary fault status registers. We already implemented a RAZ/WI AFSR0_EL1 and AFSR_EL1; add the missing AFSR{0,1}_EL{2,3} for consistency. Signed-off-by: Peter Maydell --- target-arm/helper.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/target-arm/helper.c b/target-arm/helper.c index 781b3a2..d286680 100644 --- a/target-arm/helper.c +++ b/target-arm/helper.c @@ -2610,6 +2610,14 @@ static const ARMCPRegInfo el3_no_el2_cp_reginfo[] = { .opc1 = 4, .crn = 10, .crm = 3, .opc2 = 1, .access = PL2_RW, .type = ARM_CP_CONST, .resetvalue = 0 }, + { .name = "AFSR0_EL2", .state = ARM_CP_STATE_BOTH, + .opc0 = 3, .opc1 = 4, .crn = 5, .crm = 1, .opc2 = 0, + .access = PL2_RW, .type = ARM_CP_CONST, + .resetvalue = 0 }, + { .name = "AFSR1_EL2", .state = ARM_CP_STATE_BOTH, + .opc0 = 3, .opc1 = 4, .crn = 5, .crm = 1, .opc2 = 1, + .access = PL2_RW, .type = ARM_CP_CONST, + .resetvalue = 0 }, { .name = "TCR_EL2", .state = ARM_CP_STATE_BOTH, .opc0 = 3, .opc1 = 4, .crn = 2, .crm = 0, .opc2 = 2, .access = PL2_RW, .type = ARM_CP_CONST, .resetvalue = 0 }, @@ -2713,6 +2721,14 @@ static const ARMCPRegInfo el2_cp_reginfo[] = { .opc1 = 4, .crn = 10, .crm = 3, .opc2 = 1, .access = PL2_RW, .type = ARM_CP_CONST, .resetvalue = 0 }, + { .name = "AFSR0_EL2", .state = ARM_CP_STATE_BOTH, + .opc0 = 3, .opc1 = 4, .crn = 5, .crm = 1, .opc2 = 0, + .access = PL2_RW, .type = ARM_CP_CONST, + .resetvalue = 0 }, + { .name = "AFSR1_EL2", .state = ARM_CP_STATE_BOTH, + .opc0 = 3, .opc1 = 4, .crn = 5, .crm = 1, .opc2 = 1, + .access = PL2_RW, .type = ARM_CP_CONST, + .resetvalue = 0 }, { .name = "TCR_EL2", .state = ARM_CP_STATE_BOTH, .opc0 = 3, .opc1 = 4, .crn = 2, .crm = 0, .opc2 = 2, .access = PL2_RW, .writefn = vmsa_tcr_el1_write, @@ -2819,6 +2835,14 @@ static const ARMCPRegInfo el3_cp_reginfo[] = { .opc0 = 3, .opc1 = 6, .crn = 10, .crm = 3, .opc2 = 0, .access = PL3_RW, .type = ARM_CP_CONST, .resetvalue = 0 }, + { .name = "AFSR0_EL3", .state = ARM_CP_STATE_BOTH, + .opc0 = 3, .opc1 = 6, .crn = 5, .crm = 1, .opc2 = 0, + .access = PL3_RW, .type = ARM_CP_CONST, + .resetvalue = 0 }, + { .name = "AFSR1_EL3", .state = ARM_CP_STATE_BOTH, + .opc0 = 3, .opc1 = 6, .crn = 5, .crm = 1, .opc2 = 1, + .access = PL3_RW, .type = ARM_CP_CONST, + .resetvalue = 0 }, REGINFO_SENTINEL };