Skip to content

Commit 2f76989

Browse files
glneoShawn Guo
authored andcommitted
ARM: imx: Switch to new sys-off handler API
Kernel now supports chained power-off handlers. Use register_platform_power_off() that registers a platform level power-off handler. Legacy pm_power_off() will be removed once all drivers and archs are converted to the new sys-off API. Signed-off-by: Andrew Davis <afd@ti.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org>
1 parent 9852d85 commit 2f76989

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

arch/arm/mach-imx/pm-imx6.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -634,13 +634,11 @@ static void imx6_pm_stby_poweroff(void)
634634

635635
static int imx6_pm_stby_poweroff_probe(void)
636636
{
637-
if (pm_power_off) {
638-
pr_warn("%s: pm_power_off already claimed %p %ps!\n",
639-
__func__, pm_power_off, pm_power_off);
637+
if (register_platform_power_off(imx6_pm_stby_poweroff)) {
638+
pr_warn("%s: platform power off already claimed!\n", __func__);
640639
return -EBUSY;
641640
}
642641

643-
pm_power_off = imx6_pm_stby_poweroff;
644642
return 0;
645643
}
646644

0 commit comments

Comments
 (0)