about summary refs log tree commit diff
path: root/sysdeps/unix/sysv
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2004-03-05 10:29:47 +0000
committerUlrich Drepper <drepper@redhat.com>2004-03-05 10:29:47 +0000
commitafdca0f2a3a18fb0dcfc334c205e0fb96e90e839 (patch)
tree59ba9a29d6174ebbbbe09258ea52e9f956e33c2e /sysdeps/unix/sysv
parent20c37dfde1a836a139f6269e8617260f2b90bf52 (diff)
downloadglibc-afdca0f2a3a18fb0dcfc334c205e0fb96e90e839.tar.gz
glibc-afdca0f2a3a18fb0dcfc334c205e0fb96e90e839.tar.xz
glibc-afdca0f2a3a18fb0dcfc334c205e0fb96e90e839.zip
Update.
	* sysdeps/sparc/sparc64/dl-machine.h: Likewise.
	* sysdeps/sparc/sparc32/dl-machine.h: Likewise.
	* sysdeps/s390/s390-64/dl-machine.h: Likewise.
	* sysdeps/s390/s390-32/dl-machine.h: Likewise.
	* sysdeps/powerpc/powerpc64/dl-machine.h: Likewise.
	* sysdeps/powerpc/powerpc32/dl-machine.c: Likewise.
	* sysdeps/m68k/dl-machine.h: Likewise.
	* sysdeps/ia64/dl-machine.h: Likewise.
	* sysdeps/arm/dl-machine.h: Likewise.
	* sysdeps/alpha/dl-machine.h: Likewise.
