xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Roger Pau Monne <roger.pau@citrix.com>
To: xen-devel@lists.xenproject.org
Cc: Wei Liu <wei.liu2@citrix.com>,
	Ian Jackson <ian.jackson@eu.citrix.com>,
	Ian Campbell <ian.campbell@citrix.com>,
	Roger Pau Monne <roger.pau@citrix.com>
Subject: [PATCH v2 1/4] xen/elfnotes: check phys_entry against UNSET_ADDR32
Date: Fri, 15 Jan 2016 15:59:40 +0100	[thread overview]
Message-ID: <1452869983-75956-2-git-send-email-roger.pau@citrix.com> (raw)
In-Reply-To: <1452869983-75956-1-git-send-email-roger.pau@citrix.com>

And introduce UNSET_ADDR32.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
---
Cc: Ian Jackson <ian.jackson@eu.citrix.com>
Cc: Ian Campbell <ian.campbell@citrix.com>
Cc: Wei Liu <wei.liu2@citrix.com>
---
Changes since v1:
 - Fix commit title.
---
 tools/libxc/xc_dom_elfloader.c     | 2 +-
 xen/common/libelf/libelf-dominfo.c | 1 +
 xen/include/xen/libelf.h           | 1 +
 3 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/tools/libxc/xc_dom_elfloader.c b/tools/libxc/xc_dom_elfloader.c
index 2ae575e..5039f3f 100644
--- a/tools/libxc/xc_dom_elfloader.c
+++ b/tools/libxc/xc_dom_elfloader.c
@@ -57,7 +57,7 @@ static char *xc_dom_guest_type(struct xc_dom_image *dom,
     uint64_t machine = elf_uval(elf, elf->ehdr, e_machine);
 
     if ( dom->container_type == XC_DOM_HVM_CONTAINER &&
-         dom->parms.phys_entry != UNSET_ADDR )
+         dom->parms.phys_entry != UNSET_ADDR32 )
         return "hvm-3.0-x86_32";
 
     switch ( machine )
diff --git a/xen/common/libelf/libelf-dominfo.c b/xen/common/libelf/libelf-dominfo.c
index 02d6cfb..ec69449 100644
--- a/xen/common/libelf/libelf-dominfo.c
+++ b/xen/common/libelf/libelf-dominfo.c
@@ -503,6 +503,7 @@ elf_errorstatus elf_xen_parse(struct elf_binary *elf,
     parms->virt_hv_start_low = UNSET_ADDR;
     parms->p2m_base = UNSET_ADDR;
     parms->elf_paddr_offset = UNSET_ADDR;
+    parms->phys_entry = UNSET_ADDR32;
 
     /* Find and parse elf notes. */
     count = elf_phdr_count(elf);
diff --git a/xen/include/xen/libelf.h b/xen/include/xen/libelf.h
index 6da4cc0..95b5370 100644
--- a/xen/include/xen/libelf.h
+++ b/xen/include/xen/libelf.h
@@ -386,6 +386,7 @@ elf_errorstatus elf_reloc(struct elf_binary *elf);
 /* xc_libelf_dominfo.c                                                      */
 
 #define UNSET_ADDR          ((uint64_t)-1)
+#define UNSET_ADDR32        ((uint32_t)-1)
 
 enum xen_elfnote_type {
     XEN_ENT_NONE = 0,
-- 
1.9.5 (Apple Git-50.3)


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

  reply	other threads:[~2016-01-15 14:59 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-15 14:59 [PATCH v2 0/4] HVMlite: minor fixes and Dom0 preparatory patches Roger Pau Monne
2016-01-15 14:59 ` Roger Pau Monne [this message]
2016-01-19  9:21   ` [PATCH v2 1/4] xen/elfnotes: check phys_entry against UNSET_ADDR32 Wei Liu
2016-01-15 14:59 ` [PATCH v2 2/4] libelf: rewrite symtab/strtab loading for Dom0 Roger Pau Monne
2016-01-15 14:59 ` [PATCH v2 3/4] x86/hvm: don't set the BSP as initialised in hvm_vcpu_initialise Roger Pau Monne
2016-01-15 14:59 ` [PATCH v2 4/4] x86/PV: enable the emulated PIT Roger Pau Monne
2016-01-15 17:08   ` Jan Beulich
2016-01-15 17:45     ` [PATCH v3 " Roger Pau Monne
2016-01-18  7:43       ` Jan Beulich
2016-01-18  9:29         ` Andrew Cooper
2016-01-18  9:44           ` Jan Beulich
2016-01-18 10:41             ` Andrew Cooper
2016-01-18 11:06               ` Jan Beulich
2016-01-18 16:10                 ` Andrew Cooper
2016-01-18 16:27                   ` Jan Beulich
2016-01-18 16:33                     ` Andrew Cooper
2016-01-18 16:44                       ` Jan Beulich
2016-01-18 17:58               ` Roger Pau Monné
2016-01-18 18:03                 ` Andrew Cooper
2016-01-19  9:24                   ` Ian Campbell
2016-01-19 10:09                     ` Andrew Cooper
2016-01-19 10:28                       ` Ian Campbell
2016-01-19 10:56                         ` Andrew Cooper
2016-01-20 11:57                 ` Ian Campbell
2016-01-18  9:50         ` Roger Pau Monné
2016-01-18 10:06           ` Jan Beulich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1452869983-75956-2-git-send-email-roger.pau@citrix.com \
    --to=roger.pau@citrix.com \
    --cc=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).