From patchwork Tue Oct 29 23:17:46 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ilya Leoshkevich X-Patchwork-Id: 13855645 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 28EA9D7494C for ; Tue, 29 Oct 2024 23:23:14 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t5vXf-0004Da-4y; Tue, 29 Oct 2024 19:22:27 -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 1t5vXb-0004Cz-IS for qemu-devel@nongnu.org; Tue, 29 Oct 2024 19:22:23 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t5vXa-00045j-1S for qemu-devel@nongnu.org; Tue, 29 Oct 2024 19:22:23 -0400 Received: from pps.filterd (m0360072.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 49TLKLKj012566; Tue, 29 Oct 2024 23:22:17 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=cc :content-transfer-encoding:date:from:message-id:mime-version :subject:to; s=pp1; bh=6APVo9fDg4j77qN67kGc2dJLQM0pKjRWMwYonPDvl iU=; b=ZC9Vp8s7xYFca6mUrRPmVgmR9JiVpiNAElPrCWrSB2HzlKgl/VpFbhDZ1 4IRHhonz2EOgFeQmRN9lWSVehZ+X8epx7pCLH9ycewd1DLGxSlKKOQmBQWeGtcoC Kx8dU13Ajn0g+Pd7PEiqmRMv1FcnJIiiRwxI0PSrcwvNxZIbVBYe/R/yHFPNL0sW FLXwpvTCUnTFvnzwmnP62x0CNTrR8EioHlP1giNE4lD0ApP2zLsah4tU5YMiO8mx N8jKUWkZT2RFZsvS8K6C6DiBJXuC6gsvjomtmR1B0o9Kn6k2pS3eSW2YoeALRtod XC0WRkmhycvRgeUO75w6T99Qovkbg== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 42k6gt0jx0-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 29 Oct 2024 23:22:17 +0000 (GMT) Received: from m0360072.ppops.net (m0360072.ppops.net [127.0.0.1]) by pps.reinject (8.18.0.8/8.18.0.8) with ESMTP id 49TNMG0m010549; Tue, 29 Oct 2024 23:22:16 GMT Received: from ppma13.dal12v.mail.ibm.com (dd.9e.1632.ip4.static.sl-reverse.com [50.22.158.221]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 42k6gt0jwy-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 29 Oct 2024 23:22:16 +0000 (GMT) Received: from pps.filterd (ppma13.dal12v.mail.ibm.com [127.0.0.1]) by ppma13.dal12v.mail.ibm.com (8.18.1.2/8.18.1.2) with ESMTP id 49TJKCbR024726; Tue, 29 Oct 2024 23:22:16 GMT Received: from smtprelay05.fra02v.mail.ibm.com ([9.218.2.225]) by ppma13.dal12v.mail.ibm.com (PPS) with ESMTPS id 42hcyjd51f-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 29 Oct 2024 23:22:15 +0000 Received: from smtpav04.fra02v.mail.ibm.com (smtpav04.fra02v.mail.ibm.com [10.20.54.103]) by smtprelay05.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 49TNMEOe54853928 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 29 Oct 2024 23:22:14 GMT Received: from smtpav04.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 4445720043; Tue, 29 Oct 2024 23:22:14 +0000 (GMT) Received: from smtpav04.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id D719020040; Tue, 29 Oct 2024 23:22:13 +0000 (GMT) Received: from heavy.ibm.com (unknown [9.171.12.2]) by smtpav04.fra02v.mail.ibm.com (Postfix) with ESMTP; Tue, 29 Oct 2024 23:22:13 +0000 (GMT) From: Ilya Leoshkevich To: Richard Henderson , =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , =?utf-8?q?Alex_Benn=C3=A9e?= , Laurent Vivier Cc: qemu-devel@nongnu.org, Michael Tokarev , Brian Cain , "ltaylorsimpson @ gmail . com" , Ilya Leoshkevich Subject: [PATCH v3 0/2] linux-user: Allow mapping low priority rt signals Date: Wed, 30 Oct 2024 00:17:46 +0100 Message-ID: <20241029232211.206766-1-iii@linux.ibm.com> X-Mailer: git-send-email 2.47.0 X-TM-AS-GCONF: 00 X-Proofpoint-GUID: Qblx9x__HW5l8SgX7SC32xWJw3oOwXnB X-Proofpoint-ORIG-GUID: moZtEYMz2InOSE-sUAibupGqciTH7Y4t X-Proofpoint-UnRewURL: 0 URL was un-rewritten MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1051,Hydra:6.0.680,FMLib:17.12.62.30 definitions=2024-10-15_01,2024-10-11_01,2024-09-30_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 priorityscore=1501 impostorscore=0 suspectscore=0 lowpriorityscore=0 mlxscore=0 clxscore=1015 phishscore=0 adultscore=0 spamscore=0 bulkscore=0 mlxlogscore=862 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2409260000 definitions=main-2410290175 Received-SPF: pass client-ip=148.163.158.5; envelope-from=iii@linux.ibm.com; helo=mx0b-001b2d01.pphosted.com X-Spam_score_int: -26 X-Spam_score: -2.7 X-Spam_bar: -- X-Spam_report: (-2.7 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, 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+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org v1: Unfortunately lost. v2: https://lore.kernel.org/qemu-devel/20240212205022.242968-1-iii@linux.ibm.com/ v2 -> v3: Make the mapping configurable (Richard). Hi, There are apps out there that want to use SIGRTMAX, which linux-user currently does not map to a host signal. The reason is that with the current approach it's not possible to map all target signals, so it was decided to sacrifice the end of the range. This series improves the situation by making the mapping configurable. Patch 1 is the implementation, patch 2 is a test. Best regards, Ilya Ilya Leoshkevich (2): linux-user: Allow custom rt signal mappings tests/tcg: Add SIGRTMIN/SIGRTMAX test linux-user/main.c | 12 +- linux-user/signal-common.h | 2 +- linux-user/signal.c | 108 ++++++++++++++---- meson.build | 3 +- meson_options.txt | 2 + scripts/meson-buildoptions.sh | 2 + tests/tcg/Makefile.target | 4 +- tests/tcg/multiarch/linux/linux-sigrtminmax.c | 74 ++++++++++++ 8 files changed, 182 insertions(+), 25 deletions(-) create mode 100644 tests/tcg/multiarch/linux/linux-sigrtminmax.c