Issue with non-PAE enable i386 xen guest

karim.allah.ahmed at gmail.com karim.allah.ahmed at gmail.com
Mon Jan 24 12:52:47 UTC 2011


In initvalues(start_info_t) function at "[[src]]/sys/i386/xen/xen_machdep.c"

IdlePDTnew, IdlePTDnew, etc are only declared under PAE enabled guests as
following:

#ifdef PAE
        vm_paddr_t IdlePDPTma, IdlePDPTnewma;
        vm_paddr_t IdlePTDnewma[4];
        pd_entry_t *IdlePDPTnew, *IdlePTDnew;
#else
        vm_paddr_t pdir_shadow_ma;
#endif

However It's used later in the function without constraining it to certain
guests ( without #ifdef PAE ), one of those is

memcpy(((uint8_t *)IdlePTDnew) + ((unsigned int)(KERNBASE >> 18)),
            ((uint8_t *)IdlePTD) + ((KERNBASE >> 18) & PAGE_MASK),
            l1_pages*sizeof(pt_entry_t))


Is the current non-PAE xen guest implementation broke intentionally, or is
this a merge issue or something ?

( This issue arises as a compile-time error as soon as you remove the
"options PAE" in the XEN configuration file for the build )


-- 
Karim Allah Ahmed.
LinkedIn <http://eg.linkedin.com/pub/karim-allah-ahmed/13/829/550/>


More information about the freebsd-xen mailing list