From nobody Wed May 7 16:29:19 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=linaro.org Return-Path: <qemu-devel-bounces+importer=patchew.org@nongnu.org> Received: from lists.gnu.org (209.51.188.17 [209.51.188.17]) by mx.zohomail.com with SMTPS id 1549038192043579.7762698979204; Fri, 1 Feb 2019 08:23:12 -0800 (PST) Received: from localhost ([127.0.0.1]:57460 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <qemu-devel-bounces+importer=patchew.org@nongnu.org>) id 1gpbar-0004D8-W9 for importer@patchew.org; Fri, 01 Feb 2019 11:23:06 -0500 Received: from eggs.gnu.org ([209.51.188.92]:58926) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <peter.maydell@linaro.org>) id 1gpbMB-0008EX-Mr for qemu-devel@nongnu.org; Fri, 01 Feb 2019 11:08:01 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <peter.maydell@linaro.org>) id 1gpbM9-0003hF-NX for qemu-devel@nongnu.org; Fri, 01 Feb 2019 11:07:55 -0500 Received: from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c]:52134) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from <peter.maydell@linaro.org>) id 1gpbM9-0003QW-Ek for qemu-devel@nongnu.org; Fri, 01 Feb 2019 11:07:53 -0500 Received: by mail-wm1-x32c.google.com with SMTP id b11so6677152wmj.1 for <qemu-devel@nongnu.org>; Fri, 01 Feb 2019 08:07:29 -0800 (PST) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [81.2.115.148]) by smtp.gmail.com with ESMTPSA id n6sm2847250wmk.9.2019.02.01.08.07.27 for <qemu-devel@nongnu.org> (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 01 Feb 2019 08:07:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=JzXbfa/mpewAIZNTdsRet1eOCUFT+GoezAer5VbBH7I=; b=Em1QBDHZGvH6bgLTx/OleNcTPE+eczmlrARDLL/oTCD/6W79CJCkGW+sEByQlD1zow mbbEhGENfaXwVIet+wCdoezAERB98nHYBsQL2haaf4HrBARzQTAr1r2KsIBICQ0ZC55k pJ2AwgsyrVfB11F9lJvXznN/bwdicecfjAS+Q= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=JzXbfa/mpewAIZNTdsRet1eOCUFT+GoezAer5VbBH7I=; b=r+SA/9e7nCRiLSoP46UIOQx2P1KW5im/WkPj1n+0ZtQ3zg2A1JdxYHg9UbLkLGzNrD mFeHcqyzmM0n59pRkAU+CH71ZCO/RKCxmgH1SxgDLKk7P0s6T8pIv/Vb5N75jZtmhHTf uBBtGLxPB6w35f2FTIFuKIVTGpivmVsBCJEs03DU7OcJ1wTkBUkDlTQAsdbhS2La0ndP +YThy4BSVjgEZBOlOwVecvrT3dtK+WyBoVh2oSJkT00FEcKrsQO5cjS15p0gZPJltkX0 /2IFY78lMTo5hTcs+m5joStQslXy6AeQ49sqyvl5Yo3YvYx+tnPEN/v3kuOs2xetJG/b xdzw== X-Gm-Message-State: AHQUAuYgZjv5InzJZBVOOXLMG/pZ+xHOJi9EkkOkUMSqDTcv1wGAPTNC thJZ905T7pXjuL39R6J8zBe7+WR8sOV/zw== X-Google-Smtp-Source: AHgI3IZBac1FTYyZxys9grNLjySM+wF+u/PKaYan5t9W98sBbxl0vo3tyM5GLxsgLdCyngpeRPyClQ== X-Received: by 2002:a1c:d14d:: with SMTP id i74mr2912787wmg.100.1549037248467; Fri, 01 Feb 2019 08:07:28 -0800 (PST) From: Peter Maydell <peter.maydell@linaro.org> To: qemu-devel@nongnu.org Date: Fri, 1 Feb 2019 16:06:31 +0000 Message-Id: <20190201160653.13829-26-peter.maydell@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190201160653.13829-1-peter.maydell@linaro.org> References: <20190201160653.13829-1-peter.maydell@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::32c Subject: [Qemu-devel] [PULL 25/47] target/arm/translate-a64: Don't underdecode system instructions X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: <qemu-devel.nongnu.org> List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe> List-Archive: <http://lists.nongnu.org/archive/html/qemu-devel/> List-Post: <mailto:qemu-devel@nongnu.org> List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" <qemu-devel-bounces+importer=patchew.org@nongnu.org> X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" The "system instructions" and "system register move" subcategories of "branches, exception generating and system instructions" for A64 only apply if bits [23:22] are zero; other values are currently unallocated. Correctly UNDEF these unallocated encodings. Reported-by: Laurent Desnogues <laurent.desnogues@gmail.com> Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Laurent Desnogues <laurent.desnogues@gmail.com> Message-id: 20190125182626.9221-2-peter.maydell@linaro.org --- target/arm/translate-a64.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/target/arm/translate-a64.c b/target/arm/translate-a64.c index 4d28a27c3bd..e6df303e321 100644 --- a/target/arm/translate-a64.c +++ b/target/arm/translate-a64.c @@ -2144,7 +2144,11 @@ static void disas_b_exc_sys(DisasContext *s, uint32_= t insn) break; case 0x6a: /* Exception generation / System */ if (insn & (1 << 24)) { - disas_system(s, insn); + if (extract32(insn, 22, 2) =3D=3D 0) { + disas_system(s, insn); + } else { + unallocated_encoding(s); + } } else { disas_exc(s, insn); } --=20 2.20.1