This is the mail archive of the binutils@sourceware.org mailing list for the binutils 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] | |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 This patch provides support in BFD and readelf for the new note NT_PPC_VMX added by Roland McGrath here: http://sourceware.org/ml/binutils/2007-10/msg00261.html Is it OK? Thanks and regards, - -- Carlos Eduardo Seo Software Engineer IBM Linux Technology Center -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.7 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHGQZKqvq7Aov/qQARAmjrAJ9GxzOTjzJ2bAYX7R9USl0q05LB5gCeLQ8l O3FdeAJYM6jmhAf1ATsKbEs= =Falj -----END PGP SIGNATURE-----
2007-10-19 Carlos Eduardo Seo <cseo@linux.vnet.ibm.com>
* bfd/elf.c (elfcore_grok_ppc_vmx): Added.
(elfcore_grok_note): Added note NT_PPC_VMX.
(elfcore_write_ppc_vmx): Added.
* bfd/elf-bfd.h (elfcore_write_ppc_vmx): Declare.
* binutils/readelf.c (get_note_type): Added note
NT_PPC_VMX
Index: src/bfd/elf.c
===================================================================
--- src.orig/bfd/elf.c 2007-10-19 13:35:11.000000000 +0000
+++ src/bfd/elf.c 2007-10-19 13:37:44.000000000 +0000
@@ -7449,6 +7449,13 @@
return elfcore_make_note_pseudosection (abfd, ".reg-xfp", note);
}
+static bfd_boolean
+elfcore_grok_ppc_vmx (bfd *abfd, Elf_Internal_Note *note)
+{
+ return elfcore_make_note_pseudosection (abfd, ".reg-ppc-vmx", note);
+}
+
+
#if defined (HAVE_PRPSINFO_T)
typedef prpsinfo_t elfcore_psinfo_t;
#if defined (HAVE_PRPSINFO32_T) /* Sparc64 cross Sparc32 */
@@ -7796,6 +7803,13 @@
else
return TRUE;
+ case NT_PPC_VMX:
+ if (note->namesz == 6
+ && strcmp (note->namedata, "LINUX") == 0)
+ return elfcore_grok_ppc_vmx (abfd, note);
+ else
+ return TRUE;
+
case NT_PRPSINFO:
case NT_PSINFO:
if (bed->elf_backend_grok_psinfo)
@@ -8350,6 +8364,18 @@
note_name, NT_PRXFPREG, xfpregs, size);
}
+char *
+elfcore_write_ppc_vmx (bfd *abfd,
+ char *buf,
+ int *bufsiz,
+ const void *ppc_vmx,
+ int size)
+{
+ char *note_name = "LINUX";
+ return elfcore_write_note (abfd, buf, bufsiz,
+ note_name, NT_PPC_VMX, ppc_vmx, size);
+}
+
static bfd_boolean
elf_parse_notes (bfd *abfd, char *buf, size_t size, file_ptr offset)
{
Index: src/bfd/elf-bfd.h
===================================================================
--- src.orig/bfd/elf-bfd.h 2007-10-19 13:46:28.000000000 +0000
+++ src/bfd/elf-bfd.h 2007-10-19 13:47:13.000000000 +0000
@@ -2009,6 +2009,8 @@
(bfd *, char *, int *, const void *, int);
extern char *elfcore_write_prxfpreg
(bfd *, char *, int *, const void *, int);
+extern char *elfcore_write_ppc_vmx
+ (bfd *, char *, int *, const void *, int);
extern char *elfcore_write_lwpstatus
(bfd *, char *, int *, long, int, const void *);
Index: src/binutils/readelf.c
===================================================================
--- src.orig/binutils/readelf.c 2007-10-19 16:18:17.000000000 +0000
+++ src/binutils/readelf.c 2007-10-19 16:20:18.000000000 +0000
@@ -9280,6 +9280,8 @@
return _("NT_TASKSTRUCT (task structure)");
case NT_PRXFPREG:
return _("NT_PRXFPREG (user_xfpregs structure)");
+ case NT_PPC_VMX:
+ return _("NT_PPC_VMX (ppc Altivec registers)");
case NT_PSTATUS:
return _("NT_PSTATUS (pstatus structure)");
case NT_FPREGS:
Attachment:
nt_altivec.diff.sig
Description: Binary data
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |