Skip to content

Commit

Permalink
2002-09-29 Roland McGrath <roland@redhat.com>
Browse files Browse the repository at this point in the history
	* sysdeps/unix/sysv/linux/x86_64/sysdep.S [USE_TLS && HAVE___THREAD]:
	Define errno in .tbss.
	* sysdeps/unix/x86_64/sysdep.S [USE_TLS && HAVE___THREAD]: Use TLS
	access for setting errno.
  • Loading branch information
Roland McGrath committed Sep 29, 2002
1 parent 330fad2 commit cc590e1
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion sysdeps/unix/sysv/linux/x86_64/sysdep.S
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,30 @@
02111-1307 USA. */

#include <sysdep.h>
#include <tls.h>

/* The Linux version is in fact x86-64/ELF and the start.? file for this
system (sysdeps/x86_64/elf/start.S) is also used by The Hurd. This file
must not contain the definition of the `errno' variable, we have to
define it somewhere else.
...and this place is here. */
#if USE_TLS && HAVE___THREAD
.section .tbss
#else
.bss
#endif
.globl errno
.type errno,@object
.size errno,4
.globl _errno
.type _errno,@object
.size _errno,4
.align 4
errno:
_errno:
.space 4
weak_alias (errno, _errno)


/* The following code is only used in the shared library when we
compile the reentrant version. Otherwise each system call defines
Expand Down

0 comments on commit cc590e1

Please sign in to comment.