unofficial mirror of libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Adhemerval Zanella Netto via Libc-alpha <libc-alpha@sourceware.org>
To: Xi Ruoyao <xry111@xry111.site>, Xing Li <lixing@loongson.cn>
Cc: libc-alpha@sourceware.org, i.swmail@xen0n.name,
	caiyinyu@loongson.cn, wanghongliang@loongson.cn,
	hejinyang@loongson.cn
Subject: Re: [PATCH] LoongArch: Add syscall.c for getting correct return value
Date: Wed, 23 Nov 2022 10:36:50 -0300	[thread overview]
Message-ID: <95f208a9-92aa-bf29-036e-5ae7a4556195@linaro.org> (raw)
In-Reply-To: <bab7b718cef2801c025840de95e2150ace705da0.camel@xry111.site>



On 23/11/22 00:40, Xi Ruoyao wrote:
> On Wed, 2022-11-23 at 09:57 +0800, Xing Li wrote:
>> The __SYS_mmap syscall should return 47bits value. If we use
>> the common syscall interface which defined in
>> sysdeps/unix/sysv/linux/syscall.c, the syscall return value
>> is 32bits with sign extend, which lead to mmap failure.
> 
> Could we just change
> 
> int r = INTERNAL_SYSCALL_NCS_CALL (number, a0, a1, a2, a3, a4, a5);
> 
> in sysdeps/unix/sysv/linux/syscall.c to "long r = ..." instead?
> 

Yes, afaik INTERNAL_SYSCALL_NCS on all architecture returns long int.

  reply	other threads:[~2022-11-23 13:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-23  1:57 [PATCH] LoongArch: Add syscall.c for getting correct return value Xing Li
2022-11-23  3:40 ` Xi Ruoyao via Libc-alpha
2022-11-23 13:36   ` Adhemerval Zanella Netto via Libc-alpha [this message]
2022-11-25  2:37     ` XingLi

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

  List information: https://www.gnu.org/software/libc/involved.html

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

  git send-email \
    --in-reply-to=95f208a9-92aa-bf29-036e-5ae7a4556195@linaro.org \
    --to=libc-alpha@sourceware.org \
    --cc=adhemerval.zanella@linaro.org \
    --cc=caiyinyu@loongson.cn \
    --cc=hejinyang@loongson.cn \
    --cc=i.swmail@xen0n.name \
    --cc=lixing@loongson.cn \
    --cc=wanghongliang@loongson.cn \
    --cc=xry111@xry111.site \
    /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).