Diffstat (limited to 'sysdeps/unix/sysv')
-rw-r--r--sysdeps/unix/sysv/linux/dl-execstack.c17
-rw-r--r--sysdeps/unix/sysv/linux/dl-librecon.h4
-rw-r--r--sysdeps/unix/sysv/linux/dl-origin.c8
-rw-r--r--sysdeps/unix/sysv/linux/dl-osinfo.h4
-rw-r--r--sysdeps/unix/sysv/linux/getclktck.c4
-rw-r--r--sysdeps/unix/sysv/linux/getpagesize.c7
-rw-r--r--sysdeps/unix/sysv/linux/i386/dl-librecon.h4
-rw-r--r--sysdeps/unix/sysv/linux/i386/sigaction.c4
-rw-r--r--sysdeps/unix/sysv/linux/init-first.c4
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S50
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S96
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S127
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S334
-rw-r--r--sysdeps/unix/sysv/linux/prof-freq.c8
14 files changed, 336 insertions, 335 deletions
diff --git a/sysdeps/unix/sysv/linux/dl-execstack.c b/sysdeps/unix/sysv/linux/dl-execstack.c
index 48512ede7d..d3b048192c 100644
--- a/sysdeps/unix/sysv/linux/dl-execstack.c
+++ b/sysdeps/unix/sysv/linux/dl-execstack.c
@@ -31,7 +31,8 @@ internal_function
 _dl_make_stack_executable (void **stack_endp)
 {
   /* This gives us the highest/lowest page that needs to be changed.  */
-  uintptr_t page = (uintptr_t) __libc_stack_end & -(intptr_t) GL(dl_pagesize);
+  uintptr_t page = ((uintptr_t) __libc_stack_end
+		    & -(intptr_t) GLRO(dl_pagesize));
 
   /* Challenge the caller.  */
   if (__builtin_expect (*stack_endp != __libc_stack_end, 0))
@@ -46,7 +47,7 @@ _dl_make_stack_executable (void **stack_endp)
   if (! no_growsdown)
 #  endif
     {
-      if (__builtin_expect (__mprotect ((void *) page, GL(dl_pagesize),
+      if (__builtin_expect (__mprotect ((void *) page, GLRO(dl_pagesize),
 					PROT_READ|PROT_WRITE|PROT_EXEC
 					|PROT_GROWSDOWN) == 0, 1))
 	goto return_success;
@@ -67,8 +68,8 @@ _dl_make_stack_executable (void **stack_endp)
      so as to have extended the GROWSDOWN mapping to lower pages.  */
 
 # if __ASSUME_PROT_GROWSUPDOWN == 0
-  size_t size = GL(dl_pagesize) * 8;
-  page = page + GL(dl_pagesize) - size;
+  size_t size = GLRO(dl_pagesize) * 8;
+  page = page + GLRO(dl_pagesize) - size;
   while (1)
     {
       if (__mprotect ((void *) page, size,
@@ -80,7 +81,7 @@ _dl_make_stack_executable (void **stack_endp)
 	  if (errno != ENOMEM)	/* Unexpected failure mode.  */
 	    return errno;
 
-	  if (size == GL(dl_pagesize))
+	  if (size == GLRO(dl_pagesize))
 	    /* We just tried to mprotect the top hole page and failed.
 	       We are done.  */
 	    break;
@@ -101,7 +102,7 @@ _dl_make_stack_executable (void **stack_endp)
   if (! no_growsup)
 #  endif
     {
-      if (__mprotect ((void *) page, GL(dl_pagesize),
+      if (__mprotect ((void *) page, GLRO(dl_pagesize),
 		      PROT_READ|PROT_WRITE|PROT_EXEC|PROT_GROWSUP) == 0)
 	goto return_success;
 #  if __ASSUME_PROT_GROWSUPDOWN == 0
@@ -121,7 +122,7 @@ _dl_make_stack_executable (void **stack_endp)
      so as to have extended the GROWSUP mapping to higher pages.  */
 
 # if __ASSUME_PROT_GROWSUPDOWN == 0
-  size_t size = GL(dl_pagesize) * 8;
+  size_t size = GLRO(dl_pagesize) * 8;
   while (1)
     {
       if (__mprotect ((void *) page, size,
@@ -133,7 +134,7 @@ _dl_make_stack_executable (void **stack_endp)
 	  if (errno != ENOMEM)	/* Unexpected failure mode.  */
 	    return errno;
 
-	  if (size == GL(dl_pagesize))
+	  if (size == GLRO(dl_pagesize))
 	    /* We just tried to mprotect the lowest hole page and failed.
 	       We are done.  */
 	    break;
diff --git a/sysdeps/unix/sysv/linux/dl-librecon.h b/sysdeps/unix/sysv/linux/dl-librecon.h
index 97de79640d..db46b98fb7 100644
--- a/sysdeps/unix/sysv/linux/dl-librecon.h
+++ b/sysdeps/unix/sysv/linux/dl-librecon.h
@@ -1,5 +1,5 @@
 /* Optional code to distinguish library flavours.
-   Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
+   Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Jakub Jelinek <jakub@redhat.com>, 2001.
 
@@ -40,7 +40,7 @@ _dl_osversion_init (char *assume_kernel)
 	break;
     }
   if (osversion)
-    GL(dl_osversion) = osversion;
+    GLRO(dl_osversion) = osversion;
 }
 
 /* Recognizing extra environment variables.  */
diff --git a/sysdeps/unix/sysv/linux/dl-origin.c b/sysdeps/unix/sysv/linux/dl-origin.c
index 3824681fa7..690492093d 100644
--- a/sysdeps/unix/sysv/linux/dl-origin.c
+++ b/sysdeps/unix/sysv/linux/dl-origin.c
@@ -1,5 +1,5 @@
 /* Find path of executable.
-   Copyright (C) 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
+   Copyright (C) 1998, 1999, 2000, 2002, 2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -59,15 +59,15 @@ _dl_get_origin (void)
       result = (char *) -1;
       /* We use the environment variable LD_ORIGIN_PATH.  If it is set make
 	 a copy and strip out trailing slashes.  */
-      if (GL(dl_origin_path) != NULL)
+      if (GLRO(dl_origin_path) != NULL)
 	{
-	  size_t len = strlen (GL(dl_origin_path));
+	  size_t len = strlen (GLRO(dl_origin_path));
 	  result = (char *) malloc (len + 1);
 	  if (result == NULL)
 	    result = (char *) -1;
 	  else
 	    {
-	      char *cp = __mempcpy (result, GL(dl_origin_path), len);
+	      char *cp = __mempcpy (result, GLRO(dl_origin_path), len);
 	      while (cp > result + 1 && cp[-1] == '/')
 		--cp;
 	      *cp = '\0';
diff --git a/sysdeps/unix/sysv/linux/dl-osinfo.h b/sysdeps/unix/sysv/linux/dl-osinfo.h
index b60a202ff0..5abc3c47c8 100644
--- a/sysdeps/unix/sysv/linux/dl-osinfo.h
+++ b/sysdeps/unix/sysv/linux/dl-osinfo.h
@@ -1,5 +1,5 @@
 /* Operating system specific code  for generic dynamic loader functions.
-   Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -104,6 +104,6 @@ dl_fatal (const char *str)
 	  /* Not sufficent.  */						      \
 	  FATAL ("FATAL: kernel too old\n");				      \
 									      \
-	GL(dl_osversion) = version;					      \
+	GLRO(dl_osversion) = version;					      \
       }									      \
   } while (0)
diff --git a/sysdeps/unix/sysv/linux/getclktck.c b/sysdeps/unix/sysv/linux/getclktck.c
index dc8ec9b50b..f9fece32ff 100644
--- a/sysdeps/unix/sysv/linux/getclktck.c
+++ b/sysdeps/unix/sysv/linux/getclktck.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2000, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 2000, 2002, 2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -28,5 +28,5 @@
 int
 __getclktck ()
 {
-  return GL(dl_clktck) ?: SYSTEM_CLK_TCK;
+  return GLRO(dl_clktck) ?: SYSTEM_CLK_TCK;
 }
diff --git a/sysdeps/unix/sysv/linux/getpagesize.c b/sysdeps/unix/sysv/linux/getpagesize.c
index 4f73e034eb..6d03b3bbf2 100644
--- a/sysdeps/unix/sysv/linux/getpagesize.c
+++ b/sysdeps/unix/sysv/linux/getpagesize.c
@@ -1,4 +1,5 @@
-/* Copyright (C) 1991,1992,1995-1997,2000,2002 Free Software Foundation, Inc.
+/* Copyright (C) 1991,1992,1995-1997,2000,2002,2004
+   Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -25,8 +26,8 @@
 int
 __getpagesize ()
 {
-  if (GL(dl_pagesize) != 0)
-    return GL(dl_pagesize);
+  if (GLRO(dl_pagesize) != 0)
+    return GLRO(dl_pagesize);
 
 #ifdef	EXEC_PAGESIZE
   return EXEC_PAGESIZE;
diff --git a/sysdeps/unix/sysv/linux/i386/dl-librecon.h b/sysdeps/unix/sysv/linux/i386/dl-librecon.h
index f5a9f65166..5e41977dde 100644
--- a/sysdeps/unix/sysv/linux/i386/dl-librecon.h
+++ b/sysdeps/unix/sysv/linux/i386/dl-librecon.h
@@ -1,5 +1,5 @@
 /* Optional code to distinguish library flavours.
-   Copyright (C) 1998, 2001, 2002, 2003 Free Software Foundation, Inc.
+   Copyright (C) 1998, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -51,7 +51,7 @@
 #define EXTRA_LD_ENVVARS \
   case 15:								      \
     if (memcmp (envline, "LIBRARY_VERSION", 15) == 0)			      \
-      GL(dl_correct_cache_id) = envline[16] == '5' ? 2 : 3;		      \
+      GLRO(dl_correct_cache_id) = envline[16] == '5' ? 2 : 3;		      \
     break;								      \
 
 /* Extra unsecure variables.  The names are all stuffed in a single
diff --git a/sysdeps/unix/sysv/linux/i386/sigaction.c b/sysdeps/unix/sysv/linux/i386/sigaction.c
index 8971a86a92..9cb5b6e340 100644
--- a/sysdeps/unix/sysv/linux/i386/sigaction.c
+++ b/sysdeps/unix/sysv/linux/i386/sigaction.c
@@ -1,5 +1,5 @@
 /* POSIX.1 `sigaction' call for Linux/i386.
-   Copyright (C) 1991,95,96,97,98,99,2000,02,03 Free Software Foundation, Inc.
+   Copyright (C) 1991,1995-2000,02,03, 2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -88,7 +88,7 @@ __libc_sigaction (int sig, const struct sigaction *act, struct sigaction *oact)
 	  kact.sa_flags = act->sa_flags;
 	  memcpy (&kact.sa_mask, &act->sa_mask, sizeof (sigset_t));
 
-	  if (GL(dl_sysinfo_dso) == NULL)
+	  if (GLRO(dl_sysinfo_dso) == NULL)
 	    {
 	      kact.sa_flags |= SA_RESTORER;
 
diff --git a/sysdeps/unix/sysv/linux/init-first.c b/sysdeps/unix/sysv/linux/init-first.c
index 7417fd6d0b..f00271255d 100644
--- a/sysdeps/unix/sysv/linux/init-first.c
+++ b/sysdeps/unix/sysv/linux/init-first.c
@@ -1,5 +1,5 @@
 /* Initialization code run first thing by the ELF startup code.  Linux version.
-   Copyright (C) 1995-1999,2000,01,02,03 Free Software Foundation, Inc.
+   Copyright (C) 1995-1999,2000,01,02,03,2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -58,7 +58,7 @@ init (int argc, char **argv, char **envp)
 	 kernel would use a different value.  (In a static program we
 	 don't have this information.)  */
 #ifdef SHARED
-      if (__fpu_control != GL(dl_fpu_control))
+      if (__fpu_control != GLRO(dl_fpu_control))
 #endif
 	__setfpucw (__fpu_control);
     }
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S
index 760e9b5534..d3e9b49cfb 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S
@@ -72,7 +72,7 @@ ENTRY(__getcontext)
 	mfcr	r0
 	stw	r0,_UC_GREGS+(PT_CCR*4)(r3)
 
-	/* Set the return value of getcontext to "success".  R3 is the only 
+	/* Set the return value of getcontext to "success".  R3 is the only
 	   register whose value is not preserved in the saved context.  */
 	li	r0,0
 	stw	r0,_UC_GREGS+(PT_R3*4)(r3)
@@ -121,11 +121,11 @@ ENTRY(__getcontext)
 	mflr    r8
 	bl      _GLOBAL_OFFSET_TABLE_@local-4
 	mflr    r7
-#ifdef SHARED	
-	lwz     r7,_rtld_global@got(r7)
+#ifdef SHARED
+	lwz     r7,_rtld_global_ro@got(r7)
 	mtlr    r8
 	lwz     r7,RTLD_GLOBAL_DL_HWCAP_OFFSET(r7)
-#else	
+#else
 	lwz     r7,_dl_hwcap@got(r7)
 	mtlr    r8
 	lwz     r7,0(r7)
@@ -136,95 +136,95 @@ ENTRY(__getcontext)
 #endif
 	andis.	r7,r7,(PPC_FEATURE_HAS_ALTIVEC >> 16)
 	beq	L(no_vec)
-  
+
 	la	r10,(_UC_VREGS)(r3)
 	la	r9,(_UC_VREGS+16)(r3)
 
-	stvx  v0,0,r10  
+	stvx  v0,0,r10
 	stvx  v1,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v2,0,r10  
+	stvx  v2,0,r10
 	stvx  v3,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v4,0,r10  
+	stvx  v4,0,r10
 	stvx  v5,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v6,0,r10  
+	stvx  v6,0,r10
 	stvx  v7,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v8,0,r10  
+	stvx  v8,0,r10
 	stvx  v9,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v10,0,r10  
+	stvx  v10,0,r10
 	stvx  v11,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v12,0,r10  
+	stvx  v12,0,r10
 	stvx  v13,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v14,0,r10  
+	stvx  v14,0,r10
 	stvx  v15,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v16,0,r10  
+	stvx  v16,0,r10
 	stvx  v17,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v18,0,r10  
+	stvx  v18,0,r10
 	stvx  v11,0,r9
 	addi  r19,r10,32
 	addi  r9,r9,32
 
-	stvx  v20,0,r10  
+	stvx  v20,0,r10
 	stvx  v21,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v22,0,r10  
+	stvx  v22,0,r10
 	stvx  v23,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v24,0,r10  
+	stvx  v24,0,r10
 	stvx  v25,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v26,0,r10  
+	stvx  v26,0,r10
 	stvx  v27,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v28,0,r10  
+	stvx  v28,0,r10
 	stvx  v29,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v30,0,r10  
+	stvx  v30,0,r10
 	stvx  v31,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v10,0,r10  
+	stvx  v10,0,r10
 	stvx  v11,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
-  
+
 	mfvscr	v0
 	mfspr	r0,VRSAVE
 	stvx	v0,0,r10
@@ -301,7 +301,7 @@ ENTRY(__novec_getcontext)
 	mfcr	r0
 	stw	r0,_UC_GREGS+(PT_CCR*4)(r3)
 
-	/* Set the return value of getcontext to "success".  R3 is the only 
+	/* Set the return value of getcontext to "success".  R3 is the only
 	   register whose value is not preserved in the saved context.  */
 	li	r0,0
 	stw	r0,_UC_GREGS+(PT_R3*4)(r3)
@@ -345,7 +345,7 @@ ENTRY(__novec_getcontext)
 	stfd	fp30,_UC_FREGS+(30*8)(r3)
 	stfd	fp31,_UC_FREGS+(31*8)(r3)
 	stfd	fp0,_UC_FREGS+(32*8)(r3)
-	
+
 	addi	r5,r3,_UC_SIGMASK - _UC_REG_SPACE
 	li	r4,0
 	li	r3,SIG_BLOCK
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S
index 11f488a63b..4c92dd7583 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S
@@ -75,7 +75,7 @@ ENTRY(__swapcontext)
 	mfcr	r0
 	stw	r0,_UC_GREGS+(PT_CCR*4)(r3)
 
-	/* Set the return value of swapcontext to "success".  R3 is the only 
+	/* Set the return value of swapcontext to "success".  R3 is the only
 	   register whose value is not preserved in the saved context.  */
 	li	r0,0
 	stw	r0,_UC_GREGS+(PT_R3*4)(r3)
@@ -123,11 +123,11 @@ ENTRY(__swapcontext)
 	mflr    r8
 	bl      _GLOBAL_OFFSET_TABLE_@local-4
 	mflr    r7
-#ifdef SHARED	
-	lwz     r7,_rtld_global@got(r7)
+#ifdef SHARED
+	lwz     r7,_rtld_global_ro@got(r7)
 	mtlr    r8
 	lwz     r7,RTLD_GLOBAL_DL_HWCAP_OFFSET(r7)
-#else	
+#else
 	lwz     r7,_dl_hwcap@got(r7)
 	mtlr    r8
 	lwz     r7,0(r7)
@@ -138,95 +138,95 @@ ENTRY(__swapcontext)
 #endif
 	andis.	r7,r7,(PPC_FEATURE_HAS_ALTIVEC >> 16)
 	beq	L(no_vec)
-  
+
 	la	r10,(_UC_VREGS)(r3)
 	la	r9,(_UC_VREGS+16)(r3)
 
-	stvx  v0,0,r10  
+	stvx  v0,0,r10
 	stvx  v1,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v2,0,r10  
+	stvx  v2,0,r10
 	stvx  v3,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v4,0,r10  
+	stvx  v4,0,r10
 	stvx  v5,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v6,0,r10  
+	stvx  v6,0,r10
 	stvx  v7,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v8,0,r10  
+	stvx  v8,0,r10
 	stvx  v9,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v10,0,r10  
+	stvx  v10,0,r10
 	stvx  v11,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v12,0,r10  
+	stvx  v12,0,r10
 	stvx  v13,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v14,0,r10  
+	stvx  v14,0,r10
 	stvx  v15,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v16,0,r10  
+	stvx  v16,0,r10
 	stvx  v17,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v18,0,r10  
+	stvx  v18,0,r10
 	stvx  v11,0,r9
 	addi  r19,r10,32
 	addi  r9,r9,32
 
-	stvx  v20,0,r10  
+	stvx  v20,0,r10
 	stvx  v21,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v22,0,r10  
+	stvx  v22,0,r10
 	stvx  v23,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v24,0,r10  
+	stvx  v24,0,r10
 	stvx  v25,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v26,0,r10  
+	stvx  v26,0,r10
 	stvx  v27,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v28,0,r10  
+	stvx  v28,0,r10
 	stvx  v29,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v30,0,r10  
+	stvx  v30,0,r10
 	stvx  v31,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	stvx  v10,0,r10  
+	stvx  v10,0,r10
 	stvx  v11,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
-  
+
 	mfvscr	v0
 	mfspr	r0,VRSAVE
 	stvx	v0,0,r10
@@ -260,16 +260,16 @@ L(no_vec):
 	lwz	r0,_UC_GREGS+(PT_MSR*4)(r31)
 	cmpwi	r0,0
 	bne	L(do_sigret)
-	
+
 #ifdef PIC
 	mflr    r8
 	bl      _GLOBAL_OFFSET_TABLE_@local-4
 	mflr    r7
-#ifdef SHARED	
-	lwz     r7,_rtld_global@got(r7)
+#ifdef SHARED
+	lwz     r7,_rtld_global_ro@got(r7)
 	mtlr    r8
 	lwz     r7,RTLD_GLOBAL_DL_HWCAP_OFFSET(r7)
-#else	
+#else
 	lwz     r7,_dl_hwcap@got(r7)
 	mtlr    r8
 	lwz     r7,0(r7)
@@ -281,100 +281,100 @@ L(no_vec):
 	andis.	r7,r7,(PPC_FEATURE_HAS_ALTIVEC >> 16)
 	la	r10,(_UC_VREGS)(r31)
 	beq	L(has_no_vec)
-	
+
 	lwz   r0,(32*16)(r10)
 	li    r9,(32*16)
 	cmpwi r0,0
 	mtspr VRSAVE,r0
-	beq   L(has_no_vec)  
+	beq   L(has_no_vec)
 
 	lvx   v19,r9,r10
 	la    r9,(16)(r10)
 
-	lvx   v0,0,r10  
+	lvx   v0,0,r10
 	lvx   v1,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
 	mtvscr  v19
-	lvx   v2,0,r10  
+	lvx   v2,0,r10
 	lvx   v3,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v4,0,r10  
+	lvx   v4,0,r10
 	lvx   v5,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v6,0,r10  
+	lvx   v6,0,r10
 	lvx   v7,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v8,0,r10  
+	lvx   v8,0,r10
 	lvx   v9,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v10,0,r10  
+	lvx   v10,0,r10
 	lvx   v11,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v12,0,r10  
+	lvx   v12,0,r10
 	lvx   v13,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v14,0,r10  
+	lvx   v14,0,r10
 	lvx   v15,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v16,0,r10  
+	lvx   v16,0,r10
 	lvx   v17,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v18,0,r10  
+	lvx   v18,0,r10
 	lvx   v11,0,r9
 	addi  r19,r10,32
 	addi  r9,r9,32
 
-	lvx   v20,0,r10  
+	lvx   v20,0,r10
 	lvx   v21,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v22,0,r10  
+	lvx   v22,0,r10
 	lvx   v23,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v24,0,r10  
+	lvx   v24,0,r10
 	lvx   v25,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v26,0,r10  
+	lvx   v26,0,r10
 	lvx   v27,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v28,0,r10  
+	lvx   v28,0,r10
 	lvx   v29,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v30,0,r10  
+	lvx   v30,0,r10
 	lvx   v31,0,r9
 	addi  r10,r10,32
 	addi  r9,r9,32
 
-	lvx   v10,0,r10  
+	lvx   v10,0,r10
 	lvx   v11,0,r9
-	
+
 L(has_no_vec):
 	/* Restore the floating-point registers */
 	lfd	fp31,_UC_FREGS+(32*8)(r31)
@@ -522,7 +522,7 @@ ENTRY(__novec_swapcontext)
 	mfcr	r0
 	stw	r0,_UC_GREGS+(PT_CCR*4)(r3)
 
-	/* Set the return value of swapcontext to "success".  R3 is the only 
+	/* Set the return value of swapcontext to "success".  R3 is the only
 	   register whose value is not preserved in the saved context.  */
 	li	r0,0
 	stw	r0,_UC_GREGS+(PT_R3*4)(r3)
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S
index 279a36d68d..c950316b2f 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S
@@ -73,12 +73,12 @@ ENTRY(__novec_getcontext)
   std  r0,(SIGCONTEXT_GP_REGS+(PT_XER*8))(r3)
   mfcr  r0
   std  r0,(SIGCONTEXT_GP_REGS+(PT_CCR*8))(r3)
-  
-  /* Set the return value of swapcontext to "success".  R3 is the only 
+
+  /* Set the return value of swapcontext to "success".  R3 is the only
      register whose value is not preserved in the saved context.  */
   li   r0,0
   std  r0,(SIGCONTEXT_GP_REGS+(PT_R3*8))(r3)
-  
+
   /* Zero fill fields that can't be set in user state or are unused.  */
   std  r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(34*8))(r3)
@@ -87,14 +87,14 @@ ENTRY(__novec_getcontext)
   std  r0,(SIGCONTEXT_GP_REGS+(41*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(42*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(PT_RESULT*8))(r3)
-  
-  /* Set the PT_REGS pointer to the address of sigcontext's gp_regs 
-     field.  Struct pt_regs and elf_gregset_t are the same thing.  
+
+  /* Set the PT_REGS pointer to the address of sigcontext's gp_regs
+     field.  Struct pt_regs and elf_gregset_t are the same thing.
      We kept the regs field for backwards compatibility with
      libraries built before we extended sigcontext.  */
   addi r0,r3,SIGCONTEXT_GP_REGS
   std  r0,SIGCONTEXT_PT_REGS(r3)
-  
+
   stfd  fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r3)
   stfd  fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r3)
   stfd  fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r3)
@@ -145,8 +145,8 @@ ENTRY(__novec_getcontext)
   nop
   li   r3,-1
 #endif
-  
-  ld    r0,128+FRAME_LR_SAVE(r1)  
+
+  ld    r0,128+FRAME_LR_SAVE(r1)
   addi  r1,r1,128
   mtlr  r0
   blr
@@ -159,10 +159,10 @@ compat_symbol (libc, __novec_getcontext, getcontext, GLIBC_2_3)
 	.section	".toc","aw"
 .LC__dl_hwcap:
 #ifdef SHARED
-	.tc _rtld_global[TC],_rtld_global
+	.tc _rtld_global_ro[TC],_rtld_global_ro
 #else
 	.tc _dl_hwcap[TC],_dl_hwcap
-#endif	
+#endif
 	.section ".text"
 
 ENTRY(__getcontext)
@@ -209,12 +209,12 @@ ENTRY(__getcontext)
   std  r0,(SIGCONTEXT_GP_REGS+(PT_XER*8))(r3)
   mfcr  r0
   std  r0,(SIGCONTEXT_GP_REGS+(PT_CCR*8))(r3)
-  
-  /* Set the return value of swapcontext to "success".  R3 is the only 
+
+  /* Set the return value of swapcontext to "success".  R3 is the only
      register whose value is not preserved in the saved context.  */
   li   r0,0
   std  r0,(SIGCONTEXT_GP_REGS+(PT_R3*8))(r3)
-  
+
   /* Zero fill fields that can't be set in user state or are unused.  */
   std  r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(34*8))(r3)
@@ -223,14 +223,14 @@ ENTRY(__getcontext)
   std  r0,(SIGCONTEXT_GP_REGS+(41*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(42*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(PT_RESULT*8))(r3)
-  
-  /* Set the PT_REGS pointer to the address of sigcontext's gp_regs 
-     field.  Struct pt_regs and elf_gregset_t are the same thing.  
+
+  /* Set the PT_REGS pointer to the address of sigcontext's gp_regs
+     field.  Struct pt_regs and elf_gregset_t are the same thing.
      We kept the regs field for backwards compatibility with
      libraries built before we extended sigcontext.  */
   addi r0,r3,SIGCONTEXT_GP_REGS
   std  r0,SIGCONTEXT_PT_REGS(r3)
-  
+
   stfd  fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r3)
   stfd  fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r3)
   stfd  fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r3)
@@ -265,120 +265,120 @@ ENTRY(__getcontext)
   stfd  fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r3)
   stfd  fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r3)
   stfd  fp0,(SIGCONTEXT_FP_REGS+(32*8))(r3)
-  
+
   ld    r5,.LC__dl_hwcap@toc(r2)
   li    r10,0
-#ifdef SHARED  
+#ifdef SHARED
 /* Load _rtld-global._dl_hwcap.  */
-  ld    r5,RTLD_GLOBAL_DL_HWCAP_OFFSET(r5) 
-#else  
+  ld    r5,RTLD_GLOBAL_DL_HWCAP_OFFSET(r5)
+#else
   ld    r5,0(r5) /* Load extern _dl_hwcap.  */
 #endif
   andis.  r5,r5,(PPC_FEATURE_HAS_ALTIVEC >> 16)
   beq   L(has_no_vec)
-  
+
   la    r10,(SIGCONTEXT_V_RESERVE+8)(r3)
   la    r9,(SIGCONTEXT_V_RESERVE+24)(r3)
   clrrdi  r10,r10,4
   clrrdi  r9,r9,4
-  
-  stvx  v0,0,r10  
+
+  stvx  v0,0,r10
   stvx  v1,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v2,0,r10  
+
+  stvx  v2,0,r10
   stvx  v3,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v4,0,r10  
+
+  stvx  v4,0,r10
   stvx  v5,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v6,0,r10  
+
+  stvx  v6,0,r10
   stvx  v7,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v8,0,r10  
+
+  stvx  v8,0,r10
   stvx  v9,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v10,0,r10  
+
+  stvx  v10,0,r10
   stvx  v11,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v12,0,r10  
+
+  stvx  v12,0,r10
   stvx  v13,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v14,0,r10  
+
+  stvx  v14,0,r10
   stvx  v15,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v16,0,r10  
+
+  stvx  v16,0,r10
   stvx  v17,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v18,0,r10  
+
+  stvx  v18,0,r10
   stvx  v11,0,r9
   addi  r19,r10,32
   addi  r9,r9,32
-  
-  stvx  v20,0,r10  
+
+  stvx  v20,0,r10
   stvx  v21,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v22,0,r10  
+
+  stvx  v22,0,r10
   stvx  v23,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v24,0,r10  
+
+  stvx  v24,0,r10
   stvx  v25,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v26,0,r10  
+
+  stvx  v26,0,r10
   stvx  v27,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v28,0,r10  
+
+  stvx  v28,0,r10
   stvx  v29,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v30,0,r10  
+
+  stvx  v30,0,r10
   stvx  v31,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v10,0,r10  
+
+  stvx  v10,0,r10
   stvx  v11,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
+
   mfvscr  v0
   mfspr r0,VRSAVE
   stvx  v0,0,r10
   stw   r0,0(9)
-  
+
 L(has_no_vec):
-/* 
+/*
    Store either a NULL or a quadword aligned pointer to the Vector register
    array into *v_regs.
 */
   std   r10,(SIGCONTEXT_V_REGS_PTR)(r3)
-  
+
   addi  r5,r3,UCONTEXT_SIGMASK
   li  r4,0
   li  r3,SIG_BLOCK
@@ -394,12 +394,11 @@ L(has_no_vec):
   nop
   li   r3,-1
 #endif
-  
-  ld    r0,128+FRAME_LR_SAVE(r1)  
+
+  ld    r0,128+FRAME_LR_SAVE(r1)
   addi  r1,r1,128
   mtlr  r0
   blr
 PSEUDO_END(__getcontext)
 
 versioned_symbol (libc, __getcontext, getcontext, GLIBC_2_3_4)
-
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S
index ab6a6254f9..8e2cc71b0a 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S
@@ -73,12 +73,12 @@ ENTRY(__novec_swapcontext)
   std  r0,(SIGCONTEXT_GP_REGS+(PT_XER*8))(r3)
   mfcr  r0
   std  r0,(SIGCONTEXT_GP_REGS+(PT_CCR*8))(r3)
-  
-  /* Set the return value of swapcontext to "success".  R3 is the only 
+
+  /* Set the return value of swapcontext to "success".  R3 is the only
      register whose value is not preserved in the saved context.  */
   li   r0,0
   std  r0,(SIGCONTEXT_GP_REGS+(PT_R3*8))(r3)
-  
+
   /* Zero fill fields that can't be set in user state or are unused.  */
   std  r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(34*8))(r3)
@@ -87,14 +87,14 @@ ENTRY(__novec_swapcontext)
   std  r0,(SIGCONTEXT_GP_REGS+(41*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(42*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(PT_RESULT*8))(r3)
-  
-  /* Set the PT_REGS pointer to the address of sigcontext gp_regs 
-     field.  Struct pt_regs and elf_gregset_t are the same thing.  
+
+  /* Set the PT_REGS pointer to the address of sigcontext gp_regs
+     field.  Struct pt_regs and elf_gregset_t are the same thing.
      We kept the regs field for backwards compatibility with
      libraries built before we extended sigcontext.  */
   addi r0,r3,SIGCONTEXT_GP_REGS
   std  r0,SIGCONTEXT_PT_REGS(r3)
-  
+
   stfd  fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r3)
   stfd  fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r3)
   stfd  fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r3)
@@ -154,41 +154,41 @@ ENTRY(__novec_swapcontext)
   bne	  L(nv_do_sigret)
 
   lfd  fp0,(SIGCONTEXT_FP_REGS+(32*8))(r31)
-  lfd  fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r31)	
+  lfd  fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r31)
   lfd  fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r31)
   mtfsf  0xff,fp0
-  lfd  fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31)	
+  lfd  fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31)
   lfd  fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r31)
