Skip to content

Commit

Permalink
xen/arm: initialize pm functions later
Browse files Browse the repository at this point in the history
If we are running in dom0, we have to wait for the arch specific code to
complete the initialization in order for us to successfully reset the
power_off and pm_restart functions.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
  • Loading branch information
Stefano Stabellini committed May 13, 2013
1 parent 9bc25a1 commit 1aa3d8d
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion arch/arm/xen/enlighten.c
Original file line number Diff line number Diff line change
Expand Up @@ -272,12 +272,18 @@ static int __init xen_guest_init(void)
if (!xen_initial_domain())
xenbus_probe(NULL);

return 0;
}
core_initcall(xen_guest_init);

static int __init xen_pm_init(void)
{
pm_power_off = xen_power_off;
arm_pm_restart = xen_restart;

return 0;
}
core_initcall(xen_guest_init);
subsys_initcall(xen_pm_init);

static irqreturn_t xen_arm_callback(int irq, void *arg)
{
Expand Down

0 comments on commit 1aa3d8d

Please sign in to comment.