From patchwork Mon Nov 7 23:58:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 622251 Delivered-To: patch@linaro.org Received: by 2002:a17:522:c983:b0:460:3032:e3c4 with SMTP id kr3csp2556330pvb; Mon, 7 Nov 2022 15:59:27 -0800 (PST) X-Google-Smtp-Source: AMsMyM7DvRBLeHfe/ffmRd6lvF5R4arkNqAgyiizfnX5Q8dqr6vvrDSvCqpxkRhZrmT4zX1YIe86 X-Received: by 2002:a05:620a:26a3:b0:6ce:2f8d:8750 with SMTP id c35-20020a05620a26a300b006ce2f8d8750mr610070qkp.558.1667865567662; Mon, 07 Nov 2022 15:59:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1667865567; cv=none; d=google.com; s=arc-20160816; b=sM6873Nm2a+mztksXHyv+wteYx64yIf0hEEz9YQnxZc40/a9sQqGVa8Tcx7yh/ul/X 5SHePeg9ZcfIwXdr61OJ6Byg8GCVfOX51z08X3u7R25dUqVxqV4CDSyIgKB7lwwhkDuY zsC7JgOMT1DyyNz1jrQXFiHMdQ4kfbAaOpA/yLHwyhqk6eMB1ZN+0cR35Nr21HC5hymt jucLelJg8twLbCjwOTO4sICDoXloor3qtmOwvP4Y6tRAdsAW5uMnPQ77J9abU7t7/HMi A8CBdAD9DMHD3GKvDn/gFVI1BsKbcAu2V0g8H4ETZaT7CRK1/Ti4zYl7xewqAnvVc2v0 sbVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=wqdXWOgF+QqRi3UtOQa5YNqdO+ylycMo+xdPULOGfzw=; b=UcFpazNU6LFheSxCPZsCRruGA+QYYI3R69T0nAEeWwFJm/LDQQbesCMeCNA71ZpYJG Y1Lh090qoMNmPyiuUs/kq1rz9kkj1317PjaY31W6Cb4LoGv3uH1EtCs9F2zBqUF9WlFE smNHrQjsaXL3mi/EevePzqdqaAXGJuxexCWi6EPI+ma3ICe6RhCh7o3OVsXrCNznBJVw vBr68tY1yvBrQr1jCAUduS7Pz0PV94DTXUJz/Tkm4qRd3SHYbR6z/UMxiF77S0lL+obl fq+Lz/jDJjNP9V4P7STEutLIFRTTyLnsV3KGHQSGWLz+7y5peYRuLeZTrZq6IfJpaAp4 PxaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aoeAt2eM; 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=pass (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 d7-20020a05620a240700b006f981898519si6208926qkn.50.2022.11.07.15.59.27 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 07 Nov 2022 15:59:27 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=aoeAt2eM; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1osC0k-00047J-MC; Mon, 07 Nov 2022 18:58:38 -0500 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 1osC0j-000476-Dd for qemu-devel@nongnu.org; Mon, 07 Nov 2022 18:58:37 -0500 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1osC0h-0000TM-R9 for qemu-devel@nongnu.org; Mon, 07 Nov 2022 18:58:37 -0500 Received: by mail-wm1-x32b.google.com with SMTP id i5-20020a1c3b05000000b003cfa97c05cdso23329wma.4 for ; Mon, 07 Nov 2022 15:58:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; 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=wqdXWOgF+QqRi3UtOQa5YNqdO+ylycMo+xdPULOGfzw=; b=aoeAt2eMTMja+2VjIMLDVi7a5CKWaAATS7ECeWBJ850iYPMFXzP+eVK0oGQisRblmz 0B392hght6sXes1Zz5NshVBlDUTSQ5QHHiAQVyOR/JrfaYJyguilQ6fyvWIc1gLCZ9wA x/WBisxPCIi0nWtlRsdt4RDpH7S/Zho9wDjWdwuegr7YrxNC0CFlaTFZCRFkMbvBMjgt PDt2jr2fL9gvHCbeN+Viwvqo0d2bszQkoCjUlAEjRaFyXwsL+XqQ/TdhpEn53kIn8n7q lskDxguLs/veqhIv+W9y2YbeRT6jl9H8H9JUn8518oaYC5A8oQy5IhTJ0t00NMehPpxy f17Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=wqdXWOgF+QqRi3UtOQa5YNqdO+ylycMo+xdPULOGfzw=; b=gEVh6SVLQkOKwg90uMVIP0DoDY46n0+AgEYqDVJeBdSlp+3LXq64MAloVsOmRD6g3N RCh24IDE4sBSCElDCUhz6ExPdUS+Cwf5YwsdKSW8EgPZ1k8TXK1fDp/yuXwvGxmjMqQp jpP4A2mW0L6qhLIMgR1EDzPGLSqqHywSrlhGfOAeDXDURmqIylOAJHZXHZ2WNnfmQmWl ogK7ZRjbHqgjvI/C3YeCWBCNva8/V2ndyfH9ULEylQEQl81TIGGTv9aSuttIFlIwpS1y kfB9nC1o9d7qbhpHpzpqfo7sOcgWeXDn6MbcedIz9AmLCoA/q2q9/pfcWFAC4Y3Pwd71 iRbA== X-Gm-Message-State: ACrzQf1wQ49LvAJSufbIh8iN9j9+rqBnsTFQTRrkojHDfPuDgNdS53yf 2NDB26E+a+0yyjwuYM3SZf+YH2AyrjZNpw== X-Received: by 2002:a05:600c:1994:b0:3cf:7c1e:8227 with SMTP id t20-20020a05600c199400b003cf7c1e8227mr25441066wmq.103.1667865513965; Mon, 07 Nov 2022 15:58:33 -0800 (PST) Received: from localhost.localdomain ([185.126.107.38]) by smtp.gmail.com with ESMTPSA id m21-20020a7bca55000000b003c6c182bef9sm15153410wml.36.2022.11.07.15.58.33 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Mon, 07 Nov 2022 15:58:33 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Aurelien Jarno , Aleksandar Rikalo , Jiaxun Yang , Richard Henderson , Pavel Dovgalyuk Subject: [PULL 02/14] target/mips: Cast offset field of Octeon BBIT to int16_t Date: Tue, 8 Nov 2022 00:58:10 +0100 Message-Id: <20221107235822.71458-3-philmd@linaro.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221107235822.71458-1-philmd@linaro.org> References: <20221107235822.71458-1-philmd@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=philmd@linaro.org; helo=mail-wm1-x32b.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_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org From: Jiaxun Yang As per "Cavium Networks OCTEON Plus CN50XX Hardware Reference Manual" offset field is signed 16 bit value. However arg_BBIT.offset is unsigned. We need to cast it as signed to do address calculation. Signed-off-by: Jiaxun Yang Acked-by: Richard Henderson Acked-by: Pavel Dovgalyuk Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20221031132531.18122-3-jiaxun.yang@flygoat.com> Signed-off-by: Philippe Mathieu-Daudé --- target/mips/tcg/octeon.decode | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/mips/tcg/octeon.decode b/target/mips/tcg/octeon.decode index 8929ad088e..0c787cb498 100644 --- a/target/mips/tcg/octeon.decode +++ b/target/mips/tcg/octeon.decode @@ -12,7 +12,7 @@ # BBIT132 111110 ..... ..... ................ %bbit_p 28:1 16:5 -BBIT 11 set:1 . 10 rs:5 ..... offset:16 p=%bbit_p +BBIT 11 set:1 . 10 rs:5 ..... offset:s16 p=%bbit_p # Arithmetic # BADDU rd, rs, rt