Lines Matching refs:state
258 unsigned int state)
264 /* New requested state is same as Max requested state */
265 if (state == genpd->performance_state)
266 return state;
268 /* New requested state is higher than Max requested state */
269 if (state > genpd->performance_state)
270 return state;
276 if (pd_data->performance_state > state)
277 state = pd_data->performance_state;
285 * Also note that link->performance_state (subdomain's performance state
287 * link->child->performance_state (current performance state requirement
295 if (link->performance_state > state)
296 state = link->performance_state;
299 return state;
315 unsigned int state, int depth)
321 if (state == genpd->performance_state)
328 /* Find parent's performance state */
329 ret = genpd_xlate_performance_state(genpd, parent, state);
352 ret = genpd->set_performance_state(genpd, state);
357 genpd->performance_state = state;
374 pr_err("%s: Failed to roll back to %d performance state\n",
384 static int genpd_set_performance_state(struct device *dev, unsigned int state)
392 if (prev_state == state)
395 gpd_data->performance_state = state;
396 state = _genpd_reeval_performance_state(genpd, state);
398 ret = _genpd_set_performance_state(genpd, state, 0);
416 unsigned int state)
418 if (state)
419 genpd_set_performance_state(dev, state);
423 * dev_pm_genpd_set_performance_state- Set performance state of device's power
426 * @dev: Device for which the performance-state needs to be set.
427 * @state: Target performance state of the device. This can be set as 0 when the
428 * device doesn't have any performance state constraints left (And so
430 * performance state of the genpd).
437 int dev_pm_genpd_set_performance_state(struct device *dev, unsigned int state)
452 dev_gpd_data(dev)->rpm_pstate = state;
454 ret = genpd_set_performance_state(dev, state);
661 * RPM status of the releated device is in an intermediate state, not yet turned
679 * (1) The domain is already in the "power off" state.
725 /* Default to shallowest state. */
1134 /* Check that the children are in their deepest (powered-off) state. */
1141 /* Choose the deepest state when suspending */
1399 * Make sure the domain will be in the same power state as before the
1970 struct genpd_power_state *state;
1972 state = kzalloc(sizeof(*state), GFP_KERNEL);
1973 if (!state)
1976 genpd->states = state;
2005 /* Use only one "off" state if there were no states declared */
2338 * state.
2400 * performance state.
2687 /* Drop the default performance state */
2761 /* Set the default performance state */
2780 /* Drop the default performance state */
2793 dev_err(dev, "failed to set required performance state for power-domain %s: %d\n",
2916 { .compatible = "domain-idle-state", },
2978 pr_err("Parsing idle state node %pOF failed with err %d\n",
2994 * @states: The pointer to which the state array will be saved.
3036 * pm_genpd_opp_to_performance_state - Gets performance state of the genpd from its OPP node.
3038 * @genpd_dev: Genpd's device for which the performance-state needs to be found.
3040 * state.
3042 * Returns performance state encoded in the OPP of the genpd. This calls
3044 * power domain OPP to performance state.
3046 * Returns performance state on success and 0 on failure.
3052 int state;
3060 state = genpd->opp_to_performance_state(genpd, opp);
3063 return state;
3123 char state[16];
3133 snprintf(state, sizeof(state), "%s-%u",
3136 snprintf(state, sizeof(state), "%s",
3138 seq_printf(s, "%-30s %-50s %u", genpd->name, state, genpd->performance_state);