elfnotes: check phys_entry against UNSET_ADDR32

And introduce UNSET_ADDR32.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
This commit is contained in:
Roger Pau Monné authored and Jan Beulich committed 2016-01-19 16:06:31 +01:00
1 parent 162a81abb1
commit c2ba8c24f3
3 files changed
+3 -1

No files matched your search

+1 -1
View File
@@ -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 )
+1
View File
@@ -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);
+1
View File
@@ -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,
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.