From patchwork Thu Nov 19 16:17:07 2020 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: 11918179 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.5 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B0427C63697 for ; Thu, 19 Nov 2020 16:21:42 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 11B5D22261 for ; Thu, 19 Nov 2020 16:21:41 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="uDcAQUR7" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 11B5D22261 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=amsat.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:53926 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kfmgm-0004GY-QC for qemu-devel@archiver.kernel.org; Thu, 19 Nov 2020 11:21:40 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:51834) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kfmcb-0007df-EW for qemu-devel@nongnu.org; Thu, 19 Nov 2020 11:17:21 -0500 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]:53124) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kfmcZ-0006Ra-Sf for qemu-devel@nongnu.org; Thu, 19 Nov 2020 11:17:21 -0500 Received: by mail-wm1-x341.google.com with SMTP id 10so7736260wml.2 for ; Thu, 19 Nov 2020 08:17:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=NgO3tcHedPydaPsxFO6dG6qOvzXCjuA0Kh6wwHmDQo4=; b=uDcAQUR7Lo/M3Vos5gqKcwXL59TQMZAs46aJBYaEpetkeStPXVNmf2jGIa5yIp93mm oDKysxKpk3PGVLcTKJR12Vuq2p4+RPxCu/3XKqQT1MeFHlyEJiFFqESJr5ROkE+jYDkX do8XRLJKje7+f2G11lPYjpAilXcomnMcQY6VwK//uJZSoKqUYGpBZnMBsENGdAj5+nGv gYDWeZMTzNLeln1POkceA9miGCaW5umi5I5igZh2DX50BAe1qQEYxl3mo3fBsiOs2LAj mAGTc6nHekzRbRXzzqEuWfWYknRHMShZRAzzyOzKiDtL0eQ4zm+n+MwaULN6WrN+CxrR mqRg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=NgO3tcHedPydaPsxFO6dG6qOvzXCjuA0Kh6wwHmDQo4=; b=neHbnvrBQoUuuGdEFDZvVLZFpJ6Vu6j3axGU+ffq9OytdHq/GsYLtBZd3JOz5Sudfb zAuVii6CWYZlH8Gp8Nd6UE7WTr0yRNzvKJ+OWhx3WQ7QkOpAgSqW3wXO0gXfGTILjBFh 4Cc4UxfnVzTHwuc9QYXenFoEC5VlFeIEw0MBjvhsnZIR0vS1OjBCerjdTM5wu6rTGmrn InAJTYHVh+dTcXx0941kx6O/yl6xaHYFrYxercrkCUpy1kVLefdPZzEBVStOAURNCmJH w4vK43XTroRKTmNjUohFn6e3WhRNomW5eYeAIfCNdXKAdLmrOWT/apTVfIlYe79kTLFR 5mSg== X-Gm-Message-State: AOAM532EsQ7NEaLotreNp5DCzOewPlFNu7DXRtlXxYDk7iMeWU0lf9np 3oL3IPUSmgtcqHJMuYBF/VwzmL0KL+s= X-Google-Smtp-Source: ABdhPJwlAr3gwe9bT6mS7xMBvI+Yg3zMJw8l1teNKgveQE14WPGlUCHouNtKWx4n+reD+NBxKKdatw== X-Received: by 2002:a05:600c:414b:: with SMTP id h11mr5331852wmm.89.1605802638149; Thu, 19 Nov 2020 08:17:18 -0800 (PST) Received: from x1w.redhat.com (234.red-83-42-66.dynamicip.rima-tde.net. [83.42.66.234]) by smtp.gmail.com with ESMTPSA id e6sm533999wme.27.2020.11.19.08.17.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Nov 2020 08:17:17 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH 1/4] linux-user/mips64: Restore setup_frame() for o32 ABI Date: Thu, 19 Nov 2020 17:17:07 +0100 Message-Id: <20201119161710.1985083-2-f4bug@amsat.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201119161710.1985083-1-f4bug@amsat.org> References: <20201119161710.1985083-1-f4bug@amsat.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::341; envelope-from=philippe.mathieu.daude@gmail.com; helo=mail-wm1-x341.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.25, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action 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: Richard Henderson , Laurent Vivier , Aurelien Jarno , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" 64-bit MIPS targets lost setup_frame() during the refactor in commit 8949bef18b9. Restore it declaring TARGET_ARCH_HAS_SETUP_FRAME, to be able to build the o32 ABI target. Fixes: 8949bef18b9 ("linux-user: move mips/mips64 signal.c parts to mips directory") Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: Laurent Vivier --- linux-user/mips64/target_signal.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/linux-user/mips64/target_signal.h b/linux-user/mips64/target_signal.h index 799f7a668cd..f1f0ed7f706 100644 --- a/linux-user/mips64/target_signal.h +++ b/linux-user/mips64/target_signal.h @@ -67,4 +67,8 @@ typedef struct target_sigaltstack { #define TARGET_MINSIGSTKSZ 2048 #define TARGET_SIGSTKSZ 8192 +#if defined(TARGET_ABI_MIPSO32) +/* compare linux/arch/mips/kernel/signal.c:setup_frame() */ +#define TARGET_ARCH_HAS_SETUP_FRAME +#endif #endif /* MIPS64_TARGET_SIGNAL_H */ From patchwork Thu Nov 19 16:17:08 2020 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: 11918175 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.5 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4562EC63697 for ; Thu, 19 Nov 2020 16:19:15 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 980BB22261 for ; Thu, 19 Nov 2020 16:19:14 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Y0VUGr/c" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 980BB22261 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=amsat.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:46476 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kfmeP-0000y1-IP for qemu-devel@archiver.kernel.org; Thu, 19 Nov 2020 11:19:13 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:51866) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kfmcg-0007fn-5M for qemu-devel@nongnu.org; Thu, 19 Nov 2020 11:17:26 -0500 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]:46919) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kfmce-0006Su-O5 for qemu-devel@nongnu.org; Thu, 19 Nov 2020 11:17:25 -0500 Received: by mail-wr1-x431.google.com with SMTP id d12so6966822wrr.13 for ; Thu, 19 Nov 2020 08:17:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=WI9FhYkhmV3H0Q4oY0sfeWzV/m4iQyNuvlsEXmPQcZI=; b=Y0VUGr/cCtmiSQo8N+dQldZ1qh7flz5sDCV3kNspf7a40ah08/HC3GxiDCNNxEsYDN IdqgTec/4PVId4HZ6nxaIIKxF5aBYdDpDdqM6BgYdEFzzsk6z/crP2IV63xIB7JOPIeF K5BPz3wYrr7lsbxg28j5TswEVD96AlZ8yrnL4lno6Tj6WO/0/2FIfoUUml6tGUmM4Zvh yup3IYsZfUTTRPcjupJ7d6bpWnnHCwdsGzG/Jr1+2+vxW0zk32R5Ei7M8s1N1ri3UzMY 0TnortewlE8sHVld3VQNGNs8VDIXCYzRBaibhPIOE4sXx0ysOh8t8RqnbN003ul8orAi IIPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=WI9FhYkhmV3H0Q4oY0sfeWzV/m4iQyNuvlsEXmPQcZI=; b=URYrDw0fbJAaXrmu0lrvz5SQAsT/RzmyNDh76VIiCFID6sggZaBOpZ9DcJxo8Tee0D Mhc+kqW2xGdGHcvSXfWVQz+qcDgiQo/phc+Sv/hYt8KUr5SoEuPVeeKbPxOVye1H9oj8 kdD9W3NUptxCWpLw2sobUNEQyNNzeCqqJ9f45h/lPRWk3+UqhKFOgpLLrKFKrLYhOfsZ Miu+OMi/A0I7Eln91Uaa3A0IKCkWHfG2eJuwojESRDVW7GAFKkTWU83YBWPeasp4z04i OOrbni9JyeGQutovKwVqfoJekYykK0u+N5oyqIjuSZS88NqubWHPQj//5YOQBBhY3/Q9 gm/w== X-Gm-Message-State: AOAM533Ens4S4FSD0pDu4GSQvXzfJhSqxvLw4IKi7RQwzyg5wOW36Cuk vI3YF4bomNkLjtdOdomSh6UOtmtw5EI= X-Google-Smtp-Source: ABdhPJwJfLQSB3557OwHCkaFMJQ9vfI0QzdOg0egl7bpENDA8srq73UyC15zNlrtFQUtU3WZ4l3ppw== X-Received: by 2002:adf:ce07:: with SMTP id p7mr11946118wrn.39.1605802642990; Thu, 19 Nov 2020 08:17:22 -0800 (PST) Received: from x1w.redhat.com (234.red-83-42-66.dynamicip.rima-tde.net. [83.42.66.234]) by smtp.gmail.com with ESMTPSA id n23sm506464wmk.24.2020.11.19.08.17.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Nov 2020 08:17:22 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH 2/4] linux-user/mips64: Support o32 ABI syscalls Date: Thu, 19 Nov 2020 17:17:08 +0100 Message-Id: <20201119161710.1985083-3-f4bug@amsat.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201119161710.1985083-1-f4bug@amsat.org> References: <20201119161710.1985083-1-f4bug@amsat.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::431; envelope-from=philippe.mathieu.daude@gmail.com; helo=mail-wr1-x431.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.25, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action 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: Richard Henderson , Laurent Vivier , Aurelien Jarno , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" o32 ABI syscalls start at offset 4000. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: Laurent Vivier --- linux-user/mips64/syscall_nr.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/linux-user/mips64/syscall_nr.h b/linux-user/mips64/syscall_nr.h index 672f2fa51cb..6579421fa63 100644 --- a/linux-user/mips64/syscall_nr.h +++ b/linux-user/mips64/syscall_nr.h @@ -1,4 +1,7 @@ -#ifdef TARGET_ABI_MIPSN32 +#if defined(TARGET_ABI_MIPSO32) +#define TARGET_SYSCALL_OFFSET 4000 +#include "syscall_o32_nr.h" +#elif defined(TARGET_ABI_MIPSN32) #define TARGET_SYSCALL_OFFSET 6000 #include "syscall_n32_nr.h" #else From patchwork Thu Nov 19 16:17:09 2020 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: 11918177 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.5 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E4DC5C56201 for ; Thu, 19 Nov 2020 16:19:45 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 5560C22261 for ; Thu, 19 Nov 2020 16:19:45 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="dDwV2HOO" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 5560C22261 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=amsat.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:49242 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kfmeu-00027w-4v for qemu-devel@archiver.kernel.org; Thu, 19 Nov 2020 11:19:44 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:51926) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kfmct-0007jO-7i for qemu-devel@nongnu.org; Thu, 19 Nov 2020 11:17:39 -0500 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]:40779) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kfmcp-0006V0-FV for qemu-devel@nongnu.org; Thu, 19 Nov 2020 11:17:38 -0500 Received: by mail-wm1-x343.google.com with SMTP id a3so7255541wmb.5 for ; Thu, 19 Nov 2020 08:17:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=yVxKoMCNOb0M91+IB4bEHuCMrgq5vsUnaIKYxB1d630=; b=dDwV2HOOETBDkUsCMTNHCyuyyqzdt3cOrYoC7qLG+IxqEmTiqd8zVzLhTe/ge0DNg0 YQs/xgU/vxsBu7TBXEQgdUpwbb+PY+Xor+Xqpb7ZRmlt8SXneHMUHroxQcGetjImCCpE Lpqk7iwzAuaPVX/XnBvx6im9L8KQKCnAuNhR8b2/Ob7dHWblsLK81tfFJDSjaDUMOKww E8oMkNLWKwC7aQshAPNK7jkeNizEuCX9lNK+E4tCLZeATOtnDucMXHWeIHFfUCQKElbU YaTRpNBAul1nMGaynZm/9DJ//4k5NS8A2ViH2EHooRzO27Cr8iM+z6Ta91cRsHIDOQ3+ SgcA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=yVxKoMCNOb0M91+IB4bEHuCMrgq5vsUnaIKYxB1d630=; b=Zc4F/4pRqIvtn4H/QfPaKl5bMlPyNSGSKvxNO/5pZN5A92fpfoDKqbxi3GLUFksZmC JgLKnuq9QMInxwidiK9q9L4xqnFH+0Flyb5S4RSiHFkXSX7nucmrz145Ht7qHAWnGsTx UEggliCNpV1hUj84tD7yuSxQ10pNac9GEgb/5qugRxNowVqCZ14l4ZZyvQvfFjd6SQyK cU0X1uDO+3H71f7UWLZbjcmi7lsCUM90EsJ/cnH3Q9wAhDhKcNykxF6afRoeATbhnfAk 3aVOgNN6vhqErCvMpWAS988PZO5lVX2RFTZmI6kqXksEK5a4151UnLN9cuxEpKuCc4Zx Bf1Q== X-Gm-Message-State: AOAM533kfncOIoH0oVNzE7zRfdc9f4TJWK5hqQO4f8ZAUAnY+P+uT7sx 5MlSsuw3YWMlzq3Mp7ldub78VUHM44E= X-Google-Smtp-Source: ABdhPJyQMKDqqtDvaS0yImovipER8E5lurtCERQLOi6XOKGhEV1J8r7wbuzJOFN+OGB+9K+1aY9j7g== X-Received: by 2002:a1c:56c4:: with SMTP id k187mr5368084wmb.92.1605802648205; Thu, 19 Nov 2020 08:17:28 -0800 (PST) Received: from x1w.redhat.com (234.red-83-42-66.dynamicip.rima-tde.net. [83.42.66.234]) by smtp.gmail.com with ESMTPSA id t7sm323418wrp.26.2020.11.19.08.17.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Nov 2020 08:17:27 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH 3/4] default-configs: Support o32 ABI with 64-bit MIPS CPUs Date: Thu, 19 Nov 2020 17:17:09 +0100 Message-Id: <20201119161710.1985083-4-f4bug@amsat.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201119161710.1985083-1-f4bug@amsat.org> References: <20201119161710.1985083-1-f4bug@amsat.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::343; envelope-from=philippe.mathieu.daude@gmail.com; helo=mail-wm1-x343.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.25, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action 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: Fredrik Noring , David Daney , Mathieu Malaterre , Richard Henderson , Laurent Vivier , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , YunQiang Su , James Cowgill , "Maciej W . Rozycki" , =?utf-8?q?J=C3=BCrgen_Urban?= , Aurelien Jarno , Richard Henderson Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" MIPS o32 ABI on 64-bit CPUs looks like a ILP32-on-64bit data model, allowing 64-bit arithmetic and data movement instructions. This is the default ABI used by the "Sony Linux Toolkit for Playstation 2". As we don't know big-endian uses, we only introduce the little-endian variant. Inspired-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- Cc: Fredrik Noring Cc: Maciej W. Rozycki Cc: Jürgen Urban Cc from https://lists.debian.org/debian-mips/2015/05/msg00014.html: Cc: Mathieu Malaterre Cc: James Cowgill Cc: YunQiang Su Cc: David Daney --- docs/user/main.rst | 3 +++ default-configs/targets/mips64o32el-linux-user.mak | 7 +++++++ 2 files changed, 10 insertions(+) create mode 100644 default-configs/targets/mips64o32el-linux-user.mak diff --git a/docs/user/main.rst b/docs/user/main.rst index 8dfe232a3af..2cef1320ff3 100644 --- a/docs/user/main.rst +++ b/docs/user/main.rst @@ -211,6 +211,9 @@ Other binaries * ``qemu-mipsel`` executes 32-bit little endian MIPS binaries (MIPS O32 ABI). + * ``qemu-mips64o32el`` executes 64-bit little endian MIPS binaries (MIPS O32 + ABI). + * ``qemu-mips64`` executes 64-bit big endian MIPS binaries (MIPS N64 ABI). * ``qemu-mips64el`` executes 64-bit little endian MIPS binaries (MIPS N64 diff --git a/default-configs/targets/mips64o32el-linux-user.mak b/default-configs/targets/mips64o32el-linux-user.mak new file mode 100644 index 00000000000..ecd57ff949f --- /dev/null +++ b/default-configs/targets/mips64o32el-linux-user.mak @@ -0,0 +1,7 @@ +TARGET_ARCH=mips64 +TARGET_BASE_ARCH=mips +TARGET_ABI_MIPSO32=y +TARGET_ABI32=y +TARGET_SYSTBL_ABI=o32 +TARGET_SYSTBL=../mips/syscall_o32.tbl +TARGET_ALIGNED_ONLY=y From patchwork Thu Nov 19 16:17:10 2020 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: 11918181 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.5 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 487AEC56201 for ; Thu, 19 Nov 2020 16:22:13 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8F68A22261 for ; Thu, 19 Nov 2020 16:22:12 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Rkft/W1w" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8F68A22261 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=amsat.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:56076 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kfmhH-0005Am-B9 for qemu-devel@archiver.kernel.org; Thu, 19 Nov 2020 11:22:11 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:51934) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kfmcv-0007kQ-7q for qemu-devel@nongnu.org; Thu, 19 Nov 2020 11:17:41 -0500 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:33413) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kfmcr-0006V6-4p for qemu-devel@nongnu.org; Thu, 19 Nov 2020 11:17:39 -0500 Received: by mail-wr1-x443.google.com with SMTP id u12so7093347wrt.0 for ; Thu, 19 Nov 2020 08:17:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=8eLVJbUNjYZyxrSQxAmxCAQnENDI0cgTjzGKpzQgynw=; b=Rkft/W1wjBqamc8D7GwFCpJNnldlRzjhYXSodM+OE2E8LfkOyPLtMADyIPoCbgpqQ6 fbKz9+/Cj9Tvh0eMH8MCBr5wjU21svjdFFWXDCWUlLKchLP3GHLQ4FwpSXnqYQ9zbl6L w4ZhSt93HNnRgzCl+xCJ9OPlxSQATZ96+KG8+yTvA6AZ3HtE+3nDOVNL/gXSw1KKqIGT XHCaX80bq4j/ffc2gxMgT+Lmu14hDXmeCqFIoJ2UJYz2DvQ/gggaRZ5ubfoZwCTdsLtR xYujJK9eS9gbBD0Fss4x9YkVYoSy691mluAwh8vWfDsrbKbPza3adMQKg4Al/eCj3EUE SyFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=8eLVJbUNjYZyxrSQxAmxCAQnENDI0cgTjzGKpzQgynw=; b=Jbz7lEHFjRVSQ7u1INRwgMDL0oPSUvDjm4JUic9iC55k66t6OztOz1sE62ucMGxNPa NCo96P+LuQa/GG8Fezs1Oq3gU0ixDlkw6TQNB15ZrKQC5EL2P4fEs07PvDTDJbnTWTJ5 OSTwplkoZth8oNrCzCmkYJjB9BeBba25c63HN46Rr+7veAYy5vAh36dP2lPauPwLWEj3 NoFQx9oIpJizAP4Z/roreM9ggzqwITVKbmri6zxt5KxuKhOKuPL1cpzUy1WtJcMK21af XAr81NH2Kq0GbRqB+jM39+HRD8v6YWvB225X65pSY+N5GcOl8+iXSxUfCmGxw7qMn5MU WAzg== X-Gm-Message-State: AOAM532djU4P6J1xVgEYYKJ7WWeANVAE3+msM9jRuTbTyZJWKnOi6Sms 0oZM+PrrzPtYfrBG2esX5l3Ahbp943s= X-Google-Smtp-Source: ABdhPJwp9Aiv2XdNJwc0GX37kiZDDD5JTYHsG+GrSJYAYnvPLKWLdLigpls4qk6HJH28qVy3l8BbKQ== X-Received: by 2002:a5d:548b:: with SMTP id h11mr11197447wrv.306.1605802653037; Thu, 19 Nov 2020 08:17:33 -0800 (PST) Received: from x1w.redhat.com (234.red-83-42-66.dynamicip.rima-tde.net. [83.42.66.234]) by smtp.gmail.com with ESMTPSA id p19sm398640wrg.18.2020.11.19.08.17.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Nov 2020 08:17:32 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH 4/4] RFC qemu-binfmt-conf.sh: Add MIPS64 o32 ABI Date: Thu, 19 Nov 2020 17:17:10 +0100 Message-Id: <20201119161710.1985083-5-f4bug@amsat.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201119161710.1985083-1-f4bug@amsat.org> References: <20201119161710.1985083-1-f4bug@amsat.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::443; envelope-from=philippe.mathieu.daude@gmail.com; helo=mail-wr1-x443.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.25, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action 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: Richard Henderson , Laurent Vivier , Aurelien Jarno , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" ... but this is wrong as the same header matches MIPS32 o32 ELFs... Signed-off-by: Philippe Mathieu-Daudé --- checkpatch errors: ERROR: line over 90 characters #9: FILE: scripts/qemu-binfmt-conf.sh:71: +mips64o32el_magic='\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08\x00' ERROR: line over 90 characters #10: FILE: scripts/qemu-binfmt-conf.sh:72: +mips64o32el_mask='\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff' --- scripts/qemu-binfmt-conf.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/qemu-binfmt-conf.sh b/scripts/qemu-binfmt-conf.sh index 9f1580a91c7..ee86345ff8a 100755 --- a/scripts/qemu-binfmt-conf.sh +++ b/scripts/qemu-binfmt-conf.sh @@ -68,6 +68,10 @@ mipsel_magic='\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x0 mipsel_mask='\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff' mipsel_family=mips +mips64o32el_magic='\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08\x00' +mips64o32el_mask='\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff' +mips64o32el_family=mips + mipsn32_magic='\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08' mipsn32_mask='\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff' mipsn32_family=mips