-  lfd  fp27,(SIGCONTEXT_FP_REGS+(PT_R27*8))(r31)	
+  lfd  fp27,(SIGCONTEXT_FP_REGS+(PT_R27*8))(r31)
   lfd  fp26,(SIGCONTEXT_FP_REGS+(PT_R26*8))(r31)
-  lfd  fp25,(SIGCONTEXT_FP_REGS+(PT_R25*8))(r31)	
+  lfd  fp25,(SIGCONTEXT_FP_REGS+(PT_R25*8))(r31)
   lfd  fp24,(SIGCONTEXT_FP_REGS+(PT_R24*8))(r31)
-  lfd  fp23,(SIGCONTEXT_FP_REGS+(PT_R23*8))(r31)	
+  lfd  fp23,(SIGCONTEXT_FP_REGS+(PT_R23*8))(r31)
   lfd  fp22,(SIGCONTEXT_FP_REGS+(PT_R22*8))(r31)
-  lfd  fp21,(SIGCONTEXT_FP_REGS+(PT_R21*8))(r31)	
+  lfd  fp21,(SIGCONTEXT_FP_REGS+(PT_R21*8))(r31)
   lfd  fp20,(SIGCONTEXT_FP_REGS+(PT_R20*8))(r31)
-  lfd  fp19,(SIGCONTEXT_FP_REGS+(PT_R19*8))(r31)	
+  lfd  fp19,(SIGCONTEXT_FP_REGS+(PT_R19*8))(r31)
   lfd  fp18,(SIGCONTEXT_FP_REGS+(PT_R18*8))(r31)
