From nobody Fri Nov 14 19:42:46 2025 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1761774627; cv=none; d=zohomail.com; s=zohoarc; b=Xy0Fz8Aqyp1sVVtMkQOGDlMFwWLEj2FR+JBxIT0XavMHj6t/WLRsEEcQvCVtxpQFNxx10xvGPoyu5OuDa1qyh2BxDPynMHWOVDbANi0mto6CK9oM90dsAmu73xls/mPXZegmGHkU4ZMumV/mqznBt1WsyXwr2SVQa0aKtpY8pT4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1761774627; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=feo8FQEGOqzAXoyKXsNivpWnArCzPABZfbbNYQk863w=; b=ezD55kcoZOwYSSIlDFEd01f4Hhz9rE6NeGv7dD99seyE2stPtCKuucL9LisOHnsevB/+x6zQ6fJjTY2PKFF88y6jX4rkogM0Oy9u9ec5kpiCZz844wPFCIVo1HeZ6rl98VA4ETFIERB7zpP2Q74n+mUjVdXiCrDDRe8Fx1frkX0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1761774627215523.4458438497869; Wed, 29 Oct 2025 14:50:27 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1vEE3C-0004NN-6u; Wed, 29 Oct 2025 17:49:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1vEE33-0004Ke-5Z for qemu-devel@nongnu.org; Wed, 29 Oct 2025 17:49:41 -0400 Received: from mail-wm1-x329.google.com ([2a00:1450:4864:20::329]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1vEE2t-00079B-7G for qemu-devel@nongnu.org; Wed, 29 Oct 2025 17:49:40 -0400 Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-475c9881821so10021275e9.0 for ; Wed, 29 Oct 2025 14:49:25 -0700 (PDT) Received: from localhost.localdomain (88-187-86-199.subs.proxad.net. [88.187.86.199]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-429952de971sm27977643f8f.39.2025.10.29.14.49.20 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Wed, 29 Oct 2025 14:49:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1761774561; x=1762379361; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=feo8FQEGOqzAXoyKXsNivpWnArCzPABZfbbNYQk863w=; b=byQmvuuLfQ8GP5CNcW964E3ax3bJMxGY365lNcKumH+w7T9iXD7jo1J5p3z7KxFfUo woNbbhCc+BLwR16V4bcbsg90K2GJgJ59g4nJ+eG/wtg0BXGvLfO3nN8brO73Sa+4Gwp4 phpj4ccI28vHNzIlPzKyxCi+zRxQwDCizqX01cVZT0byMEF+FfSrye1gwvWvfv/nUcG1 tnvvSXjtXuZqgMviC9AlWEGZskpN3rykjk8Sxb0BNsP/SmTFloUm1w/0oFlEqFd37SaN 5MtXvSsHrwlRWUiwlGXqEE8R9R5NHnlujwOEDamMk/wDun5v/PfERPdI++TEvHGq/3Ae oBag== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1761774561; x=1762379361; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=feo8FQEGOqzAXoyKXsNivpWnArCzPABZfbbNYQk863w=; b=qDFTljGRWWBz4Sm7J4HLCQ3L4/sO+NLEISffwS3ZcSkrwiawiV+YczgtYeuq1r9cx2 evOyn39D9ySOC0B0b0r2o6heyyyk14GzfLhtHO+DMR2ZvRdR60Qz74KBETV+agCXgKbM R7F7z1SYaKsORSdogCVFY6lgoufIMOV/lnRzzJH4St8nuFODHZKvqnIXVd0tgaNCQeUT gvB6rH1vSPb/4hrPV/uY3qpNucg+s8vs03jBGSA+47PfJ/XUB9Oe1pq4rLT2yRdUF28q 1NtEi/MirIJ+qqA8dqGwJZDkdGqUADUCTch8jCkr9mhI5tfegoWn8l55FWPkc0i/hklj hAEg== X-Gm-Message-State: AOJu0YwEseFPHqDi5ayoV23oCF9JjMTNPUiREZAedII8rC7cg4DCOx7D xbgZrRmXwXCLuuyGHA6HfTPv6dkn5LKzrUcvpWq6sR01MNKSEwYpAWskhY43EswW3m8/zU/uCyU 1/vzWH8Q= X-Gm-Gg: ASbGncvzQg3CdqD/97UwPfOgowOy5QdA1WwPEElcZ/WXp2z81bzPzP0zvo5j4cYhMqg 7ELLtJCyhGJVekGLQcqoaRuue1m2lwIdNKaN4a3JvckD2d9RibcUJ66BqE5oEmBCN5xEkvUFKBj tTxog3pBusICYiPNnucK+N8Y9yZWXK6fUZfXS1Xhbn5+rwp14B9nztJfVhKeENzNPrFj6lUV4Wd vjaml1b9OZsUEarpyOXGCXGT4lJyt3S1D31nyMJIalcwpV+O1Kx0i1bP/pEPPH//JI3xf7Us+32 m3wKfJinAI4H4hnfxcZfDTQuMuVJuPEmxUnjid2hS0nUyFzRO5G6o4F22l8+O2ICp7H4rCs0ltI So26xKLe6droqwTPUgXNApfvI6OfhCiQkLYRPOebCBOel5Pd1QT0U3B8vfgAvA1elbTFyiYLDPO 8sFB5kn+W7cveNzd/huX+saNgGJi0Ech8jKMIlIzBRiHUzt+naXw== X-Google-Smtp-Source: AGHT+IF+4/nFuvC4cJuytWiWe+H7AZ4+Eyp1KQg0BMmif9wXeFHWWHlo/AvfI0PJ99gtsbJeXZhSfA== X-Received: by 2002:a05:600c:a4b:b0:46e:6339:79c5 with SMTP id 5b1f17b1804b1-4772626120dmr12343685e9.5.1761774560927; Wed, 29 Oct 2025 14:49:20 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: qemu-arm@nongnu.org Subject: [PULL 09/23] qemu/target_info: Add target_arm() helper Date: Wed, 29 Oct 2025 22:39:46 +0100 Message-ID: <20251029214001.99824-10-philmd@linaro.org> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20251029214001.99824-1-philmd@linaro.org> References: <20251029214001.99824-1-philmd@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.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; Received-SPF: pass client-ip=2a00:1450:4864:20::329; envelope-from=philmd@linaro.org; helo=mail-wm1-x329.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, T_SPF_HELO_TEMPERROR=0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1761774631177158500 Add a helper to distinct whether the binary is targetting ARM (32-bit only) or not. Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Pierrick Bouvier Acked-by: Peter Maydell Message-Id: <20251021210144.58108-1-philmd@linaro.org> --- include/qemu/target-info.h | 7 +++++++ target-info.c | 5 +++++ 2 files changed, 12 insertions(+) diff --git a/include/qemu/target-info.h b/include/qemu/target-info.h index abcf25db6fa..984fba3f42d 100644 --- a/include/qemu/target-info.h +++ b/include/qemu/target-info.h @@ -50,4 +50,11 @@ const char *target_cpu_type(void); */ bool target_big_endian(void); =20 +/** + * target_arm: + * + * Returns whether the target architecture is ARM (32-bit, not Aarch64). + */ +bool target_arm(void); + #endif diff --git a/target-info.c b/target-info.c index 3110ab32f75..40716bf4051 100644 --- a/target-info.c +++ b/target-info.c @@ -52,3 +52,8 @@ bool target_big_endian(void) { return target_endian_mode() =3D=3D ENDIAN_MODE_BIG; } + +bool target_arm(void) +{ + return target_arch() =3D=3D SYS_EMU_TARGET_ARM; +} --=20 2.51.0