This is the mail archive of the glibc-cvs@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]

GNU C Library master sources branch, master, updated. glibc-2.14-527-g446514f


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  446514f97eaf555200f9ec4f369223f984e638a5 (commit)
      from  a501a01e069619676990454abd43c4d2bf4527f4 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=446514f97eaf555200f9ec4f369223f984e638a5

commit 446514f97eaf555200f9ec4f369223f984e638a5
Author: Andreas Schwab <schwab@redhat.com>
Date:   Tue Nov 15 15:04:26 2011 +0100

    Fix clock_gettime for assumed kernel >= 2.6.12

diff --git a/ChangeLog b/ChangeLog
index 8bb2513..84cd700 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2011-11-15  Andreas Schwab  <schwab@redhat.com>
 
+	* sysdeps/unix/sysv/linux/clock_gettime.c (SYSDEP_GETTIME_CPU)
+	[__ASSUME_POSIX_CPU_TIMERS > 0]: Assign to retval and break.
+	* sysdeps/unix/sysv/linux/x86_64/clock_gettime.c
+	(SYSCALL_GETTIME): Set errno on error.
+
 	* sysdeps/unix/sysv/linux/check_pf.c (make_request): Properly
 	count references to noai6ai_cached.
 
diff --git a/sysdeps/unix/sysv/linux/clock_gettime.c b/sysdeps/unix/sysv/linux/clock_gettime.c
index e5e032d..ad0fe1e 100644
--- a/sysdeps/unix/sysv/linux/clock_gettime.c
+++ b/sysdeps/unix/sysv/linux/clock_gettime.c
@@ -110,7 +110,9 @@ maybe_syscall_gettime (clockid_t clock_id, struct timespec *tp)
 
 # if __ASSUME_POSIX_CPU_TIMERS > 0
 
-#  define SYSDEP_GETTIME_CPU SYSCALL_GETTIME
+#  define SYSDEP_GETTIME_CPU(clock_id, tp) \
+  retval = SYSCALL_GETTIME (clock_id, tp); \
+  break
 #  define SYSDEP_GETTIME_CPUTIME	/* Default catches them too.  */
 
 # else
diff --git a/sysdeps/unix/sysv/linux/x86_64/clock_gettime.c b/sysdeps/unix/sysv/linux/x86_64/clock_gettime.c
index 7802701..f712110 100644
--- a/sysdeps/unix/sysv/linux/x86_64/clock_gettime.c
+++ b/sysdeps/unix/sysv/linux/x86_64/clock_gettime.c
@@ -3,8 +3,14 @@
 #ifdef SHARED
 # define SYSCALL_GETTIME(id, tp) \
   ({ long int (*f) (clockid_t, struct timespec *) = __vdso_clock_gettime; \
+  long int v_ret;							  \
   PTR_DEMANGLE (f);							  \
-  f (id, tp); })
+  v_ret = f (id, tp);							  \
+  if (INTERNAL_SYSCALL_ERROR_P (v_ret, )) {				  \
+    __set_errno (INTERNAL_SYSCALL_ERRNO (v_ret, ));			  \
+    v_ret = -1;								  \
+  }									  \
+  v_ret; })
 # define INTERNAL_GETTIME(id, tp) \
   ({ long int (*f) (clockid_t, struct timespec *) = __vdso_clock_gettime; \
   PTR_DEMANGLE (f);							  \

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                                      |    5 +++++
 sysdeps/unix/sysv/linux/clock_gettime.c        |    4 +++-
 sysdeps/unix/sysv/linux/x86_64/clock_gettime.c |    8 +++++++-
 3 files changed, 15 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


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