-  lfd  fp17,(SIGCONTEXT_FP_REGS+(PT_R17*8))(r31)	
+  lfd  fp17,(SIGCONTEXT_FP_REGS+(PT_R17*8))(r31)
   lfd  fp16,(SIGCONTEXT_FP_REGS+(PT_R16*8))(r31)
-  lfd  fp15,(SIGCONTEXT_FP_REGS+(PT_R15*8))(r31)	
+  lfd  fp15,(SIGCONTEXT_FP_REGS+(PT_R15*8))(r31)
   lfd  fp14,(SIGCONTEXT_FP_REGS+(PT_R14*8))(r31)
-  lfd  fp13,(SIGCONTEXT_FP_REGS+(PT_R13*8))(r31)	
+  lfd  fp13,(SIGCONTEXT_FP_REGS+(PT_R13*8))(r31)
   lfd  fp12,(SIGCONTEXT_FP_REGS+(PT_R12*8))(r31)
-  lfd  fp11,(SIGCONTEXT_FP_REGS+(PT_R11*8))(r31)	
+  lfd  fp11,(SIGCONTEXT_FP_REGS+(PT_R11*8))(r31)
   lfd  fp10,(SIGCONTEXT_FP_REGS+(PT_R10*8))(r31)
-  lfd  fp9,(SIGCONTEXT_FP_REGS+(PT_R9*8))(r31)	
+  lfd  fp9,(SIGCONTEXT_FP_REGS+(PT_R9*8))(r31)
   lfd  fp8,(SIGCONTEXT_FP_REGS+(PT_R8*8))(r31)
