io: Add time64 alias for fcntl

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
This commit is contained in:
Florian Weimer 2021-07-21 11:42:31 +02:00
parent 82c395d91e
commit 8a40aff86b
24 changed files with 46 additions and 7 deletions

View File

@ -90,6 +90,8 @@ tests-time64 := \
tst-utime-time64 \
tst-utimensat-time64 \
tst-utimes-time64 \
tst-fcntl-time64 \
# tests-time64
# Likewise for statx, but we do not need static linking here.
tests-internal += tst-statx tst-file_change_detection

View File

@ -172,17 +172,30 @@ typedef __pid_t pid_t;
This function is a cancellation point and therefore not marked with
__THROW. */
#ifndef __USE_FILE_OFFSET64
#ifndef __USE_TIME_BITS64
# ifndef __USE_FILE_OFFSET64
extern int fcntl (int __fd, int __cmd, ...);
#else
# ifdef __REDIRECT
extern int __REDIRECT (fcntl, (int __fd, int __cmd, ...), fcntl64);
# else
# define fcntl fcntl64
# ifdef __REDIRECT
extern int __REDIRECT (fcntl, (int __fd, int __cmd, ...), fcntl64);
# else
# define fcntl fcntl64
# endif
# endif
#endif
#ifdef __USE_LARGEFILE64
# ifdef __USE_LARGEFILE64
extern int fcntl64 (int __fd, int __cmd, ...);
# endif
#else /* __USE_TIME_BITS64 */
# ifdef __REDIRECT
extern int __REDIRECT (fcntl, (int __fd, int __request, ...),
__fcntl_time64) __THROW;
extern int __REDIRECT (fcntl64, (int __fd, int __request, ...),
__fcntl_time64) __THROW;
# else
extern int __fcntl_time64 (int __fd, int __request, ...) __THROW;
# define fcntl64 __fcntl_time64
# define fcntl __fcntl_time64
# endif
#endif
/* Open FILE and return a new file descriptor for it, or -1 on error.

1
io/tst-fcntl-time64.c Normal file
View File

@ -0,0 +1 @@
#include "tst-fcntl.c"

View File

@ -209,6 +209,7 @@ libc {
__ctime64;
__ctime64_r;
__difftime64;
__fcntl_time64;
__fstat64_time64;
__fstatat64_time64;
__futimens64;

View File

@ -203,6 +203,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -200,6 +200,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2359,6 +2359,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -54,6 +54,9 @@ libc_hidden_def (__libc_fcntl64)
weak_alias (__libc_fcntl64, __fcntl64)
libc_hidden_weak (__fcntl64)
weak_alias (__libc_fcntl64, fcntl64)
#if __TIMESIZE != 64
weak_alias (__libc_fcntl64, __fcntl_time64)
#endif
#ifdef __OFF_T_MATCHES_OFF64_T
weak_alias (__libc_fcntl64, __libc_fcntl)

View File

@ -2310,6 +2310,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2493,6 +2493,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -204,6 +204,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2437,6 +2437,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2410,6 +2410,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2407,6 +2407,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2402,6 +2402,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2400,6 +2400,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2408,6 +2408,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2449,6 +2449,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2464,6 +2464,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2497,6 +2497,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2462,6 +2462,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2317,6 +2317,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2314,6 +2314,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F

View File

@ -2457,6 +2457,7 @@ GLIBC_2.34 __cnd_timedwait64 F
GLIBC_2.34 __ctime64 F
GLIBC_2.34 __ctime64_r F
GLIBC_2.34 __difftime64 F
GLIBC_2.34 __fcntl_time64 F
GLIBC_2.34 __fstat64_time64 F
GLIBC_2.34 __fstatat64_time64 F
GLIBC_2.34 __fts64_children_time64 F