From patchwork Fri Jul 5 16:04:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 168561 Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp3763888ilk; Fri, 5 Jul 2019 09:14:34 -0700 (PDT) X-Google-Smtp-Source: APXvYqz2TeCw3ytIdyPy68WlcfEBs+1Q86HSImAmjjgSnS8//mkUBbAVfSbfN0yW8c/ssVFFcisB X-Received: by 2002:a17:906:3018:: with SMTP id 24mr4439691ejz.187.1562343274332; Fri, 05 Jul 2019 09:14:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562343274; cv=none; d=google.com; s=arc-20160816; b=qz7sQGjxwqEpXyVg3irWzG3DUXgj8Z7bK9btYxm9O3dYwWxqIW/U9yTyMB6AF/sjiR xTcHH8GwvgIW8BiuhjsmVV0zPwuWjstEqRBAmAEBNbKZHEFuinOkSRHDwnwXvQlibnmZ yORCzQbR1NgaoUrbHevqFPf+PkSBc6TLMWQGXoTpJzbCzssYaxRnQDFdnqu8y0jOnWfi +E8CtRH/mO5xkqE2nVnNRKckY2iPuNi0HrbCOjUpixJK4JdXZ9XLPOMadijGJtv4ki5s ooUqjyw8VTtCW6UplgPL515YcOx9ghL1bRsNbYjvZKnmZ71Plc9I8YLwikiFnW/O+f1r CZ4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=mM1Kb6A1N3/Dz5Nk0cJ9QkDDg49iumbs9t4kZbIKPkI=; b=kQiNqxFc5VWaPe9gAl4Mz/59/T8UpCmOo0AsCWE+Cy+WoxNMG6QQEeFTxF9K7bXrl4 RsKC7N8vu78/A5zLLakKaYXsFwmtBp8/O8MLAjKhaJXg7Dlp8fOo5u1sSOHRVK9sdydN R1XFP3V9smLry0kXkaAV9odfSoxy1ZSVXmjah/75DZGXoFzXOOi/XB5cIo+0BxpBRzpx qjpOXGLiTwvfDydrsJsrW9tm1UzoJzR8nQBpYMgz7QR5LIV4GzhhwLAAHiqlIjV3Grcm 5ddfkGtKOYdk2E+Qar/pahYoEb0fMA+TVI4QqLvNQmMbPVdLprRnbzJdsG4xs/pZNVyL GRtw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=B+tqP9I2; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id b42si7468417ede.365.2019.07.05.09.14.34 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 05 Jul 2019 09:14:34 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=B+tqP9I2; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:54680 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQr3-0005e2-2n for patch@linaro.org; Fri, 05 Jul 2019 12:14:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40371) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQhf-0002yf-Jy for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:52 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hjQhc-0001ze-K2 for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:50 -0400 Received: from mail-wm1-x32e.google.com ([2a00:1450:4864:20::32e]:36541) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hjQhb-0000Mx-Ch for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:48 -0400 Received: by mail-wm1-x32e.google.com with SMTP id g67so3973719wme.1 for ; Fri, 05 Jul 2019 09:04:23 -0700 (PDT) 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=mM1Kb6A1N3/Dz5Nk0cJ9QkDDg49iumbs9t4kZbIKPkI=; b=B+tqP9I2K5+Tn0q1xTHuNqxtvalMjBwgpRBufaF3SfhdXrnTb/pgmhQfNXP9lh8WML gzqDf3amfLMEWDOVNb5FvaTjtUIrXZQ3n8dBzn0xeHzjZywuHImPLALClJckQ2+YE+bq LBC9f8G4Cj2Uq22ODM/ZuH3ZeT2S2bql1id06uLDZjbS3G8BsGcDZiPjiZjULUJHyxL5 /HczLHViXPhnCv5gHEfNNhNW0v8H6sn8FjVA48ad0fLtq/MsYh5hsTe53RvKEPmkzPTR JVGKPCcWW79QVCNqO4nkkJWZfXkYUHTDJ3RJ7i3wgwSnP5Bpq7eYdHrHleiBkIvbCish a8Ug== 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=mM1Kb6A1N3/Dz5Nk0cJ9QkDDg49iumbs9t4kZbIKPkI=; b=h9dPruawaiaT9kIvyd5tSRC+5y+fhyjEkMLWvHKy3LFLx44xCLIlxp0uGY62/uzN6Z SqUS551QkhAG1oxLiXBfwWRZkd9GBhkHE9F7Hd+u78do1CJBxwt8ON7DO+qz+hlrr4r/ MS8+hTnMGlX7enNy+4n8VnC2p/FkSpRYY3x8HjrY0kU9HhE+DkqOhKPPN82PYbaUbxTZ MoVnxyFCloJOSTVxfbEAq8mVA4RKuibcRZIFWdM6L9BlZRIkFQXlJb4Ls5A382gLcda0 GqA5MXY025MCGhPmasf7Ot/mp9b6i5Q9MqZj6kvVWrUQF2s9iyMpEjdobThFUTQnD1PV SC+Q== X-Gm-Message-State: APjAAAUpQv3Q/ciWL7CQrTEC2Mb4VHNWcz9FDNCqUS83fwHyeB70sg7E YCrT7xWtahyJPi2uziGYNmqSww== X-Received: by 2002:a7b:c195:: with SMTP id y21mr407119wmi.16.1562342662844; Fri, 05 Jul 2019 09:04:22 -0700 (PDT) Received: from zen.linaroharston ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id d9sm13335593wrb.71.2019.07.05.09.04.21 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Fri, 05 Jul 2019 09:04:22 -0700 (PDT) Received: from zen.linaroharston. (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 8C7421FF8C; Fri, 5 Jul 2019 17:04:21 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Date: Fri, 5 Jul 2019 17:04:17 +0100 Message-Id: <20190705160421.19015-2-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190705160421.19015-1-alex.bennee@linaro.org> References: <20190705160421.19015-1-alex.bennee@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::32e Subject: [Qemu-devel] [PATCH v1 1/5] target/arm/vfp_helper: Call set_fpscr_to_host before updating FPSCR reg X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Laurent Desnogues , =?utf-8?q?Alex_Benn?= =?utf-8?b?w6ll?= , qemu-arm@nongnu.org, =?utf-8?q?Philippe_Math?= =?utf-8?q?ieu-Daud=C3=A9?= , Peter Maydell Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Philippe Mathieu-Daudé In commit e9d652824b0 we extracted the vfp_set_fpscr_to_host() function but failed at calling it in the correct place, we call it after xregs[ARM_VFP_FPSCR] is modified. Fix by calling this function before we update FPSCR. Reported-by: Laurent Desnogues Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Laurent Desnogues Tested-by: Laurent Desnogues Message-Id: <20190705124318.1075-1-philmd@redhat.com> Signed-off-by: Alex Bennée --- target/arm/vfp_helper.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.20.1 diff --git a/target/arm/vfp_helper.c b/target/arm/vfp_helper.c index 46041e3294..9710ef1c3e 100644 --- a/target/arm/vfp_helper.c +++ b/target/arm/vfp_helper.c @@ -197,6 +197,8 @@ void HELPER(vfp_set_fpscr)(CPUARMState *env, uint32_t val) val &= 0xf7c0009f; } + vfp_set_fpscr_to_host(env, val); + /* * We don't implement trapped exception handling, so the * trap enable bits, IDE|IXE|UFE|OFE|DZE|IOE are all RAZ/WI (not RES0!) @@ -217,8 +219,6 @@ void HELPER(vfp_set_fpscr)(CPUARMState *env, uint32_t val) env->vfp.qc[1] = 0; env->vfp.qc[2] = 0; env->vfp.qc[3] = 0; - - vfp_set_fpscr_to_host(env, val); } void vfp_set_fpscr(CPUARMState *env, uint32_t val) From patchwork Fri Jul 5 16:04:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 168562 Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp3764038ilk; Fri, 5 Jul 2019 09:14:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqwbm2ne8DV6bxTSTq9zpH7YSY4q995NRPKdJV4VKww75rlnt8zUNSlysOuljQHmsX6tbcwc X-Received: by 2002:a50:89a6:: with SMTP id g35mr5604789edg.145.1562343285209; Fri, 05 Jul 2019 09:14:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562343285; cv=none; d=google.com; s=arc-20160816; b=a/dVbSeb8fIckFfNiQSp9qybyBfV+xNiZ3rTuJb9hepte/4qgM2SFtbdAh+wDpM1gc RaaaSzIuETl4xQPPKNcUIdzn1T0aGgkBa+jYPCGj3MrcaMSos+cyz52ldEhxfR/Xqth/ pmrYxuClHL4QZ2wDNCfFzSOR7sNnRtVyKBv/Lwubll1SDV/QZAkntoP03sTYMiSVp1FI YyaEbh4xGnt4o6QWM+7WbI7JHOsXgw64l7X8PRsAjT9f5jpX0dMMTClh1HI76fo0lAls LVoY9+dZDmDc8ijd3OxPjDukcBHzjcuHF4r5NreIKRL8TnJEsqNumupMpUnkBG14QS01 pysQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=pnvxSKN5dF6BFileI9vCwcNPxM0MUq6YBqg0MnEs6Us=; b=FDLo2KL8+bAY3al8L8vX2piZNz3zqB99ocNsKpiBg399Z1nRH6LrLyNg3LsPD5uEmD QUdqd90SBJ3PU5+RccT72GKQ3ygHZleXj9QjSvcFSgNtrraiQMkXDzMiFs9Iex9S7CkI p8BV4maDrEvw2MRFdsGzkOd3H6ny1I4IDFSaFBp12Hrc3DS8dbVQ/eswagyZYJavgubb F2/KzJTumXxnGz+jRhFEhWDcs3Fu5vqG+mZiVqOEzXI/YzG0HAXbYNajJx5Z3RKm0LA9 uIyNI8sZb5xvQcLmE8ZrVUbGaUmMXyBo++mY9ojZP+bb8d3jYrGg12+5jNQN61C3q+0H xqxA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=wxvvzLI3; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id f46si7594413ede.78.2019.07.05.09.14.44 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 05 Jul 2019 09:14:45 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=wxvvzLI3; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:54688 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQrE-0005rw-6v for patch@linaro.org; Fri, 05 Jul 2019 12:14:44 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40430) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQhi-00034A-35 for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hjQhg-0002Im-Rr for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:53 -0400 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]:44550) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hjQhg-0000Qk-Ii for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:52 -0400 Received: by mail-wr1-x442.google.com with SMTP id b2so9214066wrx.11 for ; Fri, 05 Jul 2019 09:04:24 -0700 (PDT) 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=pnvxSKN5dF6BFileI9vCwcNPxM0MUq6YBqg0MnEs6Us=; b=wxvvzLI3pUyLFfRu4W8fnfvua8x4klS/NKHe8jRWR31kuqfg2IJeaGiC8S54hKVZZB hadE+mlk9PaZIrRtjrtIYqf8c8xHylMDOSmrf28HMNKhKrbVVG5b8tpQ/S0mXGJwq36m NyyiyenTL6o0BL8poTqxi0dWeOXnoY03k0Sw5KDlpwGBCb4AKPLaKlaSggbk+jo9HDmo 6WNH26IPsT8gP9I1V7QWHZ4ihuFP3xwHwsFx0nu1klugcYiSuocHdzbj4OLB6AI3EbxS 8QV+BBXs6hsQXo6mxlUncumhCu2dsSX2MywhUB3FSMkW9B9uZYjvOfWaaTKkFt4eo8BI lQWg== 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=pnvxSKN5dF6BFileI9vCwcNPxM0MUq6YBqg0MnEs6Us=; b=AriaxK6u4dBRMEbi7WEvrrJxutZgB6qJNwP2exo+t1XuzhQBPfk67crVp9sOKtZ27S 2XJFoFF8RfFaSy2Y9YbGlNlq3xM+kQ4QTy6m9R5AbCI2G22m31booqYUJoE4m9fIur61 OvDQqiIKvOvX2QCRFdDokHmaW5a1lPOphe43A7NlydkL0YHE04F3UuMtDpdTlcOetaoK TEK7SwNUG7UcYCC8PYzAYr4U9pCNjfebT+HLvIkZ8idy0DY/MgmMoELvlSvjDEMq6kvG 00QGgjFpDVpEBnOUjcidK0ouSrYx1AxF+zKwCYrmvGzFbsTa3aFzhvZMAZDxwiEUv0uI J5JA== X-Gm-Message-State: APjAAAUxBH7yxGTzfi1FW0woAmmwMLPeEfaO1QmRad0zqDx1lq8GfxLX zJlq+SVemzLLQI4z+SZXGGm3PQ== X-Received: by 2002:a5d:6089:: with SMTP id w9mr4796366wrt.166.1562342663656; Fri, 05 Jul 2019 09:04:23 -0700 (PDT) Received: from zen.linaroharston ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id j189sm8758466wmb.48.2019.07.05.09.04.21 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Fri, 05 Jul 2019 09:04:22 -0700 (PDT) Received: from zen.linaroharston. (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id A10841FF8F; Fri, 5 Jul 2019 17:04:21 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Date: Fri, 5 Jul 2019 17:04:18 +0100 Message-Id: <20190705160421.19015-3-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190705160421.19015-1-alex.bennee@linaro.org> References: <20190705160421.19015-1-alex.bennee@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::442 Subject: [Qemu-devel] [PATCH v1 2/5] tests/tcg: fix up test-i386-fprem.ref generation X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Eduardo Habkost , qemu-arm@nongnu.org, Jan Bobek , Paolo Bonzini , =?utf-8?q?Alex_Benn=C3=A9e?= , Richard Henderson Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" We never shipped the reference data in the source tree because it was quite big (64M). As a result the only option is to generate it locally. Although we have a rule to generate the reference file we missed the dependency and location changes, probably because it is only run for SLOW test runs. The test still fails with mostly incorrect flags and different than expected NaNs. I'll leave that for the x86 experts to look at. Signed-off-by: Alex Bennée Cc: Paolo Bonzini Cc: Richard Henderson Cc: Eduardo Habkost Cc: Jan Bobek --- tests/tcg/i386/Makefile.target | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.20.1 Reviewed-by: Richard Henderson diff --git a/tests/tcg/i386/Makefile.target b/tests/tcg/i386/Makefile.target index b4033ba3d1..d0eb7023e5 100644 --- a/tests/tcg/i386/Makefile.target +++ b/tests/tcg/i386/Makefile.target @@ -35,9 +35,9 @@ test-i386-fprem.ref: test-i386-fprem $(call quiet-command, ./$< > $@,"GENREF","generating $@") run-test-i386-fprem: TIMEOUT=60 -run-test-i386-fprem: test-i386-fprem +run-test-i386-fprem: test-i386-fprem test-i386-fprem.ref $(call run-test,test-i386-fprem, $(QEMU) $<,"$< on $(TARGET_NAME)") - $(call diff-out,test-i386-fprem, $(I386_SRC)/$<.ref) + $(call diff-out,test-i386-fprem, test-i386-fprem.ref) else run-test-i386-fprem: test-i386-fprem $(call skip-test, $<, "SLOW") From patchwork Fri Jul 5 16:04:19 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 168563 Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp3765392ilk; Fri, 5 Jul 2019 09:16:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqzL6lRHwoJRiAumIeBlx2XQvb2K15TXtLEkOErxhMPYgqIP2ihUjcLRE4+2YA8B78nrUhdO X-Received: by 2002:a17:906:1e85:: with SMTP id e5mr4291986ejj.200.1562343362487; Fri, 05 Jul 2019 09:16:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562343362; cv=none; d=google.com; s=arc-20160816; b=tDRwalD4aylyeS3brQ8BioSXBtD1IwQ0R/e7lFrB0yJRA/lH7+L+ljJIS0KKpyg8DZ VB6BYPRlujBTW2N/NgY9Q+5ad4n6pXdh7Wz/6FjBhujge7QDQ9CQ1Rd6z3fwLpkdK0B5 vMbDlZaWC3d7fb6BageHjLCz6Sn/4okB3TvgXAbhqm0EgBjDtJHw2dttyehoWDTGoGz7 rh1POo+JPp5QFJJ5GSxYeNVRiwwiHnXgqltKL212c7NrB4WqSqvFN1CL/f5pTZJTijDb jjjiTFlRt9gpN2nhEixd4PqPCuqXecBPKzs53Wqe9mchbDDZuBcPhkk/PrH8XfGuavLH VdWw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=rcuPIsMvIORKeTdOPCcArgmZ5EQEGenIxSqtwUik0XE=; b=nTQP27scvNFknr0Nd572J184ofs5+WqL8rZ0UFejDmBVIHkW0zp+qKrBuAzT0Sg6gI 1gfguIotWjlTcBQK/9LMBy19rPiPQ6vVNs6LSLK1EBwi5zOCg0IxtxRvocdIIYoqedap giswOgi1/gBEhFjWPrOSmP1zRS3vNlpQsxMyeu0vFAlec/1BNQ5HD3AyDdYNfZEUb+Oy 1uwjGmeHcbjI6cndg7025ujfEJbr4QTt09UOCfP74pg0t4GsBSrgYbkPeJoVVRG3VtSP i7jCUaJWWClwyGG6t+54OBIr5Vg7MWS9xVVEtd4WRNAmcylQdOcaJCCu/uzgkHCL5nG7 KsmQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=jW3QtI5c; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id e54si6848482eda.324.2019.07.05.09.16.02 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 05 Jul 2019 09:16:02 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=jW3QtI5c; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:54698 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQsT-00079V-Eq for patch@linaro.org; Fri, 05 Jul 2019 12:16:01 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40286) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQhc-0002v9-J4 for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hjQha-0001op-9K for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:48 -0400 Received: from mail-wr1-x444.google.com ([2a00:1450:4864:20::444]:33405) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hjQhX-0000Ue-Eh for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:44 -0400 Received: by mail-wr1-x444.google.com with SMTP id n9so10475431wru.0 for ; Fri, 05 Jul 2019 09:04:25 -0700 (PDT) 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=rcuPIsMvIORKeTdOPCcArgmZ5EQEGenIxSqtwUik0XE=; b=jW3QtI5c8Zulhdo28F5UE+/Zatu6U5f4ri7hwx76IrIzPTUZjqR+pGLiUWBWeVNJuy x++NA1t0ukYLSNmQzgy+9MX7rpOleDxIzEOul2339Hu++lMumqcagWJDJ5YHmgfVGNl3 /KrpLHG8ywA3HJvQE2R5NjpS2W+Z916vi6J5IQRVbdwjKYXVhHHJIgNJFsEYHRVdgf5L ceD1awHUq47TKANxJQW05wlaL1lQnNCO98CZ0g/NoSHPpeHHYcpqoHUB830ehs17H855 hRpW0dsCgsMrwCoTlvWcFZUvJWo6xn94651YCGA4hvEktiA0F4EGLIUYaRR+jL6JeBd6 yelQ== 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=rcuPIsMvIORKeTdOPCcArgmZ5EQEGenIxSqtwUik0XE=; b=snthMem2eCMYeP7Y0c7Z6TLb6rgAcpmhAGNRjN6aropo5ijasvccxZvkTDxDghWDpI TKBbk2grlbQjsO7JsxRS3BBsrebYJjGL1v1ayIBtv75SG7trfzFd4dQRm8fwM/1aLutB 7VK+tFmxM6SNLpGoP7vGehdEht2c6771MUYGnXRWl2i9oUSb8/QlwZqXHD9Ukn7gzh7A IICi6VIeQ362/r5lPzqZf0o6kwLLP6TB/+GP6Cchnl881CWfJnfsxSMdhClAzvZz6rOD o9R1Bm1xCLLt2mDfF0ReAcG4VPY2A2J8JEVz9OGgl6doPKtRkqL5Lj7/aUETeWNKvKpZ Rc3w== X-Gm-Message-State: APjAAAXqcD6wRu/bLECdhb0KFKH7oMtZhf5KjzlbFr4+m+k9jVWOIj07 W9M4CYJlpt6+0LAIyiZkIOmulw== X-Received: by 2002:adf:d4cc:: with SMTP id w12mr4835967wrk.121.1562342664880; Fri, 05 Jul 2019 09:04:24 -0700 (PDT) Received: from zen.linaroharston ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id 91sm1900253wrp.3.2019.07.05.09.04.21 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Fri, 05 Jul 2019 09:04:22 -0700 (PDT) Received: from zen.linaroharston. (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id B65081FF90; Fri, 5 Jul 2019 17:04:21 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Date: Fri, 5 Jul 2019 17:04:19 +0100 Message-Id: <20190705160421.19015-4-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190705160421.19015-1-alex.bennee@linaro.org> References: <20190705160421.19015-1-alex.bennee@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::444 Subject: [Qemu-devel] [PATCH v1 3/5] tests/tcg: fix diff-out pass to properly report failure X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: qemu-arm@nongnu.org, =?utf-8?q?Alex_Benn=C3=A9e?= , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" A side effect of piping the output to head is squash the exit status of the diff command. Fix this by only doing the pipe if the diff failed and then ensuring the status is non-zero. Signed-off-by: Alex Bennée --- tests/tcg/Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) -- 2.20.1 diff --git a/tests/tcg/Makefile b/tests/tcg/Makefile index 6fa63cc8d5..7973cd1ba2 100644 --- a/tests/tcg/Makefile +++ b/tests/tcg/Makefile @@ -45,7 +45,11 @@ run-test = $(call quiet-command, timeout $(TIMEOUT) $2,"TEST",$3) endif # $1 = test name, $2 = reference -diff-out = $(call quiet-command, diff -u $1.out $2 | head -n 10,"DIFF","$1.out with $2") +# to work around the pipe squashing the status we only pipe the result if +# we know it failed and then force failure at the end. +diff-out = $(call quiet-command, diff -q $1.out $2 || \ + (diff -u $1.out $2 | head -n 10 && false), \ + "DIFF","$1.out with $2") # $1 = test name, $2 = reason skip-test = @printf " SKIPPED %s on $(TARGET_NAME) because %s\n" $1 $2 From patchwork Fri Jul 5 16:04:20 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 168564 Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp3767244ilk; Fri, 5 Jul 2019 09:17:54 -0700 (PDT) X-Google-Smtp-Source: APXvYqxNu4XRgu5F5ElO5BieOVy17edEeqbBdww/ocrHoQcNsu3h3LlhlgzfthaokTi7v+B776z8 X-Received: by 2002:a17:906:25c5:: with SMTP id n5mr4272218ejb.195.1562343474156; Fri, 05 Jul 2019 09:17:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562343474; cv=none; d=google.com; s=arc-20160816; b=kz/SCGwmfO42kdi3dkV+lMmS3MHEjEqy64NWHbAkkb1Q23ioyD64K90sfJWoPrMSK1 nubHxBahGCOrfstkm8X48jAM6NCWB8+bE6y9zRTPD7tfTDP3BTq0FWG5H4hfMPQ0EeIn DMW5boLsUDEAQV4YX4cLJYr1564209DUimjt2QTfgWO0e1BY4TfpGyIQvXUmcCRDqDGn glePlvZnnV5aElHpLwPpBKR0iw5f3a/v+8xcg98MkBdGxrxpH1NH4VtPrJSaMgONYnlm hPqwwVLkNkSO4tar6eKH2P0Je3Rzyhf1q0IcEaUgefmoArlGicWUtF60merC3vyIJqjh 1a6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=XnuvMB0J1monHDTSCE4AjSSICHHhGGwURpGxrTZnkKs=; b=mII9+Jt0ULxEwbNyhw3G8P3lSfx1QpQk03anvrhHsiXL3BKRd4HTpHIqPKxcTGif6T w7MOwrRd27ARdwdzhAsgh16ADfeywg5euIjHStfwqIrkAu4Nej0EoWZeHSlTy1EaqkDf mf7N69krBdvZqK31vaXT9wmSolg34gOxFdzmx/wnxwg9JSqB7ZGUyCAScIKPoBEMwIiF YjCl+ePOACtptZ35+wBoSPrX5RUYpP5GYwsKbYKd8FVoXf92kxkyIxa4wJLSore1HuXl fkeq75UfaQyaKgAkfpeAc4sfI38aIzb1tUdeTZAmWXjmexMvcOIjR2NZ5+9RCpMnEeJQ U7Sg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=in9QCrzO; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id l43si7313300eda.71.2019.07.05.09.17.53 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 05 Jul 2019 09:17:54 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=in9QCrzO; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:54726 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQuH-0000Ai-2M for patch@linaro.org; Fri, 05 Jul 2019 12:17:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40384) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQhg-00030E-7h for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hjQhe-00028E-Ji for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:52 -0400 Received: from mail-wr1-x441.google.com ([2a00:1450:4864:20::441]:40903) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hjQhc-0000S2-MH for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:50 -0400 Received: by mail-wr1-x441.google.com with SMTP id r1so4119640wrl.7 for ; Fri, 05 Jul 2019 09:04:25 -0700 (PDT) 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=XnuvMB0J1monHDTSCE4AjSSICHHhGGwURpGxrTZnkKs=; b=in9QCrzOgJPCZLxoXL0YJFNU5Q9LDQGhLXn7xLZOmffqHnLi8S2dRRvfPPsDwaSCMS Fv48sKlgedip9fAGFX2DDl69IzOGkBE+0IpBTlWk/FnSgSA4yxELeng52SNj55yaCbtP DGmkIxGz0NOQbU51YOmanm4AtIyhNVvRA9Tc7xUc2BWJM2BQidJQOKmrqGMWZvcwtZB9 jt88V2o5iQqOX6n5g5y3zQoE5RxTHxlrSvYk8NmMD8nECbTvYAwKezNqO8usQq6eO2HV n2Up3qNUVCjQig+RvJ89IeS4XwjSdinWYpD+fapCc2m5LVA+U8lZRvodO0jwJaSGCtTy vIrg== 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=XnuvMB0J1monHDTSCE4AjSSICHHhGGwURpGxrTZnkKs=; b=R2g6uGaj3HgF11ACSXyIpVEWGl9ZZ7i9zQ0DUHC99aDbBUVSjrnbgmneMozZY+iA/w sTboxq75T67aiaqjKxcRRNY+YruqmKfY0FFJKmUT1V1XVqeQoUnUv7rlo7pksDmG5Vgd /NT3p9tGnRcdFe2oLIhehdGUxEecrjd8D7pypIjfyZN1CcpPC4xFJk96W7zBEgxFDe4g XCIKlcUezf6YSp038em0Fu/HKgfNiAwWjeYauvCVQ8pLk7+PaaX03b3VSMYXxuhpwRst JRZdKAoMOoPsyPZHfmm4BZRuy8LqhASIqA7FKMtFfoX6S9CLdLdoQpSMIYSXr1bGAxb8 dn5w== X-Gm-Message-State: APjAAAWW9vnVZEqx1/9dVpghGLB+I39YmWTYT72Y7kqz1CBQv5W7MyUQ V5MYm9HXiGFcnHuYSW2wF+nEnQ== X-Received: by 2002:adf:a514:: with SMTP id i20mr4892081wrb.281.1562342664134; Fri, 05 Jul 2019 09:04:24 -0700 (PDT) Received: from zen.linaroharston ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id z25sm10457578wmf.38.2019.07.05.09.04.22 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Fri, 05 Jul 2019 09:04:22 -0700 (PDT) Received: from zen.linaroharston. (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id CA8AA1FF91; Fri, 5 Jul 2019 17:04:21 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Date: Fri, 5 Jul 2019 17:04:20 +0100 Message-Id: <20190705160421.19015-5-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190705160421.19015-1-alex.bennee@linaro.org> References: <20190705160421.19015-1-alex.bennee@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::441 Subject: [Qemu-devel] [PATCH v1 4/5] gdbstub: add some notes to the header comment X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , qemu-arm@nongnu.org, =?utf-8?q?Alex_Benn=C3=A9e?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Add a link to the remote protocol spec and an SPDX tag. Signed-off-by: Alex Bennée --- gdbstub.c | 6 ++++++ 1 file changed, 6 insertions(+) -- 2.20.1 Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé diff --git a/gdbstub.c b/gdbstub.c index 8618e34311..ea3349d1aa 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1,6 +1,10 @@ /* * gdb server stub * + * This implements a subset of the remote protocol as described in: + * + * https://sourceware.org/gdb/onlinedocs/gdb/Remote-Protocol.html + * * Copyright (c) 2003-2005 Fabrice Bellard * * This library is free software; you can redistribute it and/or @@ -15,6 +19,8 @@ * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, see . + * + * SPDX-License-Identifier: GPL-2.0-or-later */ #include "qemu/osdep.h" From patchwork Fri Jul 5 16:04:21 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 168560 Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp3757652ilk; Fri, 5 Jul 2019 09:08:39 -0700 (PDT) X-Google-Smtp-Source: APXvYqy/k5vuACXxB/XXw9aZ8OMV/NKX7OlFwClF7Kz9SwOsI+bhzREw9NLzXzyO/hoJSGooey9A X-Received: by 2002:aa7:d28a:: with SMTP id w10mr5412334edq.251.1562342919366; Fri, 05 Jul 2019 09:08:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562342919; cv=none; d=google.com; s=arc-20160816; b=yzv4iJTREroC9L70/eCypAtBHCvSuOra/qngRczs2i1s4vbWxkjdj18J14WDXFwpIu 99bOoBAEUI7G2up7Ug3ZZgmmNXA8AVGTe+4T4vJdU4QACmBr6aK+KqmyahN1nl0RsLPx ZzZ6AZZLhFgP94QczucE/gDJ+1YyiHKIO9cRFHFV8BXnbfMXzsibZokzCfAMb/YI93/p 9dEM2HFLtx4go+7rxrSigAtgI8O8YerhhWlVnrg7TTALhLIGzt5IMsWnwveewpQgeq3g F12vFcxUAnY9cD0YLKS+93HKwp8bwcOAu6kZQnNyWypqjCYQj3hryVeDX0nwCts67VZ8 SZvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=qOB93lgrL4R9/I6qfgAIZn9QujVBWBIWVU/5cvf+96Y=; b=puHWmJ5v8RoAwRl5G3c7NkKzVZAqalJwniAGoF1MOqn/1PYl7Q7hXzbFa0wHRzamMi JpcSvPB+bInb3xnoSNxbrNBMt+lA7ux0jeGifsxX1K5dOfB7ivDkz2oZbs6AdJp5ezBf 7/HKmdZYGHxoURZw83K75Vq+1VU3fr4Yd6Q1YjP0DrSt6M5GQpfxlrjAlrLnYkB0S3Ab KAjR5cr6ywXpbOtdNvKkJwhglXnZ+CSs7AbeNUmUPuHqMusqO7v1q5/oDTp5wUWZunfZ LXFeO0RVUHInjU0aSwXpJNGkfl4znfp0asfCgLhEoClCyRh8CcmCeXK0fxUsu+7WP2/y 6GHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b="yHISs/FM"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id l53si1582127edd.293.2019.07.05.09.08.39 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 05 Jul 2019 09:08:39 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b="yHISs/FM"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:54488 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQlK-0006en-C9 for patch@linaro.org; Fri, 05 Jul 2019 12:08:38 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40288) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjQhc-0002vB-JY for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hjQha-0001qR-D5 for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:48 -0400 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]:33290) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hjQha-0000XK-4C for qemu-devel@nongnu.org; Fri, 05 Jul 2019 12:04:46 -0400 Received: by mail-wm1-x342.google.com with SMTP id h19so7885306wme.0 for ; Fri, 05 Jul 2019 09:04:26 -0700 (PDT) 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=qOB93lgrL4R9/I6qfgAIZn9QujVBWBIWVU/5cvf+96Y=; b=yHISs/FMVOK0HYzPaloOwliLqK1L8EbywhZiD2dTaa3syaAx/DPfSJEQErohzcjhA+ fg+urcQHJcWn/tJF9hTAVXjaPJfxQskfNA6vlzpgC+qWP/e8zsmWvCwIDiLBhHSmW1F3 4ADA3/qEe2aTD7a4nD6bkKmMSo9b/YkVLN3nsAQl9WPdNd5ShUxfS/M6tobWe1s0QkDu EfyF2/IeKo3dr7JqxNKdq6lI0srD+WctTrKt7iCBenTHUnSh/Ju0q34qweMj5W2R4M2S q5htEUZZXPfIXEadiUxDtcBC1oUNF8UMDwJYbPxLYsezj4Ktnl8tWPcBQ4EmvjQ7rywV HT8w== 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=qOB93lgrL4R9/I6qfgAIZn9QujVBWBIWVU/5cvf+96Y=; b=EUwH/6gAGP5VckRw5aPzN9vJbxAYcFFeLa1gfy9VVWyjZTOlUR+CUFpIi96l22dLLF Xa134y6ZRLwPn4VYnmjjvDTkVg1YemXtBTUtX27VJIPAD6mAXmq/bl9nszstXj+lB2Wv 5+lPaE7FmNgIBXf8IsznI3KpaZgDfCkz+YzGEV0vIadARHUPjB+FWXeBEUmJZr+Ss0QF HN2oBonW3+VUMBfYoEcAp2RR8mSeADqupMZcbYE+yJYFTZdyo9X73Ky+woipO+72wWT3 LC5UjQvWXN8/lbDvMLMCa6vfM7RxnJnJYmP1e3MV1ASzUBe7H+uCgc+JJCQjp+LsvaCC XPPg== X-Gm-Message-State: APjAAAWb2T0G7XKrsB1ABcyWThDQIP5wMHAExPmKi1ub1ykOFFzcxfVK JxYQuaeDDjxEIdBSvyi0prwJQw== X-Received: by 2002:a7b:cc97:: with SMTP id p23mr4185121wma.120.1562342665585; Fri, 05 Jul 2019 09:04:25 -0700 (PDT) Received: from zen.linaroharston ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id t15sm9442318wrx.84.2019.07.05.09.04.22 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Fri, 05 Jul 2019 09:04:24 -0700 (PDT) Received: from zen.linaroharston. (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id DDC011FF92; Fri, 5 Jul 2019 17:04:21 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Date: Fri, 5 Jul 2019 17:04:21 +0100 Message-Id: <20190705160421.19015-6-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190705160421.19015-1-alex.bennee@linaro.org> References: <20190705160421.19015-1-alex.bennee@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::342 Subject: [Qemu-devel] [PATCH v1 5/5] gdbstub: revert to previous set_reg behaviour X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Mark Cave-Ayland , qemu-arm@nongnu.org, =?utf-8?q?Alex_Benn=C3=A9e?= , Jon Doron Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" The refactoring of handle_set_reg missed the fact we previously had responded with an empty packet when we were not using XML based protocols. This broke the fallback behaviour for architectures that don't have registers defined in QEMU's gdb-xml directory. Revert to the previous behaviour and clean up the commentary for what is going on. Fixes: 62b3320bddd Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Cc: Jon Doron Cc: Mark Cave-Ayland --- gdbstub.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) -- 2.20.1 Reviewed-by: Richard Henderson diff --git a/gdbstub.c b/gdbstub.c index ea3349d1aa..b6df7ee25a 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1669,12 +1669,23 @@ static void handle_remove_bp(GdbCmdContext *gdb_ctx, void *user_ctx) put_packet(gdb_ctx->s, "E22"); } +/* + * handle_set/get_reg + * + * Older gdb are really dumb, and don't use 'G/g' if 'P/p' is available. + * This works, but can be very slow. Anything new enough to understand + * XML also knows how to use this properly. However to use this we + * need to define a local XML file as well as be talking to a + * reasonably modern gdb. Responding with an empty packet will cause + * the remote gdb to fallback to older methods. + */ + static void handle_set_reg(GdbCmdContext *gdb_ctx, void *user_ctx) { int reg_size; if (!gdb_has_xml) { - put_packet(gdb_ctx->s, "E00"); + put_packet(gdb_ctx->s, ""); return; } @@ -1694,11 +1705,6 @@ static void handle_get_reg(GdbCmdContext *gdb_ctx, void *user_ctx) { int reg_size; - /* - * Older gdb are really dumb, and don't use 'g' if 'p' is avaialable. - * This works, but can be very slow. Anything new enough to - * understand XML also knows how to use this properly. - */ if (!gdb_has_xml) { put_packet(gdb_ctx->s, ""); return;