Re: [PATCH v2] arch: Reserve map_shadow_stack() syscall number for all architectures
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- To: "Sohil Mehta" <sohil.mehta@xxxxxxxxx>, linux-api@xxxxxxxxxxxxxxx, Linux-Arch <linux-arch@xxxxxxxxxxxxxxx>
- Subject: Re: [PATCH v2] arch: Reserve map_shadow_stack() syscall number for all architectures
- From: "Arnd Bergmann" <arnd@xxxxxxxx>
- Date: Tue, 03 Oct 2023 18:54:59 +0200
- Cc: "Richard Henderson" <richard.henderson@xxxxxxxxxx>, "Ivan Kokshaysky" <ink@xxxxxxxxxxxxxxxxxxxx>, "Matt Turner" <mattst88@xxxxxxxxx>, "Russell King" <linux@xxxxxxxxxxxxxxx>, "Catalin Marinas" <catalin.marinas@xxxxxxx>, "Will Deacon" <will@xxxxxxxxxx>, "Geert Uytterhoeven" <geert@xxxxxxxxxxxxxx>, "Michal Simek" <monstr@xxxxxxxxx>, "Thomas Bogendoerfer" <tsbogend@xxxxxxxxxxxxxxxx>, "James E . J . Bottomley" <James.Bottomley@xxxxxxxxxxxxxxxxxxxxx>, "Helge Deller" <deller@xxxxxx>, "Michael Ellerman" <mpe@xxxxxxxxxxxxxx>, "Nicholas Piggin" <npiggin@xxxxxxxxx>, "Christophe Leroy" <christophe.leroy@xxxxxxxxxx>, "Heiko Carstens" <hca@xxxxxxxxxxxxx>, "Vasily Gorbik" <gor@xxxxxxxxxxxxx>, "Alexander Gordeev" <agordeev@xxxxxxxxxxxxx>, "Christian Borntraeger" <borntraeger@xxxxxxxxxxxxx>, "Sven Schnelle" <svens@xxxxxxxxxxxxx>, "Yoshinori Sato" <ysato@xxxxxxxxxxxxx>, "Rich Felker" <dalias@xxxxxxxx>, "John Paul Adrian Glaubitz" <glaubitz@xxxxxxxxxxxxxxxxxxx>, "David S . Miller" <davem@xxxxxxxxxxxxx>, "Andy Lutomirski" <luto@xxxxxxxxxx>, "Thomas Gleixner" <tglx@xxxxxxxxxxxxx>, "Ingo Molnar" <mingo@xxxxxxxxxx>, "Borislav Petkov" <bp@xxxxxxxxx>, "Dave Hansen" <dave.hansen@xxxxxxxxxxxxxxx>, x86@xxxxxxxxxx, "H. Peter Anvin" <hpa@xxxxxxxxx>, "Chris Zankel" <chris@xxxxxxxxxx>, "Max Filippov" <jcmvbkbc@xxxxxxxxx>, "Peter Zijlstra" <peterz@xxxxxxxxxxxxx>, "Arnaldo Carvalho de Melo" <acme@xxxxxxxxxx>, "Mark Rutland" <mark.rutland@xxxxxxx>, "Alexander Shishkin" <alexander.shishkin@xxxxxxxxxxxxxxx>, "Jiri Olsa" <jolsa@xxxxxxxxxx>, "Namhyung Kim" <namhyung@xxxxxxxxxx>, "Ian Rogers" <irogers@xxxxxxxxxx>, "Adrian Hunter" <adrian.hunter@xxxxxxxxx>, "Lukas Bulwahn" <lukas.bulwahn@xxxxxxxxx>, "Sergei Trofimovich" <slyich@xxxxxxxxx>, "Andrew Morton" <akpm@xxxxxxxxxxxxxxxxxxxx>, "Rohan McLure" <rmclure@xxxxxxxxxxxxx>, "Andreas Schwab" <schwab@xxxxxxxxxxxxxx>, "Eric W. Biederman" <ebiederm@xxxxxxxxxxxx>, "Brian Gerst" <brgerst@xxxxxxxxx>, "Randy Dunlap" <rdunlap@xxxxxxxxxxxxx>, "Rick Edgecombe" <rick.p.edgecombe@xxxxxxxxx>, "Mark Brown" <broonie@xxxxxxxxxx>, "Deepak Gupta" <debug@xxxxxxxxxxxx>, linux-alpha@xxxxxxxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx, linux-arm-kernel@xxxxxxxxxxxxxxxxxxx, linux-ia64@xxxxxxxxxxxxxxx, linux-m68k@xxxxxxxxxxxxxxx, linux-mips@xxxxxxxxxxxxxxx, linux-parisc@xxxxxxxxxxxxxxx, linuxppc-dev@xxxxxxxxxxxxxxxx, linux-s390@xxxxxxxxxxxxxxx, linux-sh@xxxxxxxxxxxxxxx, sparclinux@xxxxxxxxxxxxxxx, linux-perf-users@xxxxxxxxxxxxxxx
- Feedback-id: i56a14606:Fastmail
- In-reply-to: <487836fc-7c9f-2662-66a4-fa5e3829cf6b@intel.com>
- References: <20230914185804.2000497-1-sohil.mehta@intel.com> <487836fc-7c9f-2662-66a4-fa5e3829cf6b@intel.com>
- User-agent: Cyrus-JMAP/3.9.0-alpha0-958-g1b1b911df8-fm-20230927.002-g1b1b911d
On Tue, Oct 3, 2023, at 18:35, Sohil Mehta wrote:
> On 9/14/2023 11:58 AM, Sohil Mehta wrote:
>> commit c35559f94ebc ("x86/shstk: Introduce map_shadow_stack syscall")
>> recently added support for map_shadow_stack() but it is limited to x86
>> only for now. There is a possibility that other architectures (namely,
>> arm64 and RISC-V), that are implementing equivalent support for shadow
>> stacks, might need to add support for it.
>>
>> Independent of that, reserving arch-specific syscall numbers in the
>> syscall tables of all architectures is good practice and would help
>> avoid future conflicts. map_shadow_stack() is marked as a conditional
>> syscall in sys_ni.c. Adding it to the syscall tables of other
>> architectures is harmless and would return ENOSYS when exercised.
>>
>> Note, map_shadow_stack() was assigned #453 during the merge process
>> since #452 was taken by fchmodat2().
>>
>> For Powerpc, map it to sys_ni_syscall() as is the norm for Powerpc
>> syscall tables.
>>
>> For Alpha, map_shadow_stack() takes up #563 as Alpha still diverges from
>> the common syscall numbering system in the other architectures.
>>
>> Link: https://lore.kernel.org/lkml/20230515212255.GA562920@xxxxxxxxxxxxxxxxxxxxx/
>> Link: https://lore.kernel.org/lkml/b402b80b-a7c6-4ef0-b977-c0f5f582b78a@xxxxxxxxxxxxx/
>>
>> Signed-off-by: Sohil Mehta <sohil.mehta@xxxxxxxxx>
>> ---
>
> Gentle ping...
>
> Are there any additional comments? It applies cleanly on 6.6-rc4.
>
> Or does it seem ready to be merged? It has the following
> acknowledgements until now:
>
> Reviewed-by: Rick Edgecombe <rick.p.edgecombe@xxxxxxxxx>
> Acked-by: Michael Ellerman <mpe@xxxxxxxxxxxxxx> (powerpc)
>
Reviewed-by: Arnd Bergmann <arnd@xxxxxxxx>
If you like, I can pick this up for 6.7 through the asm-generic
tree. If you think this should be part of 6.6, I would suggest
to merge it through the tree that originally contained the
syscall code.
Arnd
[Index of Archives]
[Linux Kernel]
[Sparc Linux]
[DCCP]
[Linux ARM]
[Yosemite News]
[Linux SCSI]
[Linux x86_64]
[Linux for Ham Radio]