-  lfd  fp7,(SIGCONTEXT_FP_REGS+(PT_R7*8))(r31)	
+  lfd  fp7,(SIGCONTEXT_FP_REGS+(PT_R7*8))(r31)
   lfd  fp6,(SIGCONTEXT_FP_REGS+(PT_R6*8))(r31)
-  lfd  fp5,(SIGCONTEXT_FP_REGS+(PT_R5*8))(r31)	
+  lfd  fp5,(SIGCONTEXT_FP_REGS+(PT_R5*8))(r31)
   lfd  fp4,(SIGCONTEXT_FP_REGS+(PT_R4*8))(r31)
-  lfd  fp3,(SIGCONTEXT_FP_REGS+(PT_R3*8))(r31)	
+  lfd  fp3,(SIGCONTEXT_FP_REGS+(PT_R3*8))(r31)
   lfd  fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r31)
-  lfd  fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r31)	
+  lfd  fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r31)
   lfd  fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r31)
-  
-  ld   r0,(SIGCONTEXT_GP_REGS+(PT_LNK*8))(r31)  
+
+  ld   r0,(SIGCONTEXT_GP_REGS+(PT_LNK*8))(r31)
   ld   r1,(SIGCONTEXT_GP_REGS+(PT_R1*8))(r31)
   mtlr r0
   ld   r2,(SIGCONTEXT_GP_REGS+(PT_R2*8))(r31)
