xen: share start flags between PV and PVH
Use a global variable to store the start flags for both PV and PVH. This allows the xen_initial_domain macro to work properly on PVH. Note that ARM is also switched to use the new variable. Signed-off-by: Boris Ostrovsky <boris.ostrovsky@oracle.com> Signed-off-by: Roger Pau Monné <roger.pau@citrix.com> Reviewed-by: Juergen Gross <jgross@suse.com> Signed-off-by: Juergen Gross <jgross@suse.com>
This commit is contained in:

committed by
Juergen Gross

parent
7f47e1c52d
commit
1fe83888a2
@@ -64,6 +64,13 @@ struct shared_info xen_dummy_shared_info;
|
||||
__read_mostly int xen_have_vector_callback;
|
||||
EXPORT_SYMBOL_GPL(xen_have_vector_callback);
|
||||
|
||||
/*
|
||||
* NB: needs to live in .data because it's used by xen_prepare_pvh which runs
|
||||
* before clearing the bss.
|
||||
*/
|
||||
uint32_t xen_start_flags __attribute__((section(".data"))) = 0;
|
||||
EXPORT_SYMBOL(xen_start_flags);
|
||||
|
||||
/*
|
||||
* Point at some empty memory to start with. We map the real shared_info
|
||||
* page as soon as fixmap is up and running.
|
||||
|
@@ -1203,6 +1203,7 @@ asmlinkage __visible void __init xen_start_kernel(void)
|
||||
return;
|
||||
|
||||
xen_domain_type = XEN_PV_DOMAIN;
|
||||
xen_start_flags = xen_start_info->flags;
|
||||
|
||||
xen_setup_features();
|
||||
|
||||
|
@@ -97,6 +97,7 @@ void __init xen_prepare_pvh(void)
|
||||
}
|
||||
|
||||
xen_pvh = 1;
|
||||
xen_start_flags = pvh_start_info.flags;
|
||||
|
||||
msr = cpuid_ebx(xen_cpuid_base() + 2);
|
||||
pfn = __pa(hypercall_page);
|
||||
|
Reference in New Issue
Block a user