public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Stefan Liebler <stli@linux.ibm.com>
To: GNU C Library <libc-alpha@sourceware.org>
Subject: Re: [PATCH] S390: Always use svc 0
Date: Tue, 30 Aug 2022 10:59:15 +0200	[thread overview]
Message-ID: <5b131123-c6ca-0914-8e88-951e04a0d3bb@linux.ibm.com> (raw)
In-Reply-To: <20220825101748.2658723-1-stli@linux.ibm.com>

On 25/08/2022 12:17, Stefan Liebler wrote:
> On s390x syscalls are triggered by svc instruction. One can
> pass the syscall number encoded in the instruction "svc 123"
> or by storing it in r1:
> lghi r1,123
> svc 0
> 
> If the syscall number is encoded in the instruction, this can
> cause broken syscall restarts.  Therefore this patch is now just
> passing the syscall number in r1.
> 
> See also kernel-commit:
> "s390/signal: switch to using vdso for sigreturn and syscall restart"
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/arch/s390/[%e2%80%a6]call.c?h=v6.0-rc1&id=df29a7440c4b5c65765c8f60396b3b13063e24e9
> 
> As information, the "svc 0" feature was introduced in kernel 2.5.62:
> commit b5aad611393ef2e132e3648fa4c6e56a9cfa8708
> ---
>  sysdeps/unix/sysv/linux/s390/s390-32/clone.S  | 14 ++++----
>  .../unix/sysv/linux/s390/s390-32/getcontext.S |  8 +++--
>  .../unix/sysv/linux/s390/s390-32/setcontext.S |  8 +++--
>  .../sysv/linux/s390/s390-32/swapcontext.S     |  3 +-
>  sysdeps/unix/sysv/linux/s390/s390-32/sysdep.h |  4 ---
>  sysdeps/unix/sysv/linux/s390/s390-32/vfork.S  |  3 +-
>  sysdeps/unix/sysv/linux/s390/s390-64/clone.S  | 14 ++++----
>  .../unix/sysv/linux/s390/s390-64/getcontext.S |  8 +++--
>  .../unix/sysv/linux/s390/s390-64/setcontext.S |  8 +++--
>  .../sysv/linux/s390/s390-64/swapcontext.S     |  3 +-
>  sysdeps/unix/sysv/linux/s390/s390-64/sysdep.h |  4 ---
>  sysdeps/unix/sysv/linux/s390/s390-64/vfork.S  |  3 +-
>  sysdeps/unix/sysv/linux/s390/sysdep.h         | 32 ++-----------------
>  13 files changed, 46 insertions(+), 66 deletions(-)
> 
Committed

      reply	other threads:[~2022-08-30  8:59 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-25 10:17 Stefan Liebler
2022-08-30  8:59 ` Stefan Liebler [this message]

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=5b131123-c6ca-0914-8e88-951e04a0d3bb@linux.ibm.com \
    --to=stli@linux.ibm.com \
    --cc=libc-alpha@sourceware.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).