@@ -224,33 +224,33 @@ ENTRY(__novec_swapcontext)
   ld   r28,(SIGCONTEXT_GP_REGS+(PT_R28*8))(r31)
   ld   r29,(SIGCONTEXT_GP_REGS+(PT_R29*8))(r31)
   ld   r30,(SIGCONTEXT_GP_REGS+(PT_R30*8))(r31)
-    
+
   /* Now we branch to the "Next Instruction Pointer" from the saved
-     context.  With the powerpc64 instruction set there is no good way to 
+     context.  With the powerpc64 instruction set there is no good way to
      do this (from user state) without clobbering either the LR or CTR.
-     The makecontext and swapcontext functions depend on the callers 
+     The makecontext and swapcontext functions depend on the callers
      LR being preserved so we use the CTR.  */
   ld   r0,(SIGCONTEXT_GP_REGS+(PT_NIP*8))(r31)
   mtctr r0
   ld   r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r31)
   ld   r31,(SIGCONTEXT_GP_REGS+(PT_R31*8))(r31)
   bctr
-  
+
 L(nv_error_exit):
-  ld    r0,128+FRAME_LR_SAVE(r1)  
+  ld    r0,128+FRAME_LR_SAVE(r1)
   addi  r1,r1,128
   mtlr  r0
   ld    r31,-8(r1)
   blr
 
-  /* At this point we assume that the ucontext was created by a 
-     rt_signal and we should use rt_sigreturn to restore the original 
-     state.  As of the 2.4.21 kernel the ucontext is the first thing 
-     (offset 0) in the rt_signal frame and rt_sigreturn expects the 
-     ucontext address in R1.  Normally the rt-signal trampoline handles 
-     this by popping dummy frame before the rt_signal syscall.  In our 
-     case the stack may not be in its original (signal handler return with 
-     R1 pointing at the dummy frame) state.  We do have the ucontext 
+  /* At this point we assume that the ucontext was created by a
+     rt_signal and we should use rt_sigreturn to restore the original
+     state.  As of the 2.4.21 kernel the ucontext is the first thing
+     (offset 0) in the rt_signal frame and rt_sigreturn expects the
+     ucontext address in R1.  Normally the rt-signal trampoline handles
+     this by popping dummy frame before the rt_signal syscall.  In our
+     case the stack may not be in its original (signal handler return with
+     R1 pointing at the dummy frame) state.  We do have the ucontext
      address in R3, so simply copy R3 to R1 before the syscall.  */
 L(nv_do_sigret):
   mr   r1,r3,
@@ -266,11 +266,11 @@ L(nv_do_sigret):
   bl   JUMPTARGET(__syscall_error)
   nop
   li   r3,-1
-  ld   r0,128+FRAME_LR_SAVE(r1)  
+  ld   r0,128+FRAME_LR_SAVE(r1)
   addi r1,r1,128
   mtlr r0
   blr
-#endif  
+#endif
 
 PSEUDO_END(__novec_swapcontext)
 
@@ -281,12 +281,12 @@ compat_symbol (libc, __novec_swapcontext, swapcontext, GLIBC_2_3)
 	.section	".toc","aw"
 .LC__dl_hwcap:
 #ifdef SHARED
-	.tc _rtld_global[TC],_rtld_global
+	.tc _rtld_global_ro[TC],_rtld_global_ro
 #else
 	.tc _dl_hwcap[TC],_dl_hwcap
 #endif
 	.section ".text"
-	
+
 ENTRY(__swapcontext)
 #ifdef __ASSUME_NEW_RT_SIGRETURN_SYSCALL
   std  r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r3)
@@ -332,12 +332,12 @@ ENTRY(__swapcontext)
   std  r0,(SIGCONTEXT_GP_REGS+(PT_XER*8))(r3)
   mfcr  r0
   std  r0,(SIGCONTEXT_GP_REGS+(PT_CCR*8))(r3)
-  
-  /* Set the return value of swapcontext to "success".  R3 is the only 
+
+  /* Set the return value of swapcontext to "success".  R3 is the only
      register whose value is not preserved in the saved context.  */
   li   r0,0
   std  r0,(SIGCONTEXT_GP_REGS+(PT_R3*8))(r3)
-  
+
   /* Zero fill fields that can't be set in user state or are unused.  */
   std  r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(34*8))(r3)
@@ -346,14 +346,14 @@ ENTRY(__swapcontext)
   std  r0,(SIGCONTEXT_GP_REGS+(41*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(42*8))(r3)
   std  r0,(SIGCONTEXT_GP_REGS+(PT_RESULT*8))(r3)
-  
-  /* Set the PT_REGS pointer to the address of sigcontext gp_regs 
-     field.  Struct pt_regs and elf_gregset_t are the same thing.  
+
+  /* Set the PT_REGS pointer to the address of sigcontext gp_regs
+     field.  Struct pt_regs and elf_gregset_t are the same thing.
      We kept the regs field for backwards compatibility with
      libraries built before we extended sigcontext.  */
   addi r0,r3,SIGCONTEXT_GP_REGS
   std  r0,SIGCONTEXT_PT_REGS(r3)
-  
+
   stfd  fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r3)
   stfd  fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r3)
   stfd  fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r3)
@@ -388,115 +388,115 @@ ENTRY(__swapcontext)
   stfd  fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r3)
   stfd  fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r3)
   stfd  fp0,(SIGCONTEXT_FP_REGS+(32*8))(r3)
-  
+
   ld    r8,.LC__dl_hwcap@toc(r2)
   li    r10,0
-#ifdef SHARED  
+#ifdef SHARED
 /* Load _rtld-global._dl_hwcap.  */
-  ld    r8,RTLD_GLOBAL_DL_HWCAP_OFFSET(r8) 
-#else  
+  ld    r8,RTLD_GLOBAL_DL_HWCAP_OFFSET(r8)
+#else
   ld    r8,0(r8) /* Load extern _dl_hwcap.  */
 #endif
   andis.  r8,r8,(PPC_FEATURE_HAS_ALTIVEC >> 16)
   beq   L(has_no_vec)
-  
+
   la    r10,(SIGCONTEXT_V_RESERVE+8)(r3)
   la    r9,(SIGCONTEXT_V_RESERVE+24)(r3)
   clrrdi  r10,r10,4
   clrrdi  r9,r9,4
-  
-  stvx  v0,0,r10  
+
+  stvx  v0,0,r10
   stvx  v1,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v2,0,r10  
+
+  stvx  v2,0,r10
   stvx  v3,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v4,0,r10  
+
+  stvx  v4,0,r10
   stvx  v5,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v6,0,r10  
+
+  stvx  v6,0,r10
   stvx  v7,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v8,0,r10  
+
+  stvx  v8,0,r10
   stvx  v9,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v10,0,r10  
+
+  stvx  v10,0,r10
   stvx  v11,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v12,0,r10  
+
+  stvx  v12,0,r10
   stvx  v13,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v14,0,r10  
+
+  stvx  v14,0,r10
   stvx  v15,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v16,0,r10  
+
+  stvx  v16,0,r10
   stvx  v17,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v18,0,r10  
+
+  stvx  v18,0,r10
   stvx  v11,0,r9
   addi  r19,r10,32
   addi  r9,r9,32
-  
-  stvx  v20,0,r10  
+
+  stvx  v20,0,r10
   stvx  v21,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v22,0,r10  
+
+  stvx  v22,0,r10
   stvx  v23,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v24,0,r10  
+
+  stvx  v24,0,r10
   stvx  v25,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v26,0,r10  
+
+  stvx  v26,0,r10
   stvx  v27,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v28,0,r10  
+
+  stvx  v28,0,r10
   stvx  v29,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v30,0,r10  
+
+  stvx  v30,0,r10
   stvx  v31,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  stvx  v10,0,r10  
+
+  stvx  v10,0,r10
   stvx  v11,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
+
   mfvscr  v0
   mfspr r0,VRSAVE
   stvx  v0,0,r10
   stw   r0,0(9)
-  
+
 L(has_no_vec):
-/* 
+/*
    Store either a NULL or a quadword aligned pointer to the Vector register
    array into *v_regs.
 */
@@ -524,154 +524,154 @@ L(has_no_vec):
   lwz	  r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r31)
   cmpdi r0,0
   bne	  L(do_sigret)
-  
+
   ld    r8,.LC__dl_hwcap@toc(r2)
   ld    r10,(SIGCONTEXT_V_REGS_PTR)(r31)
-#ifdef SHARED  
+#ifdef SHARED
 /* Load _rtld-global._dl_hwcap.  */
-  ld    r8,RTLD_GLOBAL_DL_HWCAP_OFFSET(r8) 
-#else  
+  ld    r8,RTLD_GLOBAL_DL_HWCAP_OFFSET(r8)
+#else
   ld    r8,0(r8) /* Load extern _dl_hwcap.  */
 #endif
   andis.  r8,r8,(PPC_FEATURE_HAS_ALTIVEC >> 16)
   beq   L(has_no_vec2)
-  
+
   cmpdi r10,0
   beq   L(has_no_vec2)
   lwz   r0,(33*16)(r10)
-  
+
   li    r9,(16*32)
   mtspr VRSAVE,r0
   cmpwi r0,0
-  beq   L(has_no_vec2)  
-  
+  beq   L(has_no_vec2)
+
   lvx   v19,r9,r10
   la    r9,(16)(r10)
-  
-  lvx   v0,0,r10  
+
+  lvx   v0,0,r10
   lvx   v1,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
+
   mtvscr  v19
-  lvx   v2,0,r10  
+  lvx   v2,0,r10
   lvx   v3,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v4,0,r10  
+
+  lvx   v4,0,r10
   lvx   v5,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v6,0,r10  
+
+  lvx   v6,0,r10
   lvx   v7,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v8,0,r10  
+
+  lvx   v8,0,r10
   lvx   v9,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v10,0,r10  
+
+  lvx   v10,0,r10
   lvx   v11,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v12,0,r10  
+
+  lvx   v12,0,r10
   lvx   v13,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v14,0,r10  
+
+  lvx   v14,0,r10
   lvx   v15,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v16,0,r10  
+
+  lvx   v16,0,r10
   lvx   v17,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v18,0,r10  
+
+  lvx   v18,0,r10
   lvx   v11,0,r9
   addi  r19,r10,32
   addi  r9,r9,32
-  
-  lvx   v20,0,r10  
+
+  lvx   v20,0,r10
   lvx   v21,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v22,0,r10  
+
+  lvx   v22,0,r10
   lvx   v23,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v24,0,r10  
+
+  lvx   v24,0,r10
   lvx   v25,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v26,0,r10  
+
+  lvx   v26,0,r10
   lvx   v27,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v28,0,r10  
+
+  lvx   v28,0,r10
   lvx   v29,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v30,0,r10  
+
+  lvx   v30,0,r10
   lvx   v31,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
-  lvx   v10,0,r10  
+
+  lvx   v10,0,r10
   lvx   v11,0,r9
   addi  r10,r10,32
   addi  r9,r9,32
-  
+
 L(has_no_vec2):
 
   lfd  fp0,(SIGCONTEXT_FP_REGS+(32*8))(r31)
-  lfd  fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r31)	
+  lfd  fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r31)
   lfd  fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r31)
   mtfsf  0xff,fp0
-  lfd  fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31)	
+  lfd  fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31)
   lfd  fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r31)
-  lfd  fp27,(SIGCONTEXT_FP_REGS+(PT_R27*8))(r31)	
+  lfd  fp27,(SIGCONTEXT_FP_REGS+(PT_R27*8))(r31)
   lfd  fp26,(SIGCONTEXT_FP_REGS+(PT_R26*8))(r31)
-  lfd  fp25,(SIGCONTEXT_FP_REGS+(PT_R25*8))(r31)	
+  lfd  fp25,(SIGCONTEXT_FP_REGS+(PT_R25*8))(r31)
   lfd  fp24,(SIGCONTEXT_FP_REGS+(PT_R24*8))(r31)
-  lfd  fp23,(SIGCONTEXT_FP_REGS+(PT_R23*8))(r31)	
+  lfd  fp23,(SIGCONTEXT_FP_REGS+(PT_R23*8))(r31)
   lfd  fp22,(SIGCONTEXT_FP_REGS+(PT_R22*8))(r31)
-  lfd  fp21,(SIGCONTEXT_FP_REGS+(PT_R21*8))(r31)	
+  lfd  fp21,(SIGCONTEXT_FP_REGS+(PT_R21*8))(r31)
   lfd  fp20,(SIGCONTEXT_FP_REGS+(PT_R20*8))(r31)
-  lfd  fp19,(SIGCONTEXT_FP_REGS+(PT_R19*8))(r31)	
+  lfd  fp19,(SIGCONTEXT_FP_REGS+(PT_R19*8))(r31)
   lfd  fp18,(SIGCONTEXT_FP_REGS+(PT_R18*8))(r31)
-  lfd  fp17,(SIGCONTEXT_FP_REGS+(PT_R17*8))(r31)	
+  lfd  fp17,(SIGCONTEXT_FP_REGS+(PT_R17*8))(r31)
   lfd  fp16,(SIGCONTEXT_FP_REGS+(PT_R16*8))(r31)
-  lfd  fp15,(SIGCONTEXT_FP_REGS+(PT_R15*8))(r31)	
+  lfd  fp15,(SIGCONTEXT_FP_REGS+(PT_R15*8))(r31)
   lfd  fp14,(SIGCONTEXT_FP_REGS+(PT_R14*8))(r31)
-  lfd  fp13,(SIGCONTEXT_FP_REGS+(PT_R13*8))(r31)	
+  lfd  fp13,(SIGCONTEXT_FP_REGS+(PT_R13*8))(r31)
   lfd  fp12,(SIGCONTEXT_FP_REGS+(PT_R12*8))(r31)
-  lfd  fp11,(SIGCONTEXT_FP_REGS+(PT_R11*8))(r31)	
+  lfd  fp11,(SIGCONTEXT_FP_REGS+(PT_R11*8))(r31)
   lfd  fp10,(SIGCONTEXT_FP_REGS+(PT_R10*8))(r31)
-  lfd  fp9,(SIGCONTEXT_FP_REGS+(PT_R9*8))(r31)	
+  lfd  fp9,(SIGCONTEXT_FP_REGS+(PT_R9*8))(r31)
   lfd  fp8,(SIGCONTEXT_FP_REGS+(PT_R8*8))(r31)
-  lfd  fp7,(SIGCONTEXT_FP_REGS+(PT_R7*8))(r31)	
+  lfd  fp7,(SIGCONTEXT_FP_REGS+(PT_R7*8))(r31)
   lfd  fp6,(SIGCONTEXT_FP_REGS+(PT_R6*8))(r31)
-  lfd  fp5,(SIGCONTEXT_FP_REGS+(PT_R5*8))(r31)	
+  lfd  fp5,(SIGCONTEXT_FP_REGS+(PT_R5*8))(r31)
   lfd  fp4,(SIGCONTEXT_FP_REGS+(PT_R4*8))(r31)
-  lfd  fp3,(SIGCONTEXT_FP_REGS+(PT_R3*8))(r31)	
+  lfd  fp3,(SIGCONTEXT_FP_REGS+(PT_R3*8))(r31)
   lfd  fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r31)
-  lfd  fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r31)	
+  lfd  fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r31)
   lfd  fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r31)
-  
-  ld   r0,(SIGCONTEXT_GP_REGS+(PT_LNK*8))(r31)  
+
+  ld   r0,(SIGCONTEXT_GP_REGS+(PT_LNK*8))(r31)
   ld   r1,(SIGCONTEXT_GP_REGS+(PT_R1*8))(r31)
   mtlr r0
   ld   r2,(SIGCONTEXT_GP_REGS+(PT_R2*8))(r31)
@@ -707,33 +707,33 @@ L(has_no_vec2):
   ld   r28,(SIGCONTEXT_GP_REGS+(PT_R28*8))(r31)
   ld   r29,(SIGCONTEXT_GP_REGS+(PT_R29*8))(r31)
   ld   r30,(SIGCONTEXT_GP_REGS+(PT_R30*8))(r31)
-    
+
   /* Now we branch to the "Next Instruction Pointer" from the saved
-     context.  With the powerpc64 instruction set there is no good way to 
+     context.  With the powerpc64 instruction set there is no good way to
      do this (from user state) without clobbering either the LR or CTR.
-     The makecontext and swapcontext functions depend on the callers 
+     The makecontext and swapcontext functions depend on the callers
      LR being preserved so we use the CTR.  */
   ld   r0,(SIGCONTEXT_GP_REGS+(PT_NIP*8))(r31)
   mtctr r0
   ld   r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r31)
   ld   r31,(SIGCONTEXT_GP_REGS+(PT_R31*8))(r31)
   bctr
-  
+
 L(error_exit):
-  ld    r0,128+FRAME_LR_SAVE(r1)  
+  ld    r0,128+FRAME_LR_SAVE(r1)
   addi  r1,r1,128
   mtlr  r0
   ld    r31,-8(r1)
   blr
 
-  /* At this point we assume that the ucontext was created by a 
-     rt_signal and we should use rt_sigreturn to restore the original 
-     state.  As of the 2.4.21 kernel the ucontext is the first thing 
-     (offset 0) in the rt_signal frame and rt_sigreturn expects the 
-     ucontext address in R1.  Normally the rt-signal trampoline handles 
-     this by popping dummy frame before the rt_signal syscall.  In our 
-     case the stack may not be in its original (signal handler return with 
-     R1 pointing at the dummy frame) state.  We do have the ucontext 
+  /* At this point we assume that the ucontext was created by a
+     rt_signal and we should use rt_sigreturn to restore the original
+     state.  As of the 2.4.21 kernel the ucontext is the first thing
+     (offset 0) in the rt_signal frame and rt_sigreturn expects the
+     ucontext address in R1.  Normally the rt-signal trampoline handles
+     this by popping dummy frame before the rt_signal syscall.  In our
+     case the stack may not be in its original (signal handler return with
+     R1 pointing at the dummy frame) state.  We do have the ucontext
      address in R3, so simply copy R3 to R1 before the syscall.  */
 L(do_sigret):
   mr   r1,r3,
@@ -749,11 +749,11 @@ L(do_sigret):
   bl   JUMPTARGET(__syscall_error)
   nop
   li   r3,-1
-  ld   r0,128+FRAME_LR_SAVE(r1)  
+  ld   r0,128+FRAME_LR_SAVE(r1)
   addi r1,r1,128
   mtlr r0
   blr
-#endif  
+#endif
 
 PSEUDO_END(__swapcontext)
 
diff --git a/sysdeps/unix/sysv/linux/prof-freq.c b/sysdeps/unix/sysv/linux/prof-freq.c
index a67c179700..621a4c4d25 100644
--- a/sysdeps/unix/sysv/linux/prof-freq.c
+++ b/sysdeps/unix/sysv/linux/prof-freq.c
@@ -1,5 +1,5 @@
 /* Determine realtime clock frequency.
-   Copyright (C) 2003 Free Software Foundation, Inc.
+   Copyright (C) 2003, 2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -27,10 +27,10 @@ int
 __profile_frequency (void)
 {
 #ifdef __ASSUME_AT_CLKTCK
-  return GL(dl_clktck);
+  return GLRO(dl_clktck);
 #else
-  if (GL(dl_clktck) != 0)
-    return GL(dl_clktck);
+  if (GLRO(dl_clktck) != 0)
+    return GLRO(dl_clktck);
 
   struct itimerval tim;