This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug network/19682] New: s390x: Incorrect syscall definitions cause breakage with Linux 4.3 headers


https://sourceware.org/bugzilla/show_bug.cgi?id=19682

            Bug ID: 19682
           Summary: s390x: Incorrect syscall definitions cause breakage
                    with Linux 4.3 headers
           Product: glibc
           Version: 2.22
            Status: NEW
          Severity: normal
          Priority: P2
         Component: network
          Assignee: unassigned at sourceware dot org
          Reporter: fweimer at redhat dot com
  Target Milestone: ---
            Target: s390x
             Flags: security-

Beginning with Linux 4.3, the kernel headers contain system call numbers
__NR_socket etc. on s390x.

In glibc 2.22 and earlier, sysdeps/unix/sysv/linux/s390/s390-64/syscalls.list
contains the following syscall definitions:

# proper socket implementations:
accept          -       accept          Ci:iBN  __libc_accept   __accept accept
bind            -       bind            i:ipi   __bind          bind
connect         -       connect         Ci:ipi  __libc_connect  __connect
connect
getpeername     -       getpeername     i:ipp   __getpeername   getpeername
getsockname     -       getsockname     i:ipp   __getsockname   getsockname
getsockopt      -       getsockopt      i:iiiBN __getsockopt    getsockopt
listen          -       listen          i:ii    __listen        listen
recv            -       recv            Ci:ibni __libc_recv     __recv recv
recvfrom        -       recvfrom        Ci:ibniBN       __libc_recvfrom
__recvfrom recvfrom
recvmsg         -       recvmsg         Ci:ipi  __libc_recvmsg  __recvmsg
recvmsg
send            -       send            Ci:ibni __libc_send     __send send
sendmsg         -       sendmsg         Ci:ipi  __libc_sendmsg  __sendmsg
sendmsg
sendto          -       sendto          Ci:ibnibn       __libc_sendto  
__sendto sendto
setsockopt      -       setsockopt      i:iiibn __setsockopt    setsockopt
shutdown        -       shutdown        i:ii    __shutdown      shutdown
socket          -       socket          i:iii   __socket        socket
socketpair      -       socketpair      i:iiif  __socketpair    socketpair

Due to the lack of the __NR_ definitions for them, these were ignored before.

With kernel 4.3 headers, they become active, and somehow override the generic
code.  The resulting glibc build will require kernel 4.3 to work, even with
--enable-kernel=2.6.32 at configure time.

I suggest to backport the syscalls.list removal patch from glibc commit
016495b818cb61df7d0d10e6db54074271b3e3a5 (S390: Call direct system calls for
socket operations.) to address this.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]