Lines Matching +full:needs +full:- +full:reset +full:- +full:on +full:- +full:resume
1 // SPDX-License-Identifier: GPL-2.0-only
8 * OMAP4430 MPUSS mainly consists of dual Cortex-A9 with per-CPU
16 * mode. While waking up from the dormant mode, a reset signal
17 * to the Cortex-A9 processor must be asserted by the external
24 * ----------------------------------------------
25 * ON ON ON
26 * ON(Inactive) OFF ON(Inactive)
30 * ----------------------------------------------
33 * and first to wake-up when MPUSS low power states are excercised
48 #include <asm/hardware/cache-l2x0.h>
53 #include "omap4-sar-layout.h"
60 #include "prm-regbits-44xx.h"
75 * struct cpu_pm_ops - CPU pm operations
77 * @resume: CPU resume function pointer
82 * suspend, resume and scu programming.
86 void (*resume)(void); member
109 .resume = dummy_cpu_resume,
122 if (pm_info->wkup_sar_addr) in set_cpu_wakeup_addr()
123 writel_relaxed(addr, pm_info->wkup_sar_addr); in set_cpu_wakeup_addr()
148 if (pm_info->scu_sar_addr) in scu_pwrst_prepare()
149 writel_relaxed(scu_pwr_st, pm_info->scu_sar_addr); in scu_pwrst_prepare()
187 if (pm_info->l2x0_sar_addr) in l2x0_pwrst_prepare()
188 writel_relaxed(save_state, pm_info->l2x0_sar_addr); in l2x0_pwrst_prepare()
218 * @rcuidle: RCU needs to be idled
222 * 0 - Nothing lost and no need to save: MPUSS INACTIVE
223 * 1 - CPUx L1 and logic lost: MPUSS CSWR
224 * 2 - CPUx L1 and logic lost + GIC lost: MPUSS OSWR
225 * 3 - CPUx L1 and logic lost + GIC + L2 lost: DEVICE OFF
234 return -ENXIO; in omap4_enter_lowpower()
253 * needs to be cleaned because of coherency. This makes in omap4_enter_lowpower()
257 return -ENXIO; in omap4_enter_lowpower()
272 pwrdm_set_next_pwrst(pm_info->pwrdm, power_state); in omap4_enter_lowpower()
273 pwrdm_set_logic_retst(pm_info->pwrdm, cpu_logic_state); in omap4_enter_lowpower()
278 set_cpu_wakeup_addr(cpu, __pa_symbol(omap_pm_ops.resume)); in omap4_enter_lowpower()
297 * Restore the CPUx power state to ON otherwise CPUx in omap4_enter_lowpower()
299 * state while doing WFI outside the low powe code. On in omap4_enter_lowpower()
303 pwrdm_set_next_pwrst(pm_info->pwrdm, PWRDM_POWER_ON); in omap4_enter_lowpower()
321 return -ENXIO; in omap4_hotplug_cpu()
324 power_state = pwrdm_get_valid_lp_state(pm_info->pwrdm, in omap4_hotplug_cpu()
330 pwrdm_clear_all_prev_pwrst(pm_info->pwrdm); in omap4_hotplug_cpu()
331 pwrdm_set_next_pwrst(pm_info->pwrdm, power_state); in omap4_hotplug_cpu()
342 pwrdm_set_next_pwrst(pm_info->pwrdm, PWRDM_POWER_ON); in omap4_hotplug_cpu()
370 WARN(1, "Power Management not supported on OMAP4430 ES1.0\n"); in omap4_mpuss_init()
371 return -ENODEV; in omap4_mpuss_init()
377 pm_info->scu_sar_addr = sar_base + SCU_OFFSET0; in omap4_mpuss_init()
379 pm_info->wkup_sar_addr = sar_base + in omap4_mpuss_init()
382 pm_info->wkup_sar_addr = sar_base + in omap4_mpuss_init()
384 pm_info->l2x0_sar_addr = sar_base + L2X0_SAVE_OFFSET0; in omap4_mpuss_init()
386 pm_info->pwrdm = pwrdm_lookup("cpu0_pwrdm"); in omap4_mpuss_init()
387 if (!pm_info->pwrdm) { in omap4_mpuss_init()
389 return -ENODEV; in omap4_mpuss_init()
393 pwrdm_clear_all_prev_pwrst(pm_info->pwrdm); in omap4_mpuss_init()
396 /* Initialise CPU0 power domain state to ON */ in omap4_mpuss_init()
397 pwrdm_set_next_pwrst(pm_info->pwrdm, PWRDM_POWER_ON); in omap4_mpuss_init()
401 pm_info->scu_sar_addr = sar_base + SCU_OFFSET1; in omap4_mpuss_init()
403 pm_info->wkup_sar_addr = sar_base + in omap4_mpuss_init()
406 pm_info->wkup_sar_addr = sar_base + in omap4_mpuss_init()
408 pm_info->l2x0_sar_addr = sar_base + L2X0_SAVE_OFFSET1; in omap4_mpuss_init()
411 pm_info->pwrdm = pwrdm_lookup("cpu1_pwrdm"); in omap4_mpuss_init()
412 if (!pm_info->pwrdm) { in omap4_mpuss_init()
414 return -ENODEV; in omap4_mpuss_init()
418 pwrdm_clear_all_prev_pwrst(pm_info->pwrdm); in omap4_mpuss_init()
421 /* Initialise CPU1 power domain state to ON */ in omap4_mpuss_init()
422 pwrdm_set_next_pwrst(pm_info->pwrdm, PWRDM_POWER_ON); in omap4_mpuss_init()
427 return -ENODEV; in omap4_mpuss_init()
433 /* Save device type on scratchpad for low level code to use */ in omap4_mpuss_init()
441 omap_pm_ops.resume = omap4_cpu_resume; in omap4_mpuss_init()
479 /* Save old NS_PA_ADDR for validity checks later on */ in omap4_mpuss_early_init()