mirror of
https://github.com/edk2-porting/linux-next.git
synced 2025-01-14 16:44:29 +08:00
ARM: imx6: call suspend_set_ops() from suspend routine
Rename function imx6q_ocram_suspend_init() to imx6q_suspend_init() and call suspend_set_ops() from there. Now we get a centralized function for suspend initialization. Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
This commit is contained in:
parent
facadba6a1
commit
afc51f4643
@ -382,8 +382,7 @@ out:
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int __init imx6q_ocram_suspend_init(const struct imx6_pm_socdata
|
static int __init imx6q_suspend_init(const struct imx6_pm_socdata *socdata)
|
||||||
*socdata)
|
|
||||||
{
|
{
|
||||||
phys_addr_t ocram_pbase;
|
phys_addr_t ocram_pbase;
|
||||||
struct device_node *node;
|
struct device_node *node;
|
||||||
@ -394,6 +393,8 @@ static int __init imx6q_ocram_suspend_init(const struct imx6_pm_socdata
|
|||||||
int i, ret = 0;
|
int i, ret = 0;
|
||||||
const u32 *mmdc_offset_array;
|
const u32 *mmdc_offset_array;
|
||||||
|
|
||||||
|
suspend_set_ops(&imx6q_pm_ops);
|
||||||
|
|
||||||
if (!socdata) {
|
if (!socdata) {
|
||||||
pr_warn("%s: invalid argument!\n", __func__);
|
pr_warn("%s: invalid argument!\n", __func__);
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
@ -515,9 +516,9 @@ static void __init imx6_pm_common_init(const struct imx6_pm_socdata
|
|||||||
|
|
||||||
WARN_ON(!ccm_base);
|
WARN_ON(!ccm_base);
|
||||||
|
|
||||||
ret = imx6q_ocram_suspend_init(socdata);
|
ret = imx6q_suspend_init(socdata);
|
||||||
if (ret)
|
if (ret)
|
||||||
pr_warn("%s: failed to initialize ocram suspend %d!\n",
|
pr_warn("%s: No DDR LPM support with suspend %d!\n",
|
||||||
__func__, ret);
|
__func__, ret);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -531,9 +532,6 @@ static void __init imx6_pm_common_init(const struct imx6_pm_socdata
|
|||||||
if (!IS_ERR(gpr))
|
if (!IS_ERR(gpr))
|
||||||
regmap_update_bits(gpr, IOMUXC_GPR1, IMX6Q_GPR1_GINT,
|
regmap_update_bits(gpr, IOMUXC_GPR1, IMX6Q_GPR1_GINT,
|
||||||
IMX6Q_GPR1_GINT);
|
IMX6Q_GPR1_GINT);
|
||||||
|
|
||||||
|
|
||||||
suspend_set_ops(&imx6q_pm_ops);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void __init imx6q_pm_init(void)
|
void __init imx6q_pm_init(void)
|
||||||
|
Loading…
Reference in New Issue
Block a user