ld.so: remove unused syscall stubs

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

ld.so: remove unused syscall stubs

Philip Guenther-2

_dl_gettimeofday() was used by the prebind code, which was recently
removed.

_dl_lstat() was only used by _dl_realpath(), which no longer needs it.

ok?


Index: alpha/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/alpha/ldasm.S,v
retrieving revision 1.36
diff -u -p -r1.36 ldasm.S
--- alpha/ldasm.S 7 Aug 2016 03:05:23 -0000 1.36
+++ alpha/ldasm.S 28 Aug 2016 04:12:17 -0000
@@ -316,10 +316,8 @@ DL_SYSCALL(getdents)
 DL_SYSCALL(getentropy)
 DL_SYSCALL(sendsyslog)
 DL_SYSCALL(pledge)
-DL_SYSCALL(gettimeofday)
 DL_SYSCALL_NOERR(issetugid)
 DL_SYSCALL_NOERR(getthrid)
-DL_SYSCALL(lstat)
 DL_SYSCALL(mprotect)
 DL_SYSCALL(munmap)
 DL_SYSCALL(open)
Index: alpha/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/alpha/syscall.h,v
retrieving revision 1.34
diff -u -p -r1.34 syscall.h
--- alpha/syscall.h 4 Jul 2016 21:15:06 -0000 1.34
+++ alpha/syscall.h 28 Aug 2016 04:12:17 -0000
@@ -51,10 +51,8 @@ int _dl_fstat(int, struct stat *);
 ssize_t _dl_getdents(int, char *, size_t);
 long _dl__syscall(quad_t, ...);
 int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 ssize_t _dl_readlink(const char *, char *, size_t);
 int _dl_pledge(const char *, const char **);
-int _dl_lstat(const char *, struct stat *);
 int _dl_getcwd(char *, size_t);
 int _dl_utrace(const char *, const void *, size_t);
 int _dl_getentropy(char *, size_t);
Index: amd64/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/amd64/ldasm.S,v
retrieving revision 1.24
diff -u -p -r1.24 ldasm.S
--- amd64/ldasm.S 7 May 2016 19:05:23 -0000 1.24
+++ amd64/ldasm.S 28 Aug 2016 04:12:17 -0000
@@ -91,10 +91,8 @@ DL_SYSCALL(getthrid)
 DL_SYSCALL(getdents)
 DL_SYSCALL(mprotect)
 DL_SYSCALL(munmap)
-DL_SYSCALL(gettimeofday)
 DL_SYSCALL(exit)
 DL_SYSCALL(readlink)
-DL_SYSCALL(lstat)
 DL_SYSCALL(utrace)
 DL_SYSCALL(getentropy)
 DL_SYSCALL(sendsyslog)
Index: amd64/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/amd64/syscall.h,v
retrieving revision 1.22
diff -u -p -r1.22 syscall.h
--- amd64/syscall.h 4 Jul 2016 21:15:06 -0000 1.22
+++ amd64/syscall.h 28 Aug 2016 04:12:18 -0000
@@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
 int _dl_fstat(int, struct stat *);
 ssize_t _dl_getdents(int, char *, size_t);
 int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 ssize_t _dl_readlink(const char *, char *, size_t);
 int _dl_pledge(const char *, const char **);
-int _dl_lstat(const char *, struct stat *);
 int _dl_getcwd(char *, size_t);
 int _dl_utrace(const char *, const void *, size_t);
 int _dl_getentropy(char *, size_t);
Index: arm/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/arm/ldasm.S,v
retrieving revision 1.23
diff -u -p -r1.23 ldasm.S
--- arm/ldasm.S 9 Aug 2016 03:58:35 -0000 1.23
+++ arm/ldasm.S 28 Aug 2016 04:12:18 -0000
@@ -126,9 +126,7 @@ DL_SYSCALL(open)
 DL_SYSCALL(read)
 DL_SYSCALL(write)
 DL_SYSCALL(fstat)
-DL_SYSCALL(gettimeofday)
 DL_SYSCALL(readlink)
-DL_SYSCALL(lstat)
 DL_SYSCALL(utrace)
 DL_SYSCALL(getentropy)
 DL_SYSCALL(sendsyslog)
Index: arm/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/arm/syscall.h,v
retrieving revision 1.22
diff -u -p -r1.22 syscall.h
--- arm/syscall.h 4 Jul 2016 21:15:06 -0000 1.22
+++ arm/syscall.h 28 Aug 2016 04:12:18 -0000
@@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
 int _dl_fstat(int, struct stat *);
 ssize_t _dl_getdents(int, char *, size_t);
 int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 ssize_t _dl_readlink(const char *, char *, size_t);
 int _dl_pledge(const char *, const char **);
