| Message ID | 20260828-tonyk-syscall_table-v6-1-fdd358456cf1@igalia.com |
|---|---|
| State | New |
| Headers | show
Return-Path: <SRS0=mkse=GV=vger.kernel.org=sparclinux+bounces-7308-patchwork-incoming=ozlabs.org@ozlabs.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=igalia.com header.i=@igalia.com header.a=rsa-sha256 header.s=20170329 header.b=kApnQbtQ; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=ozlabs.org (client-ip=2404:9400:2221:ea00::3; helo=mail.ozlabs.org; envelope-from=srs0=mkse=gv=vger.kernel.org=sparclinux+bounces-7308-patchwork-incoming=ozlabs.org@ozlabs.org; receiver=patchwork.ozlabs.org) Received: from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (secp384r1 raw public key) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4hWvWM4Y4bz1xpY for <incoming@patchwork.ozlabs.org>; Sat, 29 Aug 2026 09:20:31 +1000 (AEST) Received: from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by gandalf.ozlabs.org (Postfix) with ESMTP id 4hWvWM3lQ0z4w9h for <incoming@patchwork.ozlabs.org>; Sat, 29 Aug 2026 09:20:31 +1000 (AEST) Received: by gandalf.ozlabs.org (Postfix) id 4hWvWM3gkTz4w9r; Sat, 29 Aug 2026 09:20:31 +1000 (AEST) Delivered-To: patchwork-incoming@ozlabs.org Authentication-Results: gandalf.ozlabs.org; arc=pass smtp.remote-ip=172.234.253.10 arc.chain=subspace.kernel.org ARC-Seal: i=2; a=rsa-sha256; d=ozlabs.org; s=201707; t=1787959231; cv=pass; b=CoaRWyWBaRQMk3qZ1KH3KARyr2s6NI4QJuWBdLCfjMKHoX5UOTMjekQXDwkqV1pckRIZRINUHeR5i0UgDAwXQs6zQOA+FpdN9h04QXjimZEvAwywTxFZ56KL7nI1baG7j5kKRw6pKvtJhfcJgm61BA/5LTHRarDjjjMltuf+u5Cqr3TeSCcW1RxoHiw+76sbH8zxCclSDqgSns/Jw6lDuef2CigmgQKeSMCJn+QQbcGvbxz/H1ZV/4LXwELWfiqLq0PDhEWPXcQA/WDiHs5DdCjFcu2tTdvaoy1Sc8+nwxP4/uyugVHJbFTtmoWzbr3EwcZ7EvhiNgG6hXWIgEaNag== ARC-Message-Signature: i=2; a=rsa-sha256; d=ozlabs.org; s=201707; t=1787959231; c=relaxed/relaxed; bh=1Mqf8IivruERMP6fZwT8V4CKtJjvaF7LKzl37WPzoRE=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=bKP4kLsaciOFav/4X5PZu5MtciqaHGGgUYc+7X3qVnXonVETIm18bIM7bYjmFVrdyPYeVLLpRRBEw/SLEQUnCxLTvGwAhBhRisA5liEnYrEUl5PljFQlO5q05aHaAKocGY0l36jFdc/KK76DW5PkQS0BCJIq5Yu0CCDYCFC17NyWBqaMwYsHBz9EPMVj8nK+qyQWxPhpb330y/XLxtxjrG21gKbaN/GRFkjVWkqKA7REDuDUa9WenXVoyT+LKLFwwauAwmFx7mn/ujKC6/U8/cq5nDkZInCPSgVu5MicTPvRF97IocYqBX/9nxRUbspBRofchy+YGnWRur+gmSjzIw== ARC-Authentication-Results: i=2; gandalf.ozlabs.org; dmarc=pass (p=none dis=none) header.from=igalia.com; dkim=pass (2048-bit key; unprotected) header.d=igalia.com header.i=@igalia.com header.a=rsa-sha256 header.s=20170329 header.b=kApnQbtQ; dkim-atps=neutral; spf=pass (client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=sparclinux+bounces-7308-patchwork-incoming=ozlabs.org@vger.kernel.org; receiver=ozlabs.org) smtp.mailfrom=vger.kernel.org Authentication-Results: gandalf.ozlabs.org; dmarc=pass (p=none dis=none) header.from=igalia.com Authentication-Results: gandalf.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=igalia.com header.i=@igalia.com header.a=rsa-sha256 header.s=20170329 header.b=kApnQbtQ; dkim-atps=neutral Authentication-Results: gandalf.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=sparclinux+bounces-7308-patchwork-incoming=ozlabs.org@vger.kernel.org; receiver=ozlabs.org) Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by gandalf.ozlabs.org (Postfix) with ESMTPS id 4hWvWJ1LJmz4w9h for <patchwork-incoming@ozlabs.org>; Sat, 29 Aug 2026 09:20:28 +1000 (AEST) Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.90.174.1]) by sea.lore.kernel.org (Postfix) with ESMTP id 647BB30B71D5 for <patchwork-incoming@ozlabs.org>; Fri, 28 Aug 2026 23:19:56 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 4460139A7E5; Fri, 28 Aug 2026 23:19:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=igalia.com header.i=@igalia.com header.b="kApnQbtQ" X-Original-To: sparclinux@vger.kernel.org Received: from fanzine2.igalia.com (fanzine2.igalia.com [213.97.179.56]) (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 70E7D38AC88; Fri, 28 Aug 2026 23:19:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=213.97.179.56 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787959195; cv=none; b=S7nFRsBGApKq5STnLSrkXSclCew+F59mYplVlAYtn6V5QazPjsUxxW7qzN5e06a2F00jphJIzrqDxvi4yvgEcwPKmjVYUaBijIeiBtC0Pz+BJciM0OmDBgD92o+zbvUZieOMSUBkqcu1imYE2o3Bmvyh/lS87qw0Dvhly/mhYjc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787959195; c=relaxed/simple; bh=voYeUFRGxJF51AdGg0Ie0IWOP6zIt8JXqOyKZWKsO3I=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=U1OIxiv69q2Y9lcp1eMnuAWTNWcnor39z6mly4bCq7/aO/sSm2vl2NbW28bEf9BugOfSrE6U2kUxfRxckzG7wB0BWCinL9DxSXpT6ZkkeSt54xNoNY6oMWmzGKI9G65GWm3zuaxdva/4o0OqqC3t8TGbfh+3ji7HIhImg0uGFIM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=igalia.com; spf=pass smtp.mailfrom=igalia.com; dkim=pass (2048-bit key) header.d=igalia.com header.i=@igalia.com header.b=kApnQbtQ; arc=none smtp.client-ip=213.97.179.56 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=igalia.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=igalia.com DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com; s=20170329; h=Cc:To:Message-Id:Content-Transfer-Encoding:Content-Type: MIME-Version:Subject:Date:From:From:Reply-To; bh=1Mqf8IivruERMP6fZwT8V4CKtJjvaF7LKzl37WPzoRE=; b=kApnQbtQ+Dg617qrBmTZu5xy5f Lbnimg8N/l8V7rNCeFVbJcEP8p7rAPDFM6+FLM1MLpk3/R2s/wGdqxGk+JMY2Cbq1i732NZEEEeAi fFw07E+np24+TEJZCvkt3IqkU9W6gSieQ7X19bnMSFcmZxaqrNSv6aVoN9q081NBZK+pQDxhyv/KF PWWNev7hAPz9ckok7XW+BdFezFHo5Yzo4s5EuYxVB0UXOUCcG1bhVP69cxpgCtD/BbrSrsj24TjyS C6T1hVi66MJhPhLp79eAkl5A7zvOexdz/lccuiuAKAAz+dOHdfSUm3/OugLnUjolODZdMyQMM31Tq RkhkZoZw==; Received: from [187.57.78.212] (helo=[192.168.15.100]) by fanzine2.igalia.com with esmtpsa (Cipher TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim) id 1x05rM-00B3sF-2z; Sat, 29 Aug 2026 01:19:44 +0200 From: =?utf-8?q?Andr=C3=A9_Almeida?= <andrealmeid@igalia.com> Date: Fri, 28 Aug 2026 20:19:28 -0300 Subject: [PATCH v6 01/13] syscalls: Make --abis parsing more robust Precedence: bulk X-Mailing-List: sparclinux@vger.kernel.org List-Id: <sparclinux.vger.kernel.org> List-Subscribe: <mailto:sparclinux+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:sparclinux+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Message-Id: <20260828-tonyk-syscall_table-v6-1-fdd358456cf1@igalia.com> References: <20260828-tonyk-syscall_table-v6-0-fdd358456cf1@igalia.com> In-Reply-To: <20260828-tonyk-syscall_table-v6-0-fdd358456cf1@igalia.com> To: Masami Hiramatsu <mhiramat@kernel.org>, Arnd Bergmanon <arnd@arndb.de> Cc: Christian Brauner <brauner@kernel.org>, linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org, kernel-dev@igalia.com, Thomas Bogendoerfer <tsbogend@alpha.franken.de>, linux-alpha@vger.kernel.org, linux-s390@vger.kernel.org, linux-arm-kernel@lists.infradead.org, soc@lists.linux.dev, linux-mips@vger.kernel.org, sparclinux@vger.kernel.org, =?utf-8?q?Andr?= =?utf-8?q?=C3=A9_Almeida?= <andrealmeid@igalia.com> X-Mailer: b4 0.15.2 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DMARC_PASS,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=disabled version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on gandalf.ozlabs.org |
| Series |
syscalls: Add a shared table for all archs
|
expand
|
diff --git a/scripts/syscallhdr.sh b/scripts/syscallhdr.sh index 22e34cd46b9b..bad1ab606a0f 100755 --- a/scripts/syscallhdr.sh +++ b/scripts/syscallhdr.sh @@ -39,7 +39,7 @@ while [ $# -gt 0 ] do case $1 in --abis) - abis=$(echo "($2)" | tr ',' '|') + abis="($(echo "${2%,}" | tr ',' '|'))" shift 2;; --emit-nr) emit_nr=1 diff --git a/scripts/syscalltbl.sh b/scripts/syscalltbl.sh index 6a903b87a7c2..c4b1f85c2dd6 100755 --- a/scripts/syscalltbl.sh +++ b/scripts/syscalltbl.sh @@ -33,7 +33,7 @@ while [ $# -gt 0 ] do case $1 in --abis) - abis=$(echo "($2)" | tr ',' '|') + abis="($(echo "${2%,}" | tr ',' '|'))" shift 2;; -*) echo "$1: unknown option" >&2
Some archs Makefile have something like this as the rule for making the syscall files: cmd_systbl = $(CONFIG_SHELL) $(systbl) --abis common,$* $< $@ The $* symbol is evaluated to the variable found at $(uapi)/unistd-%.h, where % is 32 or 64, resulting in e.g. `--abis common,32`. Sometimes the rule for the file won't have a %, resulting in a trailing comma e.g. `--abis common,`. Currently this input is transformed into (common|). This is problematic because grep will then match any ABI because of the trailing `|`. Make the syscalls scripts more robust by removing any trailing comma. Signed-off-by: André Almeida <andrealmeid@igalia.com> --- scripts/syscallhdr.sh | 2 +- scripts/syscalltbl.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)