This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 3/5] sysvipc: Consolidate semtimedop s390
On Fri, May 17, 2019 at 2:30 PM Adhemerval Zanella
<adhemerval.zanella@linaro.org> wrote:
> > Il giorno 17 mag 2019, alle ore 06:13, Florian Weimer <fweimer@redhat.com> ha scritto:
> >
> > * Adhemerval Zanella:
> >
> >>> On 16/05/2019 12:41, Florian Weimer wrote:
> >>> * Adhemerval Zanella:
> >>>
> >>>> diff --git a/sysdeps/unix/sysv/linux/ipc_priv.h b/sysdeps/unix/sysv/linux/ipc_priv.h
> >>>> index 65adbb093e..49018c1b28 100644
> >>>> --- a/sysdeps/unix/sysv/linux/ipc_priv.h
> >>>> +++ b/sysdeps/unix/sysv/linux/ipc_priv.h
> >>>> @@ -34,4 +34,7 @@ struct __old_ipc_perm
> >>>> #define MSGRCV_ARGS(__msgp, __msgtyp) \
> >>>> ((long int []){ (long int) __msgp, __msgtyp })
> >>>>
> >>>> +#define SEMTIMEDOP_IPC_ARGS(__nsops, __sops, __timeout) \
> >>>> + (__nsops), 0, (__sops), (__timeout)
> >>>
> >>> Maybe add a reference to the s390 version?
> >>
> >> What about:
> >>
> >> /* This macro is required to handle the s390 variants, which passes the
> >> arguments in a different order than default. */
> >
> > Isn't this for s390 (31-bit) only?
> >
>
> Indeed, I will change to “s390-32 variant”.
According to the kernel sources, the odd sys_s390_ipc function is
used in both native 64-bit and compat 32-bit variants. The 64-bit
s390 ABI also started out with a maximum of five arguments,
so the wrapper was kept there, see:
arch/s390/kernel/syscalls/syscall.tbl:117 common ipc
sys_s390_ipc compat_sys_s390_ipc
Arnd