-int _dl_lstat(const char *, struct stat *);
 int _dl_getcwd(char *, size_t);
 int _dl_utrace(const char *, const void *, size_t);
 int _dl_getentropy(char *, size_t);
Index: hppa/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/hppa/ldasm.S,v
retrieving revision 1.21
diff -u -p -r1.21 ldasm.S
--- hppa/ldasm.S 7 May 2016 19:05:23 -0000 1.21
+++ hppa/ldasm.S 28 Aug 2016 04:12:18 -0000
@@ -242,23 +242,11 @@ ENTRY(_dl_getdents,0)
  nop
 EXIT(_dl_getdents)
 
-ENTRY(_dl_gettimeofday,0)
- SYSCALL(gettimeofday)
- bv r0(rp)
- nop
-EXIT(_dl_gettimeofday)
-
 ENTRY(_dl_readlink,0)
  SYSCALL(readlink)
  bv r0(rp)
  nop
 EXIT(_dl_readlink)
-
-ENTRY(_dl_lstat,0)
- SYSCALL(lstat)
- bv r0(rp)
- nop
-EXIT(_dl_lstat)
 
 ENTRY(_dl_getcwd,0)
  SYSCALL(__getcwd)
Index: hppa/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/hppa/syscall.h,v
retrieving revision 1.22
diff -u -p -r1.22 syscall.h
--- hppa/syscall.h 4 Jul 2016 21:15:06 -0000 1.22
+++ hppa/syscall.h 28 Aug 2016 04:12:18 -0000
@@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
 int _dl_fstat(int, struct stat *);
 ssize_t _dl_getdents(int, char *, size_t);
 int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 ssize_t _dl_readlink(const char *, char *, size_t);
 int _dl_pledge(const char *, const char **);
-int _dl_lstat(const char *, struct stat *);
 int _dl_getcwd(char *, size_t);
 int _dl_utrace(const char *, const void *, size_t);
 int _dl_getentropy(char *, size_t);
Index: i386/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/i386/ldasm.S,v
retrieving revision 1.27
diff -u -p -r1.27 ldasm.S
--- i386/ldasm.S 7 Aug 2016 03:03:44 -0000 1.27
+++ i386/ldasm.S 28 Aug 2016 04:12:18 -0000
@@ -118,9 +118,7 @@ DL_SYSCALL(open)
 DL_SYSCALL(read)
 DL_SYSCALL(write)
 DL_SYSCALL(fstat)
-DL_SYSCALL(gettimeofday)
 DL_SYSCALL(readlink)
-DL_SYSCALL(lstat)
 DL_SYSCALL(utrace)
 DL_SYSCALL(getentropy)
 DL_SYSCALL(sendsyslog)
Index: i386/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/i386/syscall.h,v
retrieving revision 1.26
diff -u -p -r1.26 syscall.h
--- i386/syscall.h 4 Jul 2016 21:15:06 -0000 1.26
+++ i386/syscall.h 28 Aug 2016 04:12:18 -0000
@@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
 int _dl_fstat(int, struct stat *);
 ssize_t _dl_getdents(int, char *, size_t);
 int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 ssize_t _dl_readlink(const char *, char *, size_t);
 int _dl_pledge(const char *, const char **);
-int _dl_lstat(const char *, struct stat *);
 int _dl_getcwd(char *, size_t);
 int _dl_utrace(const char *, const void *, size_t);
 int _dl_getentropy(char *, size_t);
Index: m88k/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/m88k/ldasm.S,v
retrieving revision 1.22
diff -u -p -r1.22 ldasm.S
--- m88k/ldasm.S 18 Jul 2016 08:43:16 -0000 1.22
+++ m88k/ldasm.S 28 Aug 2016 04:12:18 -0000
@@ -182,9 +182,7 @@ DL_SYSCALL(open)
 DL_SYSCALL(read)
 DL_SYSCALL(write)
 DL_SYSCALL(fstat)
-DL_SYSCALL(gettimeofday)
 DL_SYSCALL(readlink)
-DL_SYSCALL(lstat)
 DL_SYSCALL(utrace)
 DL_SYSCALL(getentropy)
 DL_SYSCALL(sendsyslog)
Index: m88k/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/m88k/syscall.h,v
retrieving revision 1.18
diff -u -p -r1.18 syscall.h
--- m88k/syscall.h 4 Jul 2016 21:15:06 -0000 1.18
+++ m88k/syscall.h 28 Aug 2016 04:12:18 -0000
@@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
 int _dl_fstat(int, struct stat *);
 ssize_t _dl_getdents(int, char *, size_t);
 int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 ssize_t _dl_readlink(const char *, char *, size_t);
 int _dl_pledge(const char *, const char **);
-int _dl_lstat(const char *, struct stat *);
 int _dl_getcwd(char *, size_t);
 int _dl_utrace(const char *, const void *, size_t);
 int _dl_getentropy(char *, size_t);
