From nobody Tue Feb 10 03:40:10 2026 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 ARC-Seal: i=1; a=rsa-sha256; t=1558607830; cv=none; d=zoho.com; s=zohoarc; b=XulIM4YjwYd9OcKZXBKx9JD4vVCB+p+1Vt3tnXp19CZkMQ5yUnqLEM8M+pepi21xbADmh3XeKnX2yyhKjLjvLGRyTMwVfUUbe9s+QfXx66swYL4UPS8ojvFDbILkPfPK2dzXU45NVxsk4kDS5gP7HFvIP6Li2naKfaI3SgChPlM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1558607830; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=CBMu5m7eSFgVxsne/XtTOzzcwofGf1J0u9oREYxWAFw=; b=XG3emMMgWqvcnqEVO4Iuq1AyVl4+jiosxGAUtgXndsfgyWMaeiOV332xbVwjzgRycoI2e39Dw8A/ta4lKmC4co0rxHCYv8y5pKwkVIYQDX1CZMxCTxYStZge/nMQz+0Zaocu7ahnQ1tLwwtRWTVbiXkJp7E8OT/tnfcPpI539ok= ARC-Authentication-Results: i=1; mx.zoho.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 header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1558607830357724.271338967121; Thu, 23 May 2019 03:37:10 -0700 (PDT) Received: from localhost ([127.0.0.1]:33221 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hTl5r-0006Zc-F7 for importer@patchew.org; Thu, 23 May 2019 06:37:03 -0400 Received: from eggs.gnu.org ([209.51.188.92]:49225) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hTkv4-0005YS-8B for qemu-devel@nongnu.org; Thu, 23 May 2019 06:25:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hTkv0-000185-9P for qemu-devel@nongnu.org; Thu, 23 May 2019 06:25:52 -0400 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]:34867) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hTkv0-0000xP-1o for qemu-devel@nongnu.org; Thu, 23 May 2019 06:25:50 -0400 Received: by mail-wm1-x344.google.com with SMTP id q15so5201896wmj.0 for ; Thu, 23 May 2019 03:25:41 -0700 (PDT) Received: from zen.linaroharston ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id b136sm9875486wmg.1.2019.05.23.03.25.34 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 23 May 2019 03:25:35 -0700 (PDT) Received: from zen.linaroharston. (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 4A35B1FF98; Thu, 23 May 2019 11:25:33 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=CBMu5m7eSFgVxsne/XtTOzzcwofGf1J0u9oREYxWAFw=; b=tUUnghut34aXiftRyh3GqNtRNX+FS1aOhZG4Mo5g42SKs/CO4JYGGcgYJRoxkXIDLI MJKshVJX7GJn8XhJ3DJhZuiqLICyuQHgHFnSoX2kjRKScGgnLoxanecFRfRmrftmUMf4 0AldmnfYeLmwrutxcwHPNSCkJkLe4QPq9cx8xdNDfsM8KxuzkEHg72LJVh6CGRU6EfbE GwDbxuIbb3I7tnmal1fdvPCjUn82dhtoV75dcAaw3IHFBE8mOr24FHK0KuyqImO5xcco uh9ZYCvDsknN3w1SzpPy9btYbt4LHd4x2qg+6NvZ1kdYOe5UIqvwRHpJs37rTQsUrBMz 2NuA== 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:mime-version:content-transfer-encoding; bh=CBMu5m7eSFgVxsne/XtTOzzcwofGf1J0u9oREYxWAFw=; b=QwZXUXpO6OGNjzhEZYGquxbgDnmCu64WvrIES6Ivd22qpsGULPeyYXnDtLLl+kWGf9 EteQYPlcJ9nByJl7S/7bPWNE3OYCbYOVC06QHeNk2mZf6hKmfa89wPYdYzFX8UqkSXdi FXnIBK0N/Yym10ATLVTd2bw/ufWvD0PmZlSxwvaw3KRPMab1/5fPxt0Zu4UZXziW+lIW 6n7QqyUAOiSz813/1hfUrXGPNUbJilSY5jjd5Yf2eHim+Us8wBnJBj+BBvtLkG+CaQ+Y jS7BoRyschaTZh79rmUVpgpdEFYAU5wIp2xbcMIgqY3772AMLtWL32Z4w2jfnq555HI8 bMiQ== X-Gm-Message-State: APjAAAU59net5/iJ5ZpkVEXI4whRXoU1QMYuwQKqOxAaDUWAj+uRrf3Y Ytg8qBK/nsRz/uBEglQaUqM6hw== X-Google-Smtp-Source: APXvYqxdunaT1ZXFV+IxbwCCvnOFfs41efizffc64GJAFN3ykJH4ii6kKtHxGHLvkfiRB8ZbIIFdQQ== X-Received: by 2002:a1c:688a:: with SMTP id d132mr2610625wmc.131.1558607140945; Thu, 23 May 2019 03:25:40 -0700 (PDT) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Date: Thu, 23 May 2019 11:25:13 +0100 Message-Id: <20190523102532.10486-10-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190523102532.10486-1-alex.bennee@linaro.org> References: <20190523102532.10486-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" 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::344 Subject: [Qemu-devel] [PATCH v2 09/28] target/mips: only build mips-semi for softmmu 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: Aleksandar Rikalo , =?UTF-8?q?Alex=20Benn=C3=A9e?= , qemu-arm@nongnu.org, Aleksandar Markovic , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Aurelien Jarno Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) The is_uhi gates all semihosting calls and always returns false for CONFIG_USER_ONLY builds. There is no reason to build and link mips-semi for these builds so lets fix that. Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Aleksandar Markovic Reviewed-by: Richard Henderson --- target/mips/Makefile.objs | 3 ++- target/mips/helper.h | 2 ++ target/mips/translate.c | 8 ++++++++ 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/target/mips/Makefile.objs b/target/mips/Makefile.objs index 651f36f5176..3448ad5e193 100644 --- a/target/mips/Makefile.objs +++ b/target/mips/Makefile.objs @@ -1,4 +1,5 @@ obj-y +=3D translate.o dsp_helper.o op_helper.o lmi_helper.o helper.o cpu.o -obj-y +=3D gdbstub.o msa_helper.o mips-semi.o +obj-y +=3D gdbstub.o msa_helper.o +obj-$(CONFIG_SOFTMMU) +=3D mips-semi.o obj-$(CONFIG_SOFTMMU) +=3D machine.o cp0_timer.o obj-$(CONFIG_KVM) +=3D kvm.o diff --git a/target/mips/helper.h b/target/mips/helper.h index a6d687e3405..90ab03b76e3 100644 --- a/target/mips/helper.h +++ b/target/mips/helper.h @@ -2,7 +2,9 @@ DEF_HELPER_3(raise_exception_err, noreturn, env, i32, int) DEF_HELPER_2(raise_exception, noreturn, env, i32) DEF_HELPER_1(raise_exception_debug, noreturn, env) =20 +#ifndef CONFIG_USER_ONLY DEF_HELPER_1(do_semihosting, void, env) +#endif =20 #ifdef TARGET_MIPS64 DEF_HELPER_4(sdl, void, env, tl, tl, int) diff --git a/target/mips/translate.c b/target/mips/translate.c index 3cd5b11b16b..fb905c88b57 100644 --- a/target/mips/translate.c +++ b/target/mips/translate.c @@ -13726,6 +13726,14 @@ static inline bool is_uhi(int sdbbp_code) #endif } =20 +#ifdef CONFIG_USER_ONLY +/* The above should dead-code away any calls to this..*/ +static inline void gen_helper_do_semihosting(void *env) +{ + g_assert_not_reached(); +} +#endif + static int decode_mips16_opc (CPUMIPSState *env, DisasContext *ctx) { int rx, ry; --=20 2.20.1