Lines Matching refs:pwrst
362 struct power_state *pwrst; in omap3_pm_suspend() local
366 list_for_each_entry(pwrst, &pwrst_list, node) in omap3_pm_suspend()
367 pwrst->saved_state = pwrdm_read_next_pwrst(pwrst->pwrdm); in omap3_pm_suspend()
369 list_for_each_entry(pwrst, &pwrst_list, node) { in omap3_pm_suspend()
370 if (omap_set_pwrdm_state(pwrst->pwrdm, pwrst->next_state)) in omap3_pm_suspend()
372 if (pwrdm_clear_all_prev_pwrst(pwrst->pwrdm)) in omap3_pm_suspend()
382 list_for_each_entry(pwrst, &pwrst_list, node) { in omap3_pm_suspend()
383 state = pwrdm_read_prev_pwrst(pwrst->pwrdm); in omap3_pm_suspend()
384 if (state > pwrst->next_state) { in omap3_pm_suspend()
386 pwrst->pwrdm->name, pwrst->next_state); in omap3_pm_suspend()
389 omap_set_pwrdm_state(pwrst->pwrdm, pwrst->saved_state); in omap3_pm_suspend()
559 struct power_state *pwrst; in omap3_pm_off_mode_enable() local
567 list_for_each_entry(pwrst, &pwrst_list, node) { in omap3_pm_off_mode_enable()
569 pwrst->pwrdm == core_pwrdm && in omap3_pm_off_mode_enable()
571 pwrst->next_state = PWRDM_POWER_RET; in omap3_pm_off_mode_enable()
575 pwrst->next_state = state; in omap3_pm_off_mode_enable()
577 omap_set_pwrdm_state(pwrst->pwrdm, pwrst->next_state); in omap3_pm_off_mode_enable()
583 struct power_state *pwrst; in omap3_pm_get_suspend_state() local
585 list_for_each_entry(pwrst, &pwrst_list, node) { in omap3_pm_get_suspend_state()
586 if (pwrst->pwrdm == pwrdm) in omap3_pm_get_suspend_state()
587 return pwrst->next_state; in omap3_pm_get_suspend_state()
594 struct power_state *pwrst; in omap3_pm_set_suspend_state() local
596 list_for_each_entry(pwrst, &pwrst_list, node) { in omap3_pm_set_suspend_state()
597 if (pwrst->pwrdm == pwrdm) { in omap3_pm_set_suspend_state()
598 pwrst->next_state = state; in omap3_pm_set_suspend_state()
607 struct power_state *pwrst; in pwrdms_setup() local
612 pwrst = kmalloc(sizeof(struct power_state), GFP_ATOMIC); in pwrdms_setup()
613 if (!pwrst) in pwrdms_setup()
615 pwrst->pwrdm = pwrdm; in pwrdms_setup()
616 pwrst->next_state = PWRDM_POWER_RET; in pwrdms_setup()
617 list_add(&pwrst->node, &pwrst_list); in pwrdms_setup()
622 return omap_set_pwrdm_state(pwrst->pwrdm, pwrst->next_state); in pwrdms_setup()
657 struct power_state *pwrst, *tmp; in omap3_pm_init() local
769 list_for_each_entry_safe(pwrst, tmp, &pwrst_list, node) { in omap3_pm_init()
770 list_del(&pwrst->node); in omap3_pm_init()
771 kfree(pwrst); in omap3_pm_init()