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]

two more linux core notes


I happened to notice that the Linux kernel can create a couple more core
notes that readelf does not understand.

This patch adds the needed constants to elf/common.h, and updates
readelf to recognize the notes.  I did not attempt to decode the note
contents.

Built and tested on x86-64 Fedora 16.
Ok?

Tom

2012-10-29  Tom Tromey  <tromey@redhat.com>

	* readelf.c (get_note_type): Handle NT_386_TLS, NT_386_IOPERM.

2012-10-29  Tom Tromey  <tromey@redhat.com>

	* common.h (NT_386_TLS, NT_386_IOPERM): New defines.

diff --git a/binutils/readelf.c b/binutils/readelf.c
index b4f9f4e..caec96a 100644
--- a/binutils/readelf.c
+++ b/binutils/readelf.c
@@ -12623,6 +12623,10 @@ get_note_type (unsigned e_type)
 	return _("NT_PPC_VMX (ppc Altivec registers)");
       case NT_PPC_VSX:
 	return _("NT_PPC_VSX (ppc VSX registers)");
+      case NT_386_TLS:
+	return _("NT_386_TLS (x86 TLS information)");
+      case NT_386_IOPERM:
+	return _("NT_386_IOPERM (x86 I/O permissions)");
       case NT_X86_XSTATE:
 	return _("NT_X86_XSTATE (x86 XSAVE extended state)");
       case NT_S390_HIGH_GPRS:
diff --git a/include/elf/common.h b/include/elf/common.h
index be228cd..244e27f 100644
--- a/include/elf/common.h
+++ b/include/elf/common.h
@@ -529,6 +529,10 @@
 					/*   note name must be "LINUX".  */
 #define NT_PPC_VSX	0x102		/* PowerPC VSX registers */
 					/*   note name must be "LINUX".  */
+#define NT_386_TLS	0x200		/* x86 TLS information */
+					/*   note name must be "LINUX".  */
+#define NT_386_IOPERM	0x201		/* x86 io permissions */
+					/*   note name must be "LINUX".  */
 #define NT_X86_XSTATE	0x202		/* x86 XSAVE extended state */
 					/*   note name must be "LINUX".  */
 #define NT_S390_HIGH_GPRS 0x300		/* S/390 upper halves of GPRs  */


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