This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
[PATCH] alpha, ia64, m68k, mips, sh, sparc: *_gnu_pltenter shouldallow modification of struct La_*_regs.
- From: Carlos O'Donell <carlos_odonell at mentor dot com>
- To: libc-alpha <libc-alpha at sourceware dot org>, David Miller<davem at davemloft dot net>, "Schwinge, Thomas" <Thomas_Schwinge at mentor dot com>,"Joseph S. Myers" <joseph at codesourcery dot com>, Richard Henderson<rth at twiddle dot net>, Mike Frysinger <vapier at gentoo dot org>
- Date: Wed, 15 Aug 2012 20:34:01 -0400
- Subject: [PATCH] alpha, ia64, m68k, mips, sh, sparc: *_gnu_pltenter shouldallow modification of struct La_*_regs.
The *_gnu_pltenter interface allows the modification of the incoming
set of registers in struct La_*_regs, that is to say that the 5th
argument of la_*_pltenter() is non-constant.
This was not always the case, but it is the case now and has been
since it was silently changed in commit
2413fdba7a02ba8916f75d17199a6e9133a8f7b0.
Removing const from the 5th argument conforms with the Solaris interface:
http://docs.oracle.com/cd/E19082-01/819-0690/chapter6-1242/index.html
Removing const for alpha, ia64, m68k, mips, sh, and sparc conforms
with what the other machines in glibc are already doing.
I haven't tested this, but I don't think anything should go wrong
given the wide usage of the non-const version right now. We could also
do with a better test case that does something with the registers.
For now I'm content to cleanup the definition in ldsodefs.h.
OK to commit?
ports/ChangeLog.alpha
2012-08-15 Carlos O'Donell <carlos_odonell@mentor.com>
* sysdeps/alpha/ldsodefs.h (ARCH_PLTENTER_MEMBERS):
struct La_alpha_regs is not const.
ports/ChangeLog.ia64
2012-08-15 Carlos O'Donell <carlos_odonell@mentor.com>
* sysdeps/ia64/ldsodefs.h (ARCH_PLTENTER_MEMBERS):
struct La_ia64_regs is not constant.
ports/ChangeLog.m68k
2012-08-15 Carlos O'Donell <carlos_odonell@mentor.com>
* sysdeps/m68k/ldsodefs.h (ARCH_PLTENTER_MEMBERS):
struct La_m68k_regs is not constant.
ports/ChangeLog.mips
2012-08-15 Carlos O'Donell <carlos_odonell@mentor.com>
* sysdeps/mips/ldsodefs.h (ARCH_PLTENTER_MEMBERS):
struct La_mips_32_regs and struct La_mips_64_regs are
not constant.
ChangeLog
2012-08-15 Carlos O'Donell <carlos_odonell@mentor.com>
* sysdeps/sh/ldsodefs.h (ARCH_PLTENTER_MEMBERS):
struct La_sh_regs is not constant.
* sysdeps/sparc/ldsodefs.h (ARCH_PLTENTER_MEMBERS):
struct La_sparc32_regs and struct La_sparc64_regs are
not constant.
diff --git a/ports/sysdeps/alpha/ldsodefs.h b/ports/sysdeps/alpha/ldsodefs.h
index 478bf23..464e84e 100644
--- a/ports/sysdeps/alpha/ldsodefs.h
+++ b/ports/sysdeps/alpha/ldsodefs.h
@@ -26,7 +26,7 @@ struct La_alpha_retval;
#define ARCH_PLTENTER_MEMBERS \
Elf64_Addr (*alpha_gnu_pltenter) (Elf64_Sym *, unsigned int, \
uintptr_t *, uintptr_t *, \
- const struct La_alpha_regs *, \
+ struct La_alpha_regs *, \
unsigned int *, const char *name, \
long int *framesizep);
diff --git a/ports/sysdeps/ia64/ldsodefs.h b/ports/sysdeps/ia64/ldsodefs.h
index 269319e..d5fde93 100644
--- a/ports/sysdeps/ia64/ldsodefs.h
+++ b/ports/sysdeps/ia64/ldsodefs.h
@@ -26,7 +26,7 @@ struct La_ia64_retval;
#define ARCH_PLTENTER_MEMBERS \
Elf64_Addr (*ia64_gnu_pltenter) (Elf64_Sym *, unsigned int, \
uintptr_t *, uintptr_t *, \
- const struct La_ia64_regs *, \
+ struct La_ia64_regs *, \
unsigned int *, const char *name, \
long int *framesizep);
diff --git a/ports/sysdeps/m68k/ldsodefs.h b/ports/sysdeps/m68k/ldsodefs.h
index bc8d540..41cc34f 100644
--- a/ports/sysdeps/m68k/ldsodefs.h
+++ b/ports/sysdeps/m68k/ldsodefs.h
@@ -26,7 +26,7 @@ struct La_m68k_retval;
#define ARCH_PLTENTER_MEMBERS \
Elf32_Addr (*m68k_gnu_pltenter) (Elf32_Sym *, unsigned int, \
uintptr_t *, uintptr_t *, \
- const struct La_m68k_regs *, \
+ struct La_m68k_regs *, \
unsigned int *, const char *name, \
long int *framesizep);
diff --git a/ports/sysdeps/mips/ldsodefs.h b/ports/sysdeps/mips/ldsodefs.h
index ab4e9ef..791e618 100644
--- a/ports/sysdeps/mips/ldsodefs.h
+++ b/ports/sysdeps/mips/ldsodefs.h
@@ -29,17 +29,17 @@ struct La_mips_64_retval;
#define ARCH_PLTENTER_MEMBERS \
Elf32_Addr (*mips_o32_gnu_pltenter) (Elf32_Sym *, unsigned int, \
uintptr_t *, uintptr_t *, \
- const struct La_mips_32_regs *, \
+ struct La_mips_32_regs *, \
unsigned int *, const char *name, \
long int *framesizep); \
Elf32_Addr (*mips_n32_gnu_pltenter) (Elf32_Sym *, unsigned int, \
uintptr_t *, uintptr_t *, \
- const struct La_mips_64_regs *, \
+ struct La_mips_64_regs *, \
unsigned int *, const char *name, \
long int *framesizep); \
Elf64_Addr (*mips_n64_gnu_pltenter) (Elf64_Sym *, unsigned int, \
uintptr_t *, uintptr_t *, \
- const struct La_mips_64_regs *, \
+ struct La_mips_64_regs *, \
unsigned int *, const char *name, \
long int *framesizep);
diff --git a/sysdeps/sh/ldsodefs.h b/sysdeps/sh/ldsodefs.h
index 66d1e2f..74c0f41 100644
--- a/sysdeps/sh/ldsodefs.h
+++ b/sysdeps/sh/ldsodefs.h
@@ -26,7 +26,7 @@ struct La_sh_retval;
#define ARCH_PLTENTER_MEMBERS \
uintptr_t (*sh_gnu_pltenter) (Elf32_Sym *, unsigned int, uintptr_t *, \
- uintptr_t *, const struct La_sh_regs *, \
+ uintptr_t *, struct La_sh_regs *, \
unsigned int *, const char *name, \
long int *framesizep)
diff --git a/sysdeps/sparc/ldsodefs.h b/sysdeps/sparc/ldsodefs.h
index 2cfdc49..dc68860 100644
--- a/sysdeps/sparc/ldsodefs.h
+++ b/sysdeps/sparc/ldsodefs.h
@@ -29,12 +29,12 @@ struct La_sparc64_retval;
#define ARCH_PLTENTER_MEMBERS \
Elf32_Addr (*sparc32_gnu_pltenter) (Elf32_Sym *, unsigned int, \
uintptr_t *, uintptr_t *, \
- const struct La_sparc32_regs *, \
+ struct La_sparc32_regs *, \
unsigned int *, const char *name, \
long int *framesizep); \
Elf64_Addr (*sparc64_gnu_pltenter) (Elf64_Sym *, unsigned int, \
uintptr_t *, uintptr_t *, \
- const struct La_sparc64_regs *, \
+ struct La_sparc64_regs *, \
unsigned int *, const char *name, \
long int *framesizep)
---
Cheers,
Carlos.
--
Carlos O'Donell
Mentor Graphics / CodeSourcery
carlos_odonell@mentor.com
carlos@codesourcery.com
+1 (613) 963 1026
- Follow-Ups:
- Re: [PATCH] alpha, ia64, m68k, mips, sh, sparc: *_gnu_pltentershould allow modification of struct La_*_regs.
- Re: [PATCH] alpha, ia64, m68k, mips, sh, sparc: *_gnu_pltenter should allow modification of struct La_*_regs.
- Re: [PATCH] alpha, ia64, m68k, mips, sh, sparc: *_gnu_pltentershould allow modification of struct La_*_regs.
- Re: [PATCH] alpha, ia64, m68k, mips, sh, sparc: *_gnu_pltenter shouldallow modification of struct La_*_regs.
- Re: [PATCH] alpha, ia64, m68k, mips, sh, sparc: *_gnu_pltenter shouldallow modification of struct La_*_regs.
- Re: [PATCH] alpha, ia64, m68k, mips, sh, sparc: *_gnu_pltenter shouldallow modification of struct La_*_regs.