From nobody Sun Feb 8 12:38:52 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.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 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=gmail.com Return-Path: Received: from lists.gnu.org (208.118.235.17 [208.118.235.17]) by mx.zohomail.com with SMTPS id 1534441748308802.2238393736549; Thu, 16 Aug 2018 10:49:08 -0700 (PDT) Received: from localhost ([::1]:57470 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fqMOK-0000FV-0E for importer@patchew.org; Thu, 16 Aug 2018 13:49:00 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53079) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fqMMT-0007kM-32 for qemu-devel@nongnu.org; Thu, 16 Aug 2018 13:47:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fqMMS-000678-FG for qemu-devel@nongnu.org; Thu, 16 Aug 2018 13:47:05 -0400 Received: from mail-lf1-x142.google.com ([2a00:1450:4864:20::142]:33092) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fqMMS-00066m-6N; Thu, 16 Aug 2018 13:47:04 -0400 Received: by mail-lf1-x142.google.com with SMTP id u14-v6so4039851lfu.0; Thu, 16 Aug 2018 10:47:04 -0700 (PDT) Received: from octofox.cadence.com (jcmvbkbc-1-pt.tunnel.tserv24.sto1.ipv6.he.net. [2001:470:27:1fa::2]) by smtp.gmail.com with ESMTPSA id q65-v6sm5206268lfb.80.2018.08.16.10.47.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 16 Aug 2018 10:47:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=A17x4c2H8FbLrEL0Fq8AJTxVIV1BnmtFmk176WoD9ko=; b=PPU9bgjOYl1mU2/w61nnWY4+2Chf9zn0V7jfNX05nrslmF375taAuxwl5UFq89J0di JyD6Ew1GNRHqjNeRJ8sZ5KPZrPPnLe4AMSv5obFK5mA8yEoLsdqD5JPYCdF4JSSzZBa1 P0yi78JBN1ulqf1R+cJJGJU66es9tPsrNCTBoahRWfMsYfU0SgvWfA+4HF4u98oK0k2V ETBWlcnKWXFVCRfoZZVajMB7/RXYIsB814rPDIOV0/XuPOvMiba02vHibGx00U4Xfcoy E9tlXQYlCpoADBISfVhwfpCNnFUB+QIqY3SyFP/65LOed9h3O93M7ih6pqg9OPN8trZ3 arNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=A17x4c2H8FbLrEL0Fq8AJTxVIV1BnmtFmk176WoD9ko=; b=Bo3IGUtImgCMbsaKYgY5s2GsMT/OF2cOPzMw/+HR81HVPxRj115FWhqAGazpS/irhY 1qNA68xBR3r2prOsL8bARyRh8WbNlc32jGSz2tH1sTCShA9DHxPdqFhK35/pkTqE56gG DSHDLmVdH9Z1hfbAuKW+CSRgR9tfX9xpi/qcAYjM0hyM6R5htAlPQYUAdqT1WrRv+xrW 69Sm5Fc+9uVwDKxSho1kW39CED2VXUmCLzZ3DIekOBtjMcLCwlAGxRsnfeDNUVFvHUt+ DBpDFMC3wDtSKcUIrPaK7/zjKHUAU0H4ONSb91DuQ8YLrROoP1DR9t6TP6AaOsvvQ31E 124g== X-Gm-Message-State: AOUpUlFEaYU2AD8l+OreVTEW4z+ZNtavgnqKzBhfNRzZmufTAIduIw3x ST0xUUvMfAsDVswSgnt4Gfy32S3d X-Google-Smtp-Source: AA+uWPwR9rWQRgifexFHPvStAmM7DDhYgFSJsth3vIqh7fQUvxR8+PLKlBaEh8UhDv1Aa1U3U5LscA== X-Received: by 2002:a19:548e:: with SMTP id b14-v6mr19405966lfl.10.1534441622762; Thu, 16 Aug 2018 10:47:02 -0700 (PDT) From: Max Filippov To: qemu-devel@nongnu.org Date: Thu, 16 Aug 2018 10:46:44 -0700 Message-Id: <20180816174645.30364-2-jcmvbkbc@gmail.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180816174645.30364-1-jcmvbkbc@gmail.com> References: <20180816174645.30364-1-jcmvbkbc@gmail.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::142 Subject: [Qemu-devel] [PATCH 1/2] target/xtensa: fix gdbstub register counts X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Max Filippov , qemu-stable@nongnu.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDMRC_1 RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" This fixes communication with gdb in the presence of type-5 (TIE state mapped on user registers) and type-7 (special case of masked registers) registers in the xtensa core config. Cc: qemu-stable@nongnu.org Signed-off-by: Max Filippov --- target/xtensa/helper.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/target/xtensa/helper.c b/target/xtensa/helper.c index c9a613270036..efb3cef12813 100644 --- a/target/xtensa/helper.c +++ b/target/xtensa/helper.c @@ -100,7 +100,9 @@ void xtensa_finalize_config(XtensaConfig *config) unsigned n_core_regs =3D 0; =20 for (i =3D 0; config->gdb_regmap.reg[i].targno >=3D 0; ++i) { - if (config->gdb_regmap.reg[i].type !=3D 6) { + if (config->gdb_regmap.reg[i].type !=3D 5 && + config->gdb_regmap.reg[i].type !=3D 6 && + config->gdb_regmap.reg[i].type !=3D 7) { ++n_regs; if ((config->gdb_regmap.reg[i].flags & 0x1) =3D=3D 0) { ++n_core_regs; --=20 2.11.0