[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] Add suspend_cancel flag to linux elf notes.



# HG changeset patch
# User kfraser@xxxxxxxxxxxxxxxxxxxxx
# Date 1172655662 0
# Node ID 9149ef0e61ce24ba3a12c27d0cfd7de6b86aff43
# Parent  0ba4f202d504ce547f5be400bd6a9c5a6e76452d
Add suspend_cancel flag to linux elf notes.

Signed-off-by: Brendan Cully <brendan@xxxxxxxxx>
---
 linux-2.6-xen-sparse/arch/i386/kernel/head-xen.S   |    1 +
 linux-2.6-xen-sparse/arch/x86_64/kernel/head-xen.S |    1 +
 tools/xcutils/readnotes.c                          |    3 +++
 xen/common/libelf/libelf-dominfo.c                 |    1 +
 xen/include/public/elfnote.h                       |    7 ++++++-
 5 files changed, 12 insertions(+), 1 deletion(-)

diff -r 0ba4f202d504 -r 9149ef0e61ce 
linux-2.6-xen-sparse/arch/i386/kernel/head-xen.S
--- a/linux-2.6-xen-sparse/arch/i386/kernel/head-xen.S  Wed Feb 28 09:39:23 
2007 +0000
+++ b/linux-2.6-xen-sparse/arch/i386/kernel/head-xen.S  Wed Feb 28 09:41:02 
2007 +0000
@@ -206,3 +206,4 @@ ENTRY(cpu_gdt_table)
        ELFNOTE(Xen, XEN_ELFNOTE_L1_MFN_VALID,   .long,  
_PAGE_PRESENT,_PAGE_PRESENT)
 #endif
        ELFNOTE(Xen, XEN_ELFNOTE_LOADER,         .asciz, "generic")
+       ELFNOTE(Xen, XEN_ELFNOTE_SUSPEND_CANCEL, .long,  1)
diff -r 0ba4f202d504 -r 9149ef0e61ce 
linux-2.6-xen-sparse/arch/x86_64/kernel/head-xen.S
--- a/linux-2.6-xen-sparse/arch/x86_64/kernel/head-xen.S        Wed Feb 28 
09:39:23 2007 +0000
+++ b/linux-2.6-xen-sparse/arch/x86_64/kernel/head-xen.S        Wed Feb 28 
09:41:02 2007 +0000
@@ -186,3 +186,4 @@ ENTRY(empty_zero_page)
        ELFNOTE(Xen, XEN_ELFNOTE_L1_MFN_VALID,   .quad,  
_PAGE_PRESENT,_PAGE_PRESENT)
        ELFNOTE(Xen, XEN_ELFNOTE_FEATURES,       .asciz, 
"writable_page_tables|writable_descriptor_tables|auto_translated_physmap|pae_pgdir_above_4gb|supervisor_mode_kernel")
        ELFNOTE(Xen, XEN_ELFNOTE_LOADER,         .asciz, "generic")
+       ELFNOTE(Xen, XEN_ELFNOTE_SUSPEND_CANCEL, .long,  1)
diff -r 0ba4f202d504 -r 9149ef0e61ce tools/xcutils/readnotes.c
--- a/tools/xcutils/readnotes.c Wed Feb 28 09:39:23 2007 +0000
+++ b/tools/xcutils/readnotes.c Wed Feb 28 09:41:02 2007 +0000
@@ -102,6 +102,9 @@ static int print_notes(struct elf_binary
                        break;
                case XEN_ELFNOTE_HV_START_LOW:
                        print_numeric_note("HV_START_LOW", elf , note);
+                       break;
+               case XEN_ELFNOTE_SUSPEND_CANCEL:
+                       print_numeric_note("SUSPEND_CANCEL", elf, note);
                        break;
                case XEN_ELFNOTE_L1_MFN_VALID:
                        print_l1_mfn_valid_note("L1_MFN_VALID", elf , note);
diff -r 0ba4f202d504 -r 9149ef0e61ce xen/common/libelf/libelf-dominfo.c
--- a/xen/common/libelf/libelf-dominfo.c        Wed Feb 28 09:39:23 2007 +0000
+++ b/xen/common/libelf/libelf-dominfo.c        Wed Feb 28 09:41:02 2007 +0000
@@ -99,6 +99,7 @@ int elf_xen_parse_note(struct elf_binary
         [XEN_ELFNOTE_PAE_MODE] = { "PAE_MODE", 1},
         [XEN_ELFNOTE_FEATURES] = { "FEATURES", 1},
         [XEN_ELFNOTE_BSD_SYMTAB] = { "BSD_SYMTAB", 1},
+        [XEN_ELFNOTE_SUSPEND_CANCEL] = { "SUSPEND_CANCEL", 0 },
     };
 /* *INDENT-ON* */
 
diff -r 0ba4f202d504 -r 9149ef0e61ce xen/include/public/elfnote.h
--- a/xen/include/public/elfnote.h      Wed Feb 28 09:39:23 2007 +0000
+++ b/xen/include/public/elfnote.h      Wed Feb 28 09:41:02 2007 +0000
@@ -157,9 +157,14 @@
 #define XEN_ELFNOTE_L1_MFN_VALID  13
 
 /*
+ * Whether or not the guest supports cooperative suspend cancellation.
+ */
+#define XEN_ELFNOTE_SUSPEND_CANCEL 14
+
+/*
  * The number of the highest elfnote defined.
  */
-#define XEN_ELFNOTE_MAX XEN_ELFNOTE_L1_MFN_VALID
+#define XEN_ELFNOTE_MAX XEN_ELFNOTE_SUSPEND_CANCEL
 
 /*
  * System information exported through crash notes.

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.