• Home
  • Raw
  • Download

Lines Matching refs:c

54 s32 pm_qos_read_value(struct pm_qos_constraints *c)  in pm_qos_read_value()  argument
56 return READ_ONCE(c->target_value); in pm_qos_read_value()
59 static int pm_qos_get_value(struct pm_qos_constraints *c) in pm_qos_get_value() argument
61 if (plist_head_empty(&c->list)) in pm_qos_get_value()
62 return c->no_constraint_value; in pm_qos_get_value()
64 switch (c->type) { in pm_qos_get_value()
66 return plist_first(&c->list)->prio; in pm_qos_get_value()
69 return plist_last(&c->list)->prio; in pm_qos_get_value()
77 static void pm_qos_set_value(struct pm_qos_constraints *c, s32 value) in pm_qos_set_value() argument
79 WRITE_ONCE(c->target_value, value); in pm_qos_set_value()
99 int pm_qos_update_target(struct pm_qos_constraints *c, struct plist_node *node, in pm_qos_update_target() argument
107 prev_value = pm_qos_get_value(c); in pm_qos_update_target()
109 new_value = c->default_value; in pm_qos_update_target()
115 plist_del(node, &c->list); in pm_qos_update_target()
122 plist_del(node, &c->list); in pm_qos_update_target()
126 plist_add(node, &c->list); in pm_qos_update_target()
133 curr_value = pm_qos_get_value(c); in pm_qos_update_target()
134 pm_qos_set_value(c, curr_value); in pm_qos_update_target()
143 if (c->notifiers) in pm_qos_update_target()
144 blocking_notifier_call_chain(c->notifiers, curr_value, NULL); in pm_qos_update_target()
441 struct pm_qos_constraints *c; in freq_constraints_init() local
443 c = &qos->min_freq; in freq_constraints_init()
444 plist_head_init(&c->list); in freq_constraints_init()
445 c->target_value = FREQ_QOS_MIN_DEFAULT_VALUE; in freq_constraints_init()
446 c->default_value = FREQ_QOS_MIN_DEFAULT_VALUE; in freq_constraints_init()
447 c->no_constraint_value = FREQ_QOS_MIN_DEFAULT_VALUE; in freq_constraints_init()
448 c->type = PM_QOS_MAX; in freq_constraints_init()
449 c->notifiers = &qos->min_freq_notifiers; in freq_constraints_init()
450 BLOCKING_INIT_NOTIFIER_HEAD(c->notifiers); in freq_constraints_init()
452 c = &qos->max_freq; in freq_constraints_init()
453 plist_head_init(&c->list); in freq_constraints_init()
454 c->target_value = FREQ_QOS_MAX_DEFAULT_VALUE; in freq_constraints_init()
455 c->default_value = FREQ_QOS_MAX_DEFAULT_VALUE; in freq_constraints_init()
456 c->no_constraint_value = FREQ_QOS_MAX_DEFAULT_VALUE; in freq_constraints_init()
457 c->type = PM_QOS_MIN; in freq_constraints_init()
458 c->notifiers = &qos->max_freq_notifiers; in freq_constraints_init()
459 BLOCKING_INIT_NOTIFIER_HEAD(c->notifiers); in freq_constraints_init()