mailing list of musl libc
 help / color / mirror / code / Atom feed
* [musl] [PATCH] riscv: Rename __NR_fstatat __NR_newfstatat
@ 2021-05-19  7:34 Khem Raj
  2021-05-19  7:54 ` Arnd Bergmann
  2021-06-05  5:05 ` [musl] " Khem Raj
  0 siblings, 2 replies; 5+ messages in thread
From: Khem Raj @ 2021-05-19  7:34 UTC (permalink / raw)
  To: musl; +Cc: Khem Raj, zabolcs Nagy

on riscv64 this syscall is called __NR_newfstatat
this helps the name match kernel UAPI for external
programs

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Cc: zabolcs Nagy <nsz@port70.net>
---
 arch/riscv64/bits/syscall.h.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/riscv64/bits/syscall.h.in b/arch/riscv64/bits/syscall.h.in
index f9c421d0..39c0d650 100644
--- a/arch/riscv64/bits/syscall.h.in
+++ b/arch/riscv64/bits/syscall.h.in
@@ -76,7 +76,7 @@
 #define __NR_splice 76
 #define __NR_tee 77
 #define __NR_readlinkat 78
-#define __NR_fstatat 79
+#define __NR_newfstatat 79
 #define __NR_fstat 80
 #define __NR_sync 81
 #define __NR_fsync 82
-- 
2.31.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [musl] [PATCH] riscv: Rename __NR_fstatat __NR_newfstatat
  2021-05-19  7:34 [musl] [PATCH] riscv: Rename __NR_fstatat __NR_newfstatat Khem Raj
@ 2021-05-19  7:54 ` Arnd Bergmann
  2021-06-05  5:05 ` [musl] " Khem Raj
  1 sibling, 0 replies; 5+ messages in thread
From: Arnd Bergmann @ 2021-05-19  7:54 UTC (permalink / raw)
  To: musl; +Cc: Khem Raj, zabolcs Nagy

On Wed, May 19, 2021 at 9:34 AM Khem Raj <raj.khem@gmail.com> wrote:
>
> on riscv64 this syscall is called __NR_newfstatat
> this helps the name match kernel UAPI for external
> programs
>
> Signed-off-by: Khem Raj <raj.khem@gmail.com>
> Cc: zabolcs Nagy <nsz@port70.net>

This looks correct to me. Unfortunately the kernel's definitions for the stat
family are inconsistent in a lot of different ways, and the naming between
fstat and newfstatat is just one more instance of this. In theory, the 'new'
macros refer to the kernel's "struct stat", while the non-prefixed ones
refer to the syscalls taking "struct __kernel_old_stat".

Comparing the riscv64 file to the aarch64 version shows that the aarch64
version matches what the kernel defines, no idea why the riscv64 version
is different.

       Arnd

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [musl] Re: [PATCH] riscv: Rename __NR_fstatat __NR_newfstatat
  2021-05-19  7:34 [musl] [PATCH] riscv: Rename __NR_fstatat __NR_newfstatat Khem Raj
  2021-05-19  7:54 ` Arnd Bergmann
@ 2021-06-05  5:05 ` Khem Raj
  2021-06-05  8:47   ` Szabolcs Nagy
  1 sibling, 1 reply; 5+ messages in thread
From: Khem Raj @ 2021-06-05  5:05 UTC (permalink / raw)
  To: musl; +Cc: zabolcs Nagy

ping

On Wed, May 19, 2021 at 12:34 AM Khem Raj <raj.khem@gmail.com> wrote:
>
> on riscv64 this syscall is called __NR_newfstatat
> this helps the name match kernel UAPI for external
> programs
>
> Signed-off-by: Khem Raj <raj.khem@gmail.com>
> Cc: zabolcs Nagy <nsz@port70.net>
> ---
>  arch/riscv64/bits/syscall.h.in | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/riscv64/bits/syscall.h.in b/arch/riscv64/bits/syscall.h.in
> index f9c421d0..39c0d650 100644
> --- a/arch/riscv64/bits/syscall.h.in
> +++ b/arch/riscv64/bits/syscall.h.in
> @@ -76,7 +76,7 @@
>  #define __NR_splice 76
>  #define __NR_tee 77
>  #define __NR_readlinkat 78
> -#define __NR_fstatat 79
> +#define __NR_newfstatat 79
>  #define __NR_fstat 80
>  #define __NR_sync 81
>  #define __NR_fsync 82
> --
> 2.31.1
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [musl] Re: [PATCH] riscv: Rename __NR_fstatat __NR_newfstatat
  2021-06-05  5:05 ` [musl] " Khem Raj
