arch: arm64: init xen in arch_kernel_init()
Call xen_enlighten_init() from arch_kernel_init() instead of using SYS_INIT. Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This commit is contained in:
parent
328f52b0ce
commit
7c90f1bca1
2 changed files with 6 additions and 3 deletions
|
@ -42,7 +42,7 @@ static int xen_map_shared_info(const shared_info_t *shared_page)
|
||||||
return HYPERVISOR_memory_op(XENMEM_add_to_physmap, &xatp);
|
return HYPERVISOR_memory_op(XENMEM_add_to_physmap, &xatp);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int xen_enlighten_init(void)
|
int xen_enlighten_init(void)
|
||||||
{
|
{
|
||||||
int ret = 0;
|
int ret = 0;
|
||||||
shared_info_t *info = (shared_info_t *) shared_info_buf;
|
shared_info_t *info = (shared_info_t *) shared_info_buf;
|
||||||
|
@ -66,5 +66,3 @@ static int xen_enlighten_init(void)
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
SYS_INIT(xen_enlighten_init, PRE_KERNEL_1, CONFIG_KERNEL_INIT_PRIORITY_DEVICE);
|
|
||||||
|
|
|
@ -28,8 +28,13 @@ extern "C" {
|
||||||
|
|
||||||
#ifndef _ASMLANGUAGE
|
#ifndef _ASMLANGUAGE
|
||||||
|
|
||||||
|
extern void xen_enlighten_init(void);
|
||||||
|
|
||||||
static ALWAYS_INLINE void arch_kernel_init(void)
|
static ALWAYS_INLINE void arch_kernel_init(void)
|
||||||
{
|
{
|
||||||
|
#ifdef CONFIG_XEN
|
||||||
|
xen_enlighten_init();
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void arch_switch(void *switch_to, void **switched_from)
|
static inline void arch_switch(void *switch_to, void **switched_from)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue