From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7486B3DC4DA for ; Thu, 9 Jul 2026 07:05:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=148.163.158.5 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783580709; cv=none; b=VohvaOK9jwY3bAfqr7mbeNK60z72mggCj7+ZW4Is4qjBPpQ6Lp2TgAE+mRkVOoB4vV6JnWtbLivo4DRxTlOJIbozuITiJUE+VEhc6rKV3M2r6eXZo7uCNVxZVCbMfE/t5jrboWXrueBk/ePK/21UrgFriitv8d9wjrU76Ia1Nf8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783580709; c=relaxed/simple; bh=n/jnYP2gEJu2I3vE2XyWlzLUx/q3xp6V3BhCGrJ05xU=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=R17emMX/M9ePnQWnCZEtk09X36yYF5+8OdmWXe8IgqTonD76x07DvBk4hCRbTHeH1ajli0Yks6GPQK/6lsKOljnjPhQK5OvR6ZJlGHZN3JhxLOgRRUGhBXBiJCUdtDbQfmyr9/9m5daz8G06z3w8nHZ8bcLESRc+/+s+IvTQQgE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com; spf=pass smtp.mailfrom=linux.ibm.com; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b=OQb2glAR; arc=none smtp.client-ip=148.163.158.5 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.ibm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b="OQb2glAR" Received: from pps.filterd (m0356516.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 6696IrVb1536197; Thu, 9 Jul 2026 07:04:38 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=cc :content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to; s=pp1; bh=n/jnYP2gEJu2I3vE2XyWlzLUx/q3xp 6V3BhCGrJ05xU=; b=OQb2glARHmXOtzqB7zvm9nNwWsqXxuuw0qjYNCr5TFjIam w9B0KLo+c4Ls4/UbmyEOHPFN8vj+v5KuN3Pa3A95a8A4fp74Q5t+bUnfRoFFss5V LPyPg0wE0t3eWmEw+O9/L57urNVu8B8iYgovSzX0yPpENEdSvnvD5opkGbhGp6YR E5jFeHvqe6ygGeJ0rZHhK79AQq1Jk4qGyfWQUlz0AnwiA1L7iU+0A3C13Sr3NAnA nwK4MPU2hg2fZouOZS1KPSmozu2i79Nr34TEhb/7grWrrU1T06nXc5AWqm3268gd RA5wb3NX8nj6TgG7TAslkWNRvBTICOU/cjz4Rs1Q== Received: from ppma22.wdc07v.mail.ibm.com (5c.69.3da9.ip4.static.sl-reverse.com [169.61.105.92]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 4f6qknqxcc-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 09 Jul 2026 07:04:37 +0000 (GMT) Received: from pps.filterd (ppma22.wdc07v.mail.ibm.com [127.0.0.1]) by ppma22.wdc07v.mail.ibm.com (8.18.1.7/8.18.1.7) with ESMTP id 66974aV2007343; Thu, 9 Jul 2026 07:04:37 GMT Received: from smtprelay05.fra02v.mail.ibm.com ([9.218.2.225]) by ppma22.wdc07v.mail.ibm.com (PPS) with ESMTPS id 4f7cvwc63n-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 09 Jul 2026 07:04:37 +0000 (GMT) Received: from smtpav02.fra02v.mail.ibm.com (smtpav02.fra02v.mail.ibm.com [10.20.54.101]) by smtprelay05.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 66974ZC148169416 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 9 Jul 2026 07:04:35 GMT Received: from smtpav02.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id F26FD2004F; Thu, 9 Jul 2026 07:04:34 +0000 (GMT) Received: from smtpav02.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id C8DCE2004B; Thu, 9 Jul 2026 07:04:34 +0000 (GMT) Received: from tuxmaker.linux.ibm.com (unknown [9.87.85.9]) by smtpav02.fra02v.mail.ibm.com (Postfix) with ESMTPS; Thu, 9 Jul 2026 07:04:34 +0000 (GMT) From: Sven Schnelle To: strace development discussions Cc: linux-kernel@vger.kernel.org, Renzo Davoli , Andrew Morton , Oleg Nesterov , Shuah Khan , Alexey Gladkov , Eugene Syromyatnikov , Davide Berardi , "Dmitry V . Levin" Subject: Re: [PATCH v2 1/5] ptrace: PTRACE_SET_SYSCALL_INFO syscall skipping support In-Reply-To: <20260703105027.539399-2-renzo@cs.unibo.it> References: <20260703105027.539399-1-renzo@cs.unibo.it> <20260703105027.539399-2-renzo@cs.unibo.it> Date: Thu, 09 Jul 2026 09:04:34 +0200 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain X-TM-AS-GCONF: 00 X-Proofpoint-Reinject: loops=2 maxloops=12 X-Authority-Analysis: v=2.4 cv=Q/XiJY2a c=1 sm=1 tr=0 ts=6a4f4806 cx=c_pps a=5BHTudwdYE3Te8bg5FgnPg==:117 a=5BHTudwdYE3Te8bg5FgnPg==:17 a=RAioF0-LDSMA:10 a=VkNPw1HP01LnGYTKEx00:22 a=RnoormkPH1_aCDwRdu11:22 a=Y2IxJ9c9Rs8Kov3niI8_:22 a=GaQpPoNlAAAA:8 a=R4YwnmPTE8QIeo7FXGYA:9 a=xF5q_uoM5gZT5J3czcBi:22 X-Proofpoint-GUID: FxsA0WcgabihMji_1OPd_9HcQfFEbn2E X-Proofpoint-ORIG-GUID: TRTWNj3uRFL9t44A0K84VH_ExydS_wB3 X-Proofpoint-Spam-Info: AW1haW4tMjYwNzA5MDA2MiBTYWx0ZWRfX0oZEyfxzVFxx NmtoYjT3KdJfqJoLupzlXhWsm1ZCSLQRz4BV6GfgQGxKjBxqoZUd5/OlOYTW+PLVsOGuEQftupo 2cIQ3WlQ/H8y/ZJ703EgYTHy7W4zfNo= X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNzA5MDA2MiBTYWx0ZWRfX9dfcbz/Vvt8M kfnjYWy+te3Y+N+j/THcEjessdzH54oZ60v2Vf1zwfKWoNPy0qAJW8nnbB5VsHDhfT0Op0++Nlc LGtSfJdDpWuzS/ZhCdbyAoH9pUbeshwP3OnoBlKYFAML1pSLcN7uqFt6UNlBp9rJI4EmduB5NnO 6HyZq3R1R7b7kbAqySIJwJqC8QAZRHhOcKu53D/hw3150sLLVkSVdn0U8PndUqPkEct8OLPFQ+S npVxIfB2fXkn1UELO2y4iX01jDkO6MYoKp7s1DqNwxZl1LdOVq1GBPdWUQHttR+tRUQTSbF39QP EWIymVT4JU4Wlje8SBhmKDxpKb6HMbnTq6OmeeWHGDJwVQomomoTOVWPZ8yQ0eDU0mAYgGFKspI xLKKj7Lk9phd9/sG6KRs0kS2uGlzWmKZGlzkKDl2iHnT7josWrj5LYdiklwXRW5f2p9teBV278k LIZJJFKTI57lWgO0nBQ== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.134,FMLib:17.12.100.49 definitions=2026-07-09_01,2026-07-08_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 adultscore=0 impostorscore=0 spamscore=0 phishscore=0 priorityscore=1501 bulkscore=0 clxscore=1011 lowpriorityscore=0 suspectscore=0 malwarescore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2607090062 Renzo Davoli writes: > This patch extends PTRACE_SET_SYSCALL_INFO with support for skipping a system > call triggered via seccomp. > > When the tracer retrieves a ptrace_syscall_info structure with > op == PTRACE_SYSCALL_INFO_SECCOMP, it may choose to skip the system > call by changing op to PTRACE_SYSCALL_INFO_EXIT and > populating the exit union fields (rval and is_error) to define > the return value and error status for the tracee. Is it possible to indicate the information whether the syscall should be skipped via a dedicated return value? There's currently work going on[1] to do this for seccomp, and it would be awkward if ptrace introduces this at the same time. At least for s390 this is problematic because it shares gprs[2] for both syscall number and return value, and if I read the thread correctly this also doesn't work for MIPS? [1] https://patchew.org/linux/akVRcPsD._5FR._5FCE1qW@kunlun.suse.cz/