diff options
Diffstat (limited to 'sysdeps/unix/sysv/linux/sh')
-rw-r--r-- | sysdeps/unix/sysv/linux/sh/pread.c | 19 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/sh/pread64.c | 22 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/sh/pwrite.c | 19 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/sh/pwrite64.c | 23 |
4 files changed, 10 insertions, 73 deletions
diff --git a/sysdeps/unix/sysv/linux/sh/pread.c b/sysdeps/unix/sysv/linux/sh/pread.c index 9d4b5de751..2f926b3305 100644 --- a/sysdeps/unix/sysv/linux/sh/pread.c +++ b/sysdeps/unix/sysv/linux/sh/pread.c @@ -35,23 +35,8 @@ ssize_t __libc_pread (int fd, void *buf, size_t count, off_t offset) { - ssize_t result; - - if (SINGLE_THREAD_P) - { - result = INLINE_SYSCALL (pread, 6, fd, buf, count, 0, - __LONG_LONG_PAIR (offset >> 31, offset)); - return result; - } - - int oldtype = LIBC_CANCEL_ASYNC (); - - result = INLINE_SYSCALL (pread, 6, fd, buf, count, 0, - __LONG_LONG_PAIR (offset >> 31, offset)); - - LIBC_CANCEL_RESET (oldtype); - - return result; + return SYSCALL_CANCEL (pread, fd, buf, count, 0, + __LONG_LONG_PAIR (offset >> 31, offset)); } strong_alias (__libc_pread, __pread) diff --git a/sysdeps/unix/sysv/linux/sh/pread64.c b/sysdeps/unix/sysv/linux/sh/pread64.c index 195eacc29a..697718d41b 100644 --- a/sysdeps/unix/sysv/linux/sh/pread64.c +++ b/sysdeps/unix/sysv/linux/sh/pread64.c @@ -34,25 +34,9 @@ ssize_t __libc_pread64 (int fd, void *buf, size_t count, off64_t offset) { - ssize_t result; - - if (SINGLE_THREAD_P) - { - result = INLINE_SYSCALL (pread, 6, fd, buf, count, 0, - __LONG_LONG_PAIR ((off_t) (offset >> 32), - (off_t) (offset & 0xffffffff))); - return result; - } - - int oldtype = LIBC_CANCEL_ASYNC (); - - result = INLINE_SYSCALL (pread, 6, fd, buf, count, 0, - __LONG_LONG_PAIR ((off_t) (offset >> 32), - (off_t) (offset & 0xffffffff))); - - LIBC_CANCEL_RESET (oldtype); - - return result; + return SYSCALL_CANCEL (pread, fd, buf, count, 0, + __LONG_LONG_PAIR ((off_t) (offset >> 32), + (off_t) (offset & 0xffffffff))); } weak_alias (__libc_pread64, __pread64) diff --git a/sysdeps/unix/sysv/linux/sh/pwrite.c b/sysdeps/unix/sysv/linux/sh/pwrite.c index c187d0a732..fcbb7fc94f 100644 --- a/sysdeps/unix/sysv/linux/sh/pwrite.c +++ b/sysdeps/unix/sysv/linux/sh/pwrite.c @@ -35,23 +35,8 @@ ssize_t __libc_pwrite (int fd, const void *buf, size_t count, off_t offset) { - ssize_t result; - - if (SINGLE_THREAD_P) - { - result = INLINE_SYSCALL (pwrite, 6, fd, buf, count, 0, - __LONG_LONG_PAIR (offset >> 31, offset)); - return result; - } - - int oldtype = LIBC_CANCEL_ASYNC (); - - result = INLINE_SYSCALL (pwrite, 6, fd, buf, count, 0, - __LONG_LONG_PAIR (offset >> 31, offset)); - - LIBC_CANCEL_RESET (oldtype); - - return result; + return SYSCALL_CANCEL (pwrite, fd, buf, count, 0, + __LONG_LONG_PAIR (offset >> 31, offset)); } strong_alias (__libc_pwrite, __pwrite) diff --git a/sysdeps/unix/sysv/linux/sh/pwrite64.c b/sysdeps/unix/sysv/linux/sh/pwrite64.c index 0d15ca21e8..0c189feb0b 100644 --- a/sysdeps/unix/sysv/linux/sh/pwrite64.c +++ b/sysdeps/unix/sysv/linux/sh/pwrite64.c @@ -34,26 +34,9 @@ ssize_t __libc_pwrite64 (int fd, const void *buf, size_t count, off64_t offset) { - ssize_t result; - - if (SINGLE_THREAD_P) - { - result = INLINE_SYSCALL (pwrite, 6, fd, buf, count, 0, - __LONG_LONG_PAIR ((off_t) (offset >> 32), - (off_t) (offset & 0xffffffff))); - - return result; - } - - int oldtype = LIBC_CANCEL_ASYNC (); - - result = INLINE_SYSCALL (pwrite, 6, fd, buf, count, 0, - __LONG_LONG_PAIR ((off_t) (offset >> 32), - (off_t) (offset & 0xffffffff))); - - LIBC_CANCEL_RESET (oldtype); - - return result; + return SYSCALL_CANCEL (pwrite, fd, buf, count, 0, + __LONG_LONG_PAIR ((off_t) (offset >> 32), + (off_t) (offset & 0xffffffff))); } weak_alias (__libc_pwrite64, __pwrite64) |