Index: mips64/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/mips64/ldasm.S,v
retrieving revision 1.20
diff -u -p -r1.20 ldasm.S
--- mips64/ldasm.S 7 Aug 2016 03:01:53 -0000 1.20
+++ mips64/ldasm.S 28 Aug 2016 04:12:18 -0000
@@ -156,10 +156,8 @@ DL_SYSCALL(getdents)
 DL_SYSCALL(getentropy)
 DL_SYSCALL(sendsyslog)
 DL_SYSCALL(pledge)
-DL_SYSCALL(gettimeofday)
 DL_SYSCALL_NOERR(issetugid)
 DL_SYSCALL_NOERR(getthrid)
-DL_SYSCALL(lstat)
 DL_SYSCALL(mprotect)
 DL_SYSCALL(munmap)
 DL_SYSCALL(open)
Index: mips64/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/mips64/syscall.h,v
retrieving revision 1.24
diff -u -p -r1.24 syscall.h
--- mips64/syscall.h 4 Jul 2016 21:15:07 -0000 1.24
+++ mips64/syscall.h 28 Aug 2016 04:12:18 -0000
@@ -43,10 +43,8 @@ int _dl_exit(int);
 int _dl_fstat(int, struct stat *);
 int _dl_getcwd(char *, size_t);
 ssize_t _dl_getdents(int, char *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 int _dl_issetugid(void);
 int _dl_getthrid(void);
-int _dl_lstat(const char *, struct stat *);
 int _dl_mprotect(const void *, size_t, int);
 int _dl_munmap(const void *, size_t);
 int _dl_open(const char *, int);
Index: powerpc/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/powerpc/ldasm.S,v
retrieving revision 1.29
diff -u -p -r1.29 ldasm.S
--- powerpc/ldasm.S 7 May 2016 19:05:23 -0000 1.29
+++ powerpc/ldasm.S 28 Aug 2016 04:12:18 -0000
@@ -149,10 +149,8 @@ DL_SYSCALL(getdents)
 DL_SYSCALL(getentropy)
 DL_SYSCALL(sendsyslog)
 DL_SYSCALL(pledge)
-DL_SYSCALL(gettimeofday)
 DL_SYSCALL_NOERR(issetugid)
 DL_SYSCALL_NOERR(getthrid)
-DL_SYSCALL(lstat)
 DL_SYSCALL(mmap)
 DL_SYSCALL(mprotect)
 DL_SYSCALL(munmap)
Index: powerpc/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/powerpc/syscall.h,v
retrieving revision 1.42
diff -u -p -r1.42 syscall.h
--- powerpc/syscall.h 4 Jul 2016 21:15:07 -0000 1.42
+++ powerpc/syscall.h 28 Aug 2016 04:12:18 -0000
@@ -43,10 +43,8 @@ void _dl_exit(int);
 int _dl_fstat(int, struct stat *);
 int _dl_getcwd(char *, size_t);
 ssize_t _dl_getdents(int, char *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 int _dl_issetugid(void);
 int _dl_getthrid(void);
-int _dl_lstat(const char *, struct stat *);
 void * _dl_mmap(void *, size_t, int, int, int, off_t);
 int _dl_mprotect(const void *, size_t, int);
 int _dl_munmap(const void *, size_t);
Index: sh/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/sh/ldasm.S,v
retrieving revision 1.25
diff -u -p -r1.25 ldasm.S
--- sh/ldasm.S 7 May 2016 21:20:11 -0000 1.25
+++ sh/ldasm.S 28 Aug 2016 04:12:19 -0000
@@ -186,9 +186,7 @@ DL_SYSCALL(read)
 
 DL_SYSCALL(write)
 DL_SYSCALL(fstat)
-DL_SYSCALL(gettimeofday)
 DL_SYSCALL(readlink)
-DL_SYSCALL(lstat)
 DL_SYSCALL(utrace)
 DL_SYSCALL(getentropy)
 DL_SYSCALL(sendsyslog)
Index: sh/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/sh/syscall.h,v
retrieving revision 1.20
diff -u -p -r1.20 syscall.h
--- sh/syscall.h 4 Jul 2016 21:15:07 -0000 1.20
+++ sh/syscall.h 28 Aug 2016 04:12:19 -0000
@@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
 int _dl_fstat(int, struct stat *);
 ssize_t _dl_getdents(int, char *, size_t);
 int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 ssize_t _dl_readlink(const char *, char *, size_t);
 int _dl_pledge(const char *, const char **);
-int _dl_lstat(const char *, struct stat *);
 int _dl_getcwd(char *, size_t);
 int _dl_utrace(const char *, const void *, size_t);
 int _dl_getentropy(char *, size_t);
Index: sparc/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/sparc/ldasm.S,v
retrieving revision 1.31
diff -u -p -r1.31 ldasm.S
--- sparc/ldasm.S 7 May 2016 19:05:23 -0000 1.31
+++ sparc/ldasm.S 28 Aug 2016 04:12:19 -0000
@@ -296,34 +296,10 @@ _dl_sysctl:
 
  .section ".text"
  .align 4
- .global _dl_gettimeofday
- .type _dl_gettimeofday,@function
-_dl_gettimeofday:
- mov SYS_gettimeofday | SYSCALL_G2RFLAG, %g1 ! calling sys_gettimeofday
- add %o7, 8, %g2 ! just return on success
- t ST_SYSCALL ! off to wonderland
- retl
- sub %g0, %o0, %o0 ! error: result = -errno
-
-
- .section ".text"
- .align 4
  .global _dl_readlink
  .type _dl_readlink,@function
 _dl_readlink:
  mov SYS_readlink | SYSCALL_G2RFLAG, %g1 ! calling sys_readlink
- add %o7, 8, %g2 ! just return on success
- t ST_SYSCALL ! off to wonderland
- retl
- sub %g0, %o0, %o0 ! error: result = -errno
-
-
- .section ".text"
- .align 4
- .global _dl_lstat
- .type _dl_lstat,@function
-_dl_lstat:
- mov SYS_lstat | SYSCALL_G2RFLAG, %g1 ! calling sys_lstat
  add %o7, 8, %g2 ! just return on success
  t ST_SYSCALL ! off to wonderland
  retl
Index: sparc/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/sparc/syscall.h,v
retrieving revision 1.27
diff -u -p -r1.27 syscall.h
--- sparc/syscall.h 4 Jul 2016 21:15:07 -0000 1.27
+++ sparc/syscall.h 28 Aug 2016 04:12:19 -0000
@@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
 int _dl_fstat(int, struct stat *);
 ssize_t _dl_getdents(int, char *, size_t);
 int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 ssize_t _dl_readlink(const char *, char *, size_t);
 int _dl_pledge(const char *, const char **);
-int _dl_lstat(const char *, struct stat *);
 int _dl_getcwd(char *, size_t);
 int _dl_utrace(const char *, const void *, size_t);
 int _dl_getentropy(char *, size_t);
Index: sparc64/ldasm.S
===================================================================
RCS file: /cvs/src/libexec/ld.so/sparc64/ldasm.S,v
retrieving revision 1.43
diff -u -p -r1.43 ldasm.S
--- sparc64/ldasm.S 7 May 2016 19:05:23 -0000 1.43
+++ sparc64/ldasm.S 28 Aug 2016 04:12:19 -0000
@@ -300,22 +300,8 @@ _ENTRY(_dl_sysctl)
  retl
  sub %g0, %o0, %o0 ! error: result = -errno
 
-_ENTRY(_dl_gettimeofday)
- mov SYS_gettimeofday | SYSCALL_G2RFLAG, %g1 ! calling sys_gettimeofday
- add %o7, 8, %g2 ! just return on success
- t ST_SYSCALL ! off to wonderland
- retl
- sub %g0, %o0, %o0 ! error: result = -errno
-
 _ENTRY(_dl_readlink)
  mov SYS_readlink | SYSCALL_G2RFLAG, %g1 ! calling sys_readlink
- add %o7, 8, %g2 ! just return on success
- t ST_SYSCALL ! off to wonderland
- retl
- sub %g0, %o0, %o0 ! error: result = -errno
-
-_ENTRY(_dl_lstat)
- mov SYS_lstat | SYSCALL_G2RFLAG, %g1 ! calling sys_lstat
  add %o7, 8, %g2 ! just return on success
  t ST_SYSCALL ! off to wonderland
  retl
Index: sparc64/syscall.h
===================================================================
RCS file: /cvs/src/libexec/ld.so/sparc64/syscall.h,v
retrieving revision 1.34
diff -u -p -r1.34 syscall.h
--- sparc64/syscall.h 4 Jul 2016 21:15:07 -0000 1.34
+++ sparc64/syscall.h 28 Aug 2016 04:12:19 -0000
@@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
 int _dl_fstat(int, struct stat *);
 ssize_t _dl_getdents(int, char *, size_t);
 int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
-int _dl_gettimeofday(struct timeval *, struct timezone *);
 ssize_t _dl_readlink(const char *, char *, size_t);
 int _dl_pledge(const char *, const char **);
-int _dl_lstat(const char *, struct stat *);
 int _dl_getcwd(char *, size_t);
 int _dl_utrace(const char *, const void *, size_t);
 int _dl_getentropy(char *, size_t);

Reply | Threaded
Open this post in threaded view
|

Re: ld.so: remove unused syscall stubs

Mark Kettenis
> Date: Sat, 27 Aug 2016 21:14:20 -0700
> From: Philip Guenther <[hidden email]>
>
> _dl_gettimeofday() was used by the prebind code, which was recently
> removed.
>
> _dl_lstat() was only used by _dl_realpath(), which no longer needs it.
>
> ok?

ok kettenis@

> Index: alpha/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/alpha/ldasm.S,v
> retrieving revision 1.36
> diff -u -p -r1.36 ldasm.S
> --- alpha/ldasm.S 7 Aug 2016 03:05:23 -0000 1.36
> +++ alpha/ldasm.S 28 Aug 2016 04:12:17 -0000
> @@ -316,10 +316,8 @@ DL_SYSCALL(getdents)
>  DL_SYSCALL(getentropy)
>  DL_SYSCALL(sendsyslog)
>  DL_SYSCALL(pledge)
> -DL_SYSCALL(gettimeofday)
>  DL_SYSCALL_NOERR(issetugid)
>  DL_SYSCALL_NOERR(getthrid)
> -DL_SYSCALL(lstat)
>  DL_SYSCALL(mprotect)
>  DL_SYSCALL(munmap)
>  DL_SYSCALL(open)
> Index: alpha/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/alpha/syscall.h,v
> retrieving revision 1.34
> diff -u -p -r1.34 syscall.h
> --- alpha/syscall.h 4 Jul 2016 21:15:06 -0000 1.34
> +++ alpha/syscall.h 28 Aug 2016 04:12:17 -0000
> @@ -51,10 +51,8 @@ int _dl_fstat(int, struct stat *);
>  ssize_t _dl_getdents(int, char *, size_t);
>  long _dl__syscall(quad_t, ...);
>  int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  ssize_t _dl_readlink(const char *, char *, size_t);
>  int _dl_pledge(const char *, const char **);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  int _dl_utrace(const char *, const void *, size_t);
>  int _dl_getentropy(char *, size_t);
> Index: amd64/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/amd64/ldasm.S,v
> retrieving revision 1.24
> diff -u -p -r1.24 ldasm.S
> --- amd64/ldasm.S 7 May 2016 19:05:23 -0000 1.24
> +++ amd64/ldasm.S 28 Aug 2016 04:12:17 -0000
> @@ -91,10 +91,8 @@ DL_SYSCALL(getthrid)
>  DL_SYSCALL(getdents)
>  DL_SYSCALL(mprotect)
>  DL_SYSCALL(munmap)
> -DL_SYSCALL(gettimeofday)
>  DL_SYSCALL(exit)
>  DL_SYSCALL(readlink)
> -DL_SYSCALL(lstat)
>  DL_SYSCALL(utrace)
>  DL_SYSCALL(getentropy)
>  DL_SYSCALL(sendsyslog)
> Index: amd64/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/amd64/syscall.h,v
> retrieving revision 1.22
> diff -u -p -r1.22 syscall.h
> --- amd64/syscall.h 4 Jul 2016 21:15:06 -0000 1.22
> +++ amd64/syscall.h 28 Aug 2016 04:12:18 -0000
> @@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
>  int _dl_fstat(int, struct stat *);
>  ssize_t _dl_getdents(int, char *, size_t);
>  int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  ssize_t _dl_readlink(const char *, char *, size_t);
>  int _dl_pledge(const char *, const char **);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  int _dl_utrace(const char *, const void *, size_t);
>  int _dl_getentropy(char *, size_t);
> Index: arm/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/arm/ldasm.S,v
> retrieving revision 1.23
> diff -u -p -r1.23 ldasm.S
> --- arm/ldasm.S 9 Aug 2016 03:58:35 -0000 1.23
> +++ arm/ldasm.S 28 Aug 2016 04:12:18 -0000
> @@ -126,9 +126,7 @@ DL_SYSCALL(open)
>  DL_SYSCALL(read)
>  DL_SYSCALL(write)
>  DL_SYSCALL(fstat)
> -DL_SYSCALL(gettimeofday)
>  DL_SYSCALL(readlink)
> -DL_SYSCALL(lstat)
>  DL_SYSCALL(utrace)
>  DL_SYSCALL(getentropy)
>  DL_SYSCALL(sendsyslog)
> Index: arm/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/arm/syscall.h,v
> retrieving revision 1.22
> diff -u -p -r1.22 syscall.h
> --- arm/syscall.h 4 Jul 2016 21:15:06 -0000 1.22
> +++ arm/syscall.h 28 Aug 2016 04:12:18 -0000
> @@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
>  int _dl_fstat(int, struct stat *);
>  ssize_t _dl_getdents(int, char *, size_t);
>  int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  ssize_t _dl_readlink(const char *, char *, size_t);
>  int _dl_pledge(const char *, const char **);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  int _dl_utrace(const char *, const void *, size_t);
>  int _dl_getentropy(char *, size_t);
> Index: hppa/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/hppa/ldasm.S,v
> retrieving revision 1.21
> diff -u -p -r1.21 ldasm.S
> --- hppa/ldasm.S 7 May 2016 19:05:23 -0000 1.21
> +++ hppa/ldasm.S 28 Aug 2016 04:12:18 -0000
> @@ -242,23 +242,11 @@ ENTRY(_dl_getdents,0)
>   nop
>  EXIT(_dl_getdents)
>  
> -ENTRY(_dl_gettimeofday,0)
> - SYSCALL(gettimeofday)
> - bv r0(rp)
> - nop
> -EXIT(_dl_gettimeofday)
> -
>  ENTRY(_dl_readlink,0)
>   SYSCALL(readlink)
>   bv r0(rp)
>   nop
>  EXIT(_dl_readlink)
> -
> -ENTRY(_dl_lstat,0)
> - SYSCALL(lstat)
> - bv r0(rp)
> - nop
> -EXIT(_dl_lstat)
>  
>  ENTRY(_dl_getcwd,0)
>   SYSCALL(__getcwd)
> Index: hppa/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/hppa/syscall.h,v
> retrieving revision 1.22
> diff -u -p -r1.22 syscall.h
> --- hppa/syscall.h 4 Jul 2016 21:15:06 -0000 1.22
> +++ hppa/syscall.h 28 Aug 2016 04:12:18 -0000
> @@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
>  int _dl_fstat(int, struct stat *);
>  ssize_t _dl_getdents(int, char *, size_t);
>  int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  ssize_t _dl_readlink(const char *, char *, size_t);
>  int _dl_pledge(const char *, const char **);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  int _dl_utrace(const char *, const void *, size_t);
>  int _dl_getentropy(char *, size_t);
> Index: i386/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/i386/ldasm.S,v
> retrieving revision 1.27
> diff -u -p -r1.27 ldasm.S
> --- i386/ldasm.S 7 Aug 2016 03:03:44 -0000 1.27
> +++ i386/ldasm.S 28 Aug 2016 04:12:18 -0000
> @@ -118,9 +118,7 @@ DL_SYSCALL(open)
>  DL_SYSCALL(read)
>  DL_SYSCALL(write)
>  DL_SYSCALL(fstat)
> -DL_SYSCALL(gettimeofday)
>  DL_SYSCALL(readlink)
> -DL_SYSCALL(lstat)
>  DL_SYSCALL(utrace)
>  DL_SYSCALL(getentropy)
>  DL_SYSCALL(sendsyslog)
> Index: i386/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/i386/syscall.h,v
> retrieving revision 1.26
> diff -u -p -r1.26 syscall.h
> --- i386/syscall.h 4 Jul 2016 21:15:06 -0000 1.26
> +++ i386/syscall.h 28 Aug 2016 04:12:18 -0000
> @@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
>  int _dl_fstat(int, struct stat *);
>  ssize_t _dl_getdents(int, char *, size_t);
>  int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  ssize_t _dl_readlink(const char *, char *, size_t);
>  int _dl_pledge(const char *, const char **);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  int _dl_utrace(const char *, const void *, size_t);
>  int _dl_getentropy(char *, size_t);
> Index: m88k/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/m88k/ldasm.S,v
> retrieving revision 1.22
> diff -u -p -r1.22 ldasm.S
> --- m88k/ldasm.S 18 Jul 2016 08:43:16 -0000 1.22
> +++ m88k/ldasm.S 28 Aug 2016 04:12:18 -0000
> @@ -182,9 +182,7 @@ DL_SYSCALL(open)
>  DL_SYSCALL(read)
>  DL_SYSCALL(write)
>  DL_SYSCALL(fstat)
> -DL_SYSCALL(gettimeofday)
>  DL_SYSCALL(readlink)
> -DL_SYSCALL(lstat)
>  DL_SYSCALL(utrace)
>  DL_SYSCALL(getentropy)
>  DL_SYSCALL(sendsyslog)
> Index: m88k/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/m88k/syscall.h,v
> retrieving revision 1.18
> diff -u -p -r1.18 syscall.h
> --- m88k/syscall.h 4 Jul 2016 21:15:06 -0000 1.18
> +++ m88k/syscall.h 28 Aug 2016 04:12:18 -0000
> @@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
>  int _dl_fstat(int, struct stat *);
>  ssize_t _dl_getdents(int, char *, size_t);
>  int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  ssize_t _dl_readlink(const char *, char *, size_t);
>  int _dl_pledge(const char *, const char **);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  int _dl_utrace(const char *, const void *, size_t);
>  int _dl_getentropy(char *, size_t);
> Index: mips64/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/mips64/ldasm.S,v
> retrieving revision 1.20
> diff -u -p -r1.20 ldasm.S
> --- mips64/ldasm.S 7 Aug 2016 03:01:53 -0000 1.20
> +++ mips64/ldasm.S 28 Aug 2016 04:12:18 -0000
> @@ -156,10 +156,8 @@ DL_SYSCALL(getdents)
>  DL_SYSCALL(getentropy)
>  DL_SYSCALL(sendsyslog)
>  DL_SYSCALL(pledge)
> -DL_SYSCALL(gettimeofday)
>  DL_SYSCALL_NOERR(issetugid)
>  DL_SYSCALL_NOERR(getthrid)
> -DL_SYSCALL(lstat)
>  DL_SYSCALL(mprotect)
>  DL_SYSCALL(munmap)
>  DL_SYSCALL(open)
> Index: mips64/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/mips64/syscall.h,v
> retrieving revision 1.24
> diff -u -p -r1.24 syscall.h
> --- mips64/syscall.h 4 Jul 2016 21:15:07 -0000 1.24
> +++ mips64/syscall.h 28 Aug 2016 04:12:18 -0000
> @@ -43,10 +43,8 @@ int _dl_exit(int);
>  int _dl_fstat(int, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  ssize_t _dl_getdents(int, char *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  int _dl_issetugid(void);
>  int _dl_getthrid(void);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_mprotect(const void *, size_t, int);
>  int _dl_munmap(const void *, size_t);
>  int _dl_open(const char *, int);
> Index: powerpc/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/powerpc/ldasm.S,v
> retrieving revision 1.29
> diff -u -p -r1.29 ldasm.S
> --- powerpc/ldasm.S 7 May 2016 19:05:23 -0000 1.29
> +++ powerpc/ldasm.S 28 Aug 2016 04:12:18 -0000
> @@ -149,10 +149,8 @@ DL_SYSCALL(getdents)
>  DL_SYSCALL(getentropy)
>  DL_SYSCALL(sendsyslog)
>  DL_SYSCALL(pledge)
> -DL_SYSCALL(gettimeofday)
>  DL_SYSCALL_NOERR(issetugid)
>  DL_SYSCALL_NOERR(getthrid)
> -DL_SYSCALL(lstat)
>  DL_SYSCALL(mmap)
>  DL_SYSCALL(mprotect)
>  DL_SYSCALL(munmap)
> Index: powerpc/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/powerpc/syscall.h,v
> retrieving revision 1.42
> diff -u -p -r1.42 syscall.h
> --- powerpc/syscall.h 4 Jul 2016 21:15:07 -0000 1.42
> +++ powerpc/syscall.h 28 Aug 2016 04:12:18 -0000
> @@ -43,10 +43,8 @@ void _dl_exit(int);
>  int _dl_fstat(int, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  ssize_t _dl_getdents(int, char *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  int _dl_issetugid(void);
>  int _dl_getthrid(void);
> -int _dl_lstat(const char *, struct stat *);
>  void * _dl_mmap(void *, size_t, int, int, int, off_t);
>  int _dl_mprotect(const void *, size_t, int);
>  int _dl_munmap(const void *, size_t);
> Index: sh/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/sh/ldasm.S,v
> retrieving revision 1.25
> diff -u -p -r1.25 ldasm.S
> --- sh/ldasm.S 7 May 2016 21:20:11 -0000 1.25
> +++ sh/ldasm.S 28 Aug 2016 04:12:19 -0000
> @@ -186,9 +186,7 @@ DL_SYSCALL(read)
>  
>  DL_SYSCALL(write)
>  DL_SYSCALL(fstat)
> -DL_SYSCALL(gettimeofday)
>  DL_SYSCALL(readlink)
> -DL_SYSCALL(lstat)
>  DL_SYSCALL(utrace)
>  DL_SYSCALL(getentropy)
>  DL_SYSCALL(sendsyslog)
> Index: sh/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/sh/syscall.h,v
> retrieving revision 1.20
> diff -u -p -r1.20 syscall.h
> --- sh/syscall.h 4 Jul 2016 21:15:07 -0000 1.20
> +++ sh/syscall.h 28 Aug 2016 04:12:19 -0000
> @@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
>  int _dl_fstat(int, struct stat *);
>  ssize_t _dl_getdents(int, char *, size_t);
>  int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  ssize_t _dl_readlink(const char *, char *, size_t);
>  int _dl_pledge(const char *, const char **);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  int _dl_utrace(const char *, const void *, size_t);
>  int _dl_getentropy(char *, size_t);
> Index: sparc/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/sparc/ldasm.S,v
> retrieving revision 1.31
> diff -u -p -r1.31 ldasm.S
> --- sparc/ldasm.S 7 May 2016 19:05:23 -0000 1.31
> +++ sparc/ldasm.S 28 Aug 2016 04:12:19 -0000
> @@ -296,34 +296,10 @@ _dl_sysctl:
>  
>   .section ".text"
>   .align 4
> - .global _dl_gettimeofday
> - .type _dl_gettimeofday,@function
> -_dl_gettimeofday:
> - mov SYS_gettimeofday | SYSCALL_G2RFLAG, %g1 ! calling sys_gettimeofday
> - add %o7, 8, %g2 ! just return on success
> - t ST_SYSCALL ! off to wonderland
> - retl
> - sub %g0, %o0, %o0 ! error: result = -errno
> -
> -
> - .section ".text"
> - .align 4
>   .global _dl_readlink
>   .type _dl_readlink,@function
>  _dl_readlink:
>   mov SYS_readlink | SYSCALL_G2RFLAG, %g1 ! calling sys_readlink
> - add %o7, 8, %g2 ! just return on success
> - t ST_SYSCALL ! off to wonderland
> - retl
> - sub %g0, %o0, %o0 ! error: result = -errno
> -
> -
> - .section ".text"
> - .align 4
> - .global _dl_lstat
> - .type _dl_lstat,@function
> -_dl_lstat:
> - mov SYS_lstat | SYSCALL_G2RFLAG, %g1 ! calling sys_lstat
>   add %o7, 8, %g2 ! just return on success
>   t ST_SYSCALL ! off to wonderland
>   retl
> Index: sparc/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/sparc/syscall.h,v
> retrieving revision 1.27
> diff -u -p -r1.27 syscall.h
> --- sparc/syscall.h 4 Jul 2016 21:15:07 -0000 1.27
> +++ sparc/syscall.h 28 Aug 2016 04:12:19 -0000
> @@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
>  int _dl_fstat(int, struct stat *);
>  ssize_t _dl_getdents(int, char *, size_t);
>  int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  ssize_t _dl_readlink(const char *, char *, size_t);
>  int _dl_pledge(const char *, const char **);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  int _dl_utrace(const char *, const void *, size_t);
>  int _dl_getentropy(char *, size_t);
> Index: sparc64/ldasm.S
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/sparc64/ldasm.S,v
> retrieving revision 1.43
> diff -u -p -r1.43 ldasm.S
> --- sparc64/ldasm.S 7 May 2016 19:05:23 -0000 1.43
> +++ sparc64/ldasm.S 28 Aug 2016 04:12:19 -0000
> @@ -300,22 +300,8 @@ _ENTRY(_dl_sysctl)
>   retl
>   sub %g0, %o0, %o0 ! error: result = -errno
>  
> -_ENTRY(_dl_gettimeofday)
> - mov SYS_gettimeofday | SYSCALL_G2RFLAG, %g1 ! calling sys_gettimeofday
> - add %o7, 8, %g2 ! just return on success
> - t ST_SYSCALL ! off to wonderland
> - retl
> - sub %g0, %o0, %o0 ! error: result = -errno
> -
>  _ENTRY(_dl_readlink)
>   mov SYS_readlink | SYSCALL_G2RFLAG, %g1 ! calling sys_readlink
> - add %o7, 8, %g2 ! just return on success
> - t ST_SYSCALL ! off to wonderland
> - retl
> - sub %g0, %o0, %o0 ! error: result = -errno
> -
> -_ENTRY(_dl_lstat)
> - mov SYS_lstat | SYSCALL_G2RFLAG, %g1 ! calling sys_lstat
>   add %o7, 8, %g2 ! just return on success
>   t ST_SYSCALL ! off to wonderland
>   retl
> Index: sparc64/syscall.h
> ===================================================================
> RCS file: /cvs/src/libexec/ld.so/sparc64/syscall.h,v
> retrieving revision 1.34
> diff -u -p -r1.34 syscall.h
> --- sparc64/syscall.h 4 Jul 2016 21:15:07 -0000 1.34
> +++ sparc64/syscall.h 28 Aug 2016 04:12:19 -0000
> @@ -51,10 +51,8 @@ ssize_t _dl_read(int, const char *, size
>  int _dl_fstat(int, struct stat *);
>  ssize_t _dl_getdents(int, char *, size_t);
>  int _dl_sysctl(const int *, u_int, void *, size_t *, void *, size_t);
> -int _dl_gettimeofday(struct timeval *, struct timezone *);
>  ssize_t _dl_readlink(const char *, char *, size_t);
>  int _dl_pledge(const char *, const char **);
> -int _dl_lstat(const char *, struct stat *);
>  int _dl_getcwd(char *, size_t);
>  int _dl_utrace(const char *, const void *, size_t);
>  int _dl_getentropy(char *, size_t);
>
>