From: Andreas Schwab Date: Sat, 6 Feb 2010 10:03:10 +0000 (-0800) Subject: Avoid PLT calls in utmp compat wrappers on Linux/s390 X-Git-Tag: upstream/2.30~13035 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=03849910cd0493dde35315eb0baaaf8d5056d296;p=external%2Fglibc.git Avoid PLT calls in utmp compat wrappers on Linux/s390 --- diff --git a/ChangeLog b/ChangeLog index 1216d06..a5797ea 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2010-01-26 Andreas Schwab + * sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c: Use internal + interface. + * sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c: Likewise. + * sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h: Declare internal + utmpx interface. + * sysdeps/unix/sysv/linux/sparc/Versions: Add new errlist compat entry for 2.12. diff --git a/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c b/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c index 32a5d71..bf07f68 100644 --- a/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c +++ b/sysdeps/unix/sysv/linux/s390/s390-32/utmp32.c @@ -62,7 +62,7 @@ struct utmp32 * getutid32 (const struct utmp32 *id) { - ACCESS_UTMP_ENTRY (getutid, id) + ACCESS_UTMP_ENTRY (__getutid, id) } symbol_version (getutid32, getutid, GLIBC_2.0); @@ -71,7 +71,7 @@ symbol_version (getutid32, getutid, GLIBC_2.0); struct utmp32 * getutline32 (const struct utmp32 *line) { - ACCESS_UTMP_ENTRY (getutline, line) + ACCESS_UTMP_ENTRY (__getutline, line) } symbol_version (getutline32, getutline, GLIBC_2.0); @@ -79,7 +79,7 @@ symbol_version (getutline32, getutline, GLIBC_2.0); struct utmp32 * pututline32 (const struct utmp32 *utmp_ptr) { - ACCESS_UTMP_ENTRY (pututline, utmp_ptr) + ACCESS_UTMP_ENTRY (__pututline, utmp_ptr) } symbol_version (pututline32, pututline, GLIBC_2.0); @@ -90,7 +90,7 @@ getutent32 (void) struct utmp *out64; ALLOCATE_UTMP32_OUT (out32); - out64 = getutent (); + out64 = __getutent (); if (!out64) return NULL; @@ -108,7 +108,7 @@ getutent32_r (struct utmp32 *buffer, struct utmp32 **result) struct utmp *out64p; int ret; - ret = getutent_r (&out64, &out64p); + ret = __getutent_r (&out64, &out64p); if (ret == -1) { *result = NULL; @@ -133,7 +133,7 @@ getutid32_r (const struct utmp32 *id, struct utmp32 *buffer, utmp_convert32to64 (id, &in64); - ret = getutid_r (&in64, &out64, &out64p); + ret = __getutid_r (&in64, &out64, &out64p); if (ret == -1) { *result = NULL; @@ -158,7 +158,7 @@ getutline32_r (const struct utmp32 *line, utmp_convert32to64 (line, &in64); - ret = getutline_r (&in64, &out64, &out64p); + ret = __getutline_r (&in64, &out64, &out64p); if (ret == -1) { *result = NULL; @@ -180,6 +180,6 @@ updwtmp32 (const char *wtmp_file, const struct utmp32 *utmp) struct utmp in32; utmp_convert32to64 (utmp, &in32); - updwtmp (wtmp_file, &in32); + __updwtmp (wtmp_file, &in32); } symbol_version (updwtmp32, updwtmp, GLIBC_2.0); diff --git a/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c b/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c index 69a1384..f566f50 100644 --- a/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c +++ b/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.c @@ -68,7 +68,7 @@ getutxent32 (void) struct utmpx *out64; ALLOCATE_UTMPX32_OUT (out32); - out64 = getutxent (); + out64 = __getutxent (); if (!out64) return NULL; @@ -82,7 +82,7 @@ symbol_version (getutxent32, getutxent, GLIBC_2.1); struct utmpx32 * getutxid32 (const struct utmpx32 *id) { - ACCESS_UTMPX_ENTRY (getutxid, id); + ACCESS_UTMPX_ENTRY (__getutxid, id); } symbol_version (getutxid32, getutxid, GLIBC_2.1); @@ -90,7 +90,7 @@ symbol_version (getutxid32, getutxid, GLIBC_2.1); struct utmpx32 * getutxline32 (const struct utmpx32 *line) { - ACCESS_UTMPX_ENTRY (getutxline, line); + ACCESS_UTMPX_ENTRY (__getutxline, line); } symbol_version (getutxline32, getutxline, GLIBC_2.1); @@ -98,7 +98,7 @@ symbol_version (getutxline32, getutxline, GLIBC_2.1); struct utmpx32 * pututxline32 (const struct utmpx32 *utmpx) { - ACCESS_UTMPX_ENTRY (pututxline, utmpx); + ACCESS_UTMPX_ENTRY (__pututxline, utmpx); } symbol_version (pututxline32, pututxline, GLIBC_2.1); @@ -109,7 +109,7 @@ updwtmpx32 (const char *wtmpx_file, const struct utmpx32 *utmpx) struct utmpx in64; utmpx_convert32to64 (utmpx, &in64); - updwtmpx (wtmpx_file, &in64); + __updwtmpx (wtmpx_file, &in64); } symbol_version (updwtmpx32, updwtmpx, GLIBC_2.1); @@ -121,7 +121,7 @@ getutmp32 (const struct utmpx32 *utmpx, struct utmp32 *utmp) struct utmp out64; utmpx_convert32to64 (utmpx, &in64); - getutmp (&in64, &out64); + __getutmp (&in64, &out64); utmp_convert64to32 (&out64, utmp); } symbol_version (getutmp32, getutmp, GLIBC_2.1.1); @@ -134,7 +134,7 @@ getutmpx32 (const struct utmp32 *utmp, struct utmpx32 *utmpx) struct utmpx out64; utmp_convert32to64 (utmp, &in64); - getutmpx (&in64, &out64); + __getutmpx (&in64, &out64); utmpx_convert64to32 (&out64, utmpx); } symbol_version (getutmpx32, getutmpx, GLIBC_2.1.1); diff --git a/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h b/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h index 5f468ed..c61e1cd 100644 --- a/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h +++ b/sysdeps/unix/sysv/linux/s390/s390-32/utmpx32.h @@ -49,4 +49,16 @@ struct utmpx32 char __unused[20]; /* Reserved for future use. */ }; +/* The internal interface needed by the compat wrapper functions. */ +extern struct utmpx *__getutxent (void); +extern struct utmpx *__getutxid (__const struct utmpx *__id); +extern struct utmpx *__getutxline (__const struct utmpx *__line); +extern struct utmpx *__pututxline (__const struct utmpx *__utmpx); +extern void __updwtmpx (__const char *__wtmpx_file, + __const struct utmpx *__utmpx); +extern void __getutmp (__const struct utmpx *__utmpx, + struct utmp *__utmp); +extern void __getutmpx (__const struct utmp *__utmp, + struct utmpx *__utmpx); + #endif /* utmpx32.h */