[ARM] pxa: Allow platforms to override PSPR setting
Currently, we set PSPR just before entering sleep mode. However, some platforms have different requirements for setting PSPR in order to properly wake up. Set PSPR earlier in the suspend cycle so that platforms can change the setting by using a sysdev driver instead. Acked-by: Eric Miao <eric.miao@marvell.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
This commit is contained in:
committed by
Russell King
parent
63bef54738
commit
4104980a3c
@@ -86,9 +86,27 @@ static int pxa_pm_valid(suspend_state_t state)
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
static int pxa_pm_prepare(void)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
if (pxa_cpu_pm_fns && pxa_cpu_pm_fns->prepare)
|
||||
ret = pxa_cpu_pm_fns->prepare();
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void pxa_pm_finish(void)
|
||||
{
|
||||
if (pxa_cpu_pm_fns && pxa_cpu_pm_fns->finish)
|
||||
pxa_cpu_pm_fns->finish();
|
||||
}
|
||||
|
||||
static struct platform_suspend_ops pxa_pm_ops = {
|
||||
.valid = pxa_pm_valid,
|
||||
.enter = pxa_pm_enter,
|
||||
.prepare = pxa_pm_prepare,
|
||||
.finish = pxa_pm_finish,
|
||||
};
|
||||
|
||||
static int __init pxa_pm_init(void)
|
||||
|
Reference in New Issue
Block a user