mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Arnd Bergmann" <arnd@arndb.de>
To: "André Almeida" <andrealmeid@igalia.com>,
	"Thomas Gleixner" <tglx@kernel.org>,
	"Nathan Chancellor" <nathan@kernel.org>,
	"Masami Hiramatsu" <mhiramat@kernel.org>
Cc: linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org,
	kernel-dev@igalia.com
Subject: Re: [PATCH RFC v3 2/8] syscalls: Create unified partial table for all archs
Date: Fri, 07 Aug 2026 22:40:50 +0200	[thread overview]
Message-ID: <fc9361d7-2505-4ec7-9d47-966b4f5a9fc2@app.fastmail.com> (raw)
In-Reply-To: <20260807-tonyk-syscall_table-v3-2-7c45a23c50b5@igalia.com>

On Fri, Aug 7, 2026, at 21:34, André Almeida wrote:
> To take advantage of the subset of syscall numbers that are guaranteed to
> be shared, create a new table and adapt generation scripts to use it. In
> that way, every new syscall can be added to a single file.
>
> Create special ABIs in order to make the table work for different archs:
>
>  - `memfd_secret` for archs that implements it

This was already there, so it's not really a new addition. We could
also avoid this entirely and just rely on the stub implementation
from kernel/sys_ni.c for those architectures that don't need it.
They still get the macro definition, but it should be fine to define
that for everyone.

>  - `cln3` for archs that use the common clone3 entry
>  - `__cln3` for archs that use their own special entry point

I guess that's one way to do it. I would probably use the full
clone3/__clone3 name here for consistency.

> Some archs only care about the native entry point and have no compat, so
> create a option to never generate __SYSCALL_WITH_COMPAT() and always
> generate __SYSCALL().

I don't see the purpose of this and would prefer to not add that
extra option if the scripts works fine without it.

>  usage() {
> -	echo >&2 "usage: $0 [--abis ABIS] [--emit-nr] [--offset OFFSET] 
> [--prefix PREFIX] INFILE OUTFILE" >&2
> +	echo >&2 "usage: $0 [--abis ABIS] [--emit-nr] [--offset OFFSET] 
> [--prefix PREFIX] [--common-tbl] INFILE OUTFILE" >&2

This needs to be changed to include the argument of common-tbl

> diff --git a/scripts/syscalltbl.sh b/scripts/syscalltbl.sh
> index c4b1f85c2dd6..c0fd6af2d892 100755
> --- a/scripts/syscalltbl.sh
> +++ b/scripts/syscalltbl.sh
> @@ -16,18 +16,23 @@
>  set -e
> 
>  usage() {
> -	echo >&2 "usage: $0 [--abis ABIS] INFILE OUTFILE" >&2
> +	echo >&2 "usage: $0 [--abis ABIS] [--common-tbl] [--no-compat] INFILE 

same here

     Arnd

  reply	other threads:[~2026-08-07 20:41 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-07 19:34 [PATCH RFC v3 0/8] syscalls: Add a shared " André Almeida
2026-08-07 19:34 ` [PATCH RFC v3 1/8] syscalls: Make --abis parsing more robust André Almeida
2026-08-07 19:34 ` [PATCH RFC v3 2/8] syscalls: Create unified partial table for all archs André Almeida
2026-08-07 20:40   ` Arnd Bergmann [this message]
2026-08-10 13:19     ` André Almeida
2026-08-10 14:22       ` Arnd Bergmann
2026-08-07 19:34 ` [PATCH RFC v3 3/8] scripts/syscall.tbl: Use the common table André Almeida
2026-08-07 19:34 ` [PATCH RFC v3 4/8] arm: Use the common syscall table André Almeida
2026-08-07 19:34 ` [PATCH RFC v3 5/8] s390: " André Almeida
2026-08-07 19:34 ` [PATCH RFC v3 6/8] sparc: " André Almeida
2026-08-07 19:34 ` [PATCH RFC v3 7/8] mips: Remove duplicated syscallnr.sh André Almeida
2026-08-07 19:34 ` [PATCH RFC v3 8/8] mips: Use the common syscall table André Almeida
2026-08-07 21:02   ` Arnd Bergmann
2026-08-10 13:20     ` André Almeida
2026-08-07 20:43 ` [PATCH RFC v3 0/8] syscalls: Add a shared table for all archs Arnd Bergmann
2026-08-10 13:25   ` André Almeida
2026-08-10 14:18     ` Arnd Bergmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fc9361d7-2505-4ec7-9d47-966b4f5a9fc2@app.fastmail.com \
    --to=arnd@arndb.de \
    --cc=andrealmeid@igalia.com \
    --cc=kernel-dev@igalia.com \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mhiramat@kernel.org \
    --cc=nathan@kernel.org \
    --cc=tglx@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®