@ 2021-06-05  8:47   ` Szabolcs Nagy
  2021-06-05 15:47     ` Rich Felker
  0 siblings, 1 reply; 5+ messages in thread
From: Szabolcs Nagy @ 2021-06-05  8:47 UTC (permalink / raw)
  To: Khem Raj; +Cc: musl

* Khem Raj <raj.khem@gmail.com> [2021-06-04 22:05:21 -0700]:
> ping
> 
> On Wed, May 19, 2021 at 12:34 AM Khem Raj <raj.khem@gmail.com> wrote:
> > on riscv64 this syscall is called __NR_newfstatat
> > this helps the name match kernel UAPI for external
> > programs
> >
> > Signed-off-by: Khem Raj <raj.khem@gmail.com>
> > Cc: zabolcs Nagy <nsz@port70.net>

looks correct to me too.

> > ---
> >  arch/riscv64/bits/syscall.h.in | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/arch/riscv64/bits/syscall.h.in b/arch/riscv64/bits/syscall.h.in
> > index f9c421d0..39c0d650 100644
> > --- a/arch/riscv64/bits/syscall.h.in
> > +++ b/arch/riscv64/bits/syscall.h.in
> > @@ -76,7 +76,7 @@
> >  #define __NR_splice 76
> >  #define __NR_tee 77
> >  #define __NR_readlinkat 78
> > -#define __NR_fstatat 79
> > +#define __NR_newfstatat 79
> >  #define __NR_fstat 80
> >  #define __NR_sync 81
> >  #define __NR_fsync 82
> > --
> > 2.31.1
> >

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [musl] Re: [PATCH] riscv: Rename __NR_fstatat __NR_newfstatat
  2021-06-05  8:47   ` Szabolcs Nagy
@ 2021-06-05 15:47     ` Rich Felker
  0 siblings, 0 replies; 5+ messages in thread
From: Rich Felker @ 2021-06-05 15:47 UTC (permalink / raw)
  To: musl; +Cc: Khem Raj

On Sat, Jun 05, 2021 at 10:47:54AM +0200, Szabolcs Nagy wrote:
> * Khem Raj <raj.khem@gmail.com> [2021-06-04 22:05:21 -0700]:
> > ping
> > 
> > On Wed, May 19, 2021 at 12:34 AM Khem Raj <raj.khem@gmail.com> wrote:
> > > on riscv64 this syscall is called __NR_newfstatat
> > > this helps the name match kernel UAPI for external
> > > programs
> > >
> > > Signed-off-by: Khem Raj <raj.khem@gmail.com>
> > > Cc: zabolcs Nagy <nsz@port70.net>
> 
> looks correct to me too.
> 
> > > ---
> > >  arch/riscv64/bits/syscall.h.in | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/arch/riscv64/bits/syscall.h.in b/arch/riscv64/bits/syscall.h.in
> > > index f9c421d0..39c0d650 100644
> > > --- a/arch/riscv64/bits/syscall.h.in
> > > +++ b/arch/riscv64/bits/syscall.h.in
> > > @@ -76,7 +76,7 @@
> > >  #define __NR_splice 76
> > >  #define __NR_tee 77
> > >  #define __NR_readlinkat 78
> > > -#define __NR_fstatat 79
> > > +#define __NR_newfstatat 79
> > >  #define __NR_fstat 80
> > >  #define __NR_sync 81
> > >  #define __NR_fsync 82
> > > --
> > > 2.31.1
> > >

Thanks, applying.

Rich

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-06-05 15:48 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-19  7:34 [musl] [PATCH] riscv: Rename __NR_fstatat __NR_newfstatat Khem Raj
2021-05-19  7:54 ` Arnd Bergmann
2021-06-05  5:05 ` [musl] " Khem Raj
2021-06-05  8:47   ` Szabolcs Nagy
2021-06-05 15:47     ` Rich Felker

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

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 NNTP newsgroup(s).