Lines Matching refs:policy
58 static ssize_t show_total_trans(struct cpufreq_policy *policy, char *buf)
60 struct cpufreq_stats *stats = policy->stats;
69 static ssize_t show_time_in_state(struct cpufreq_policy *policy, char *buf)
71 struct cpufreq_stats *stats = policy->stats;
103 static ssize_t store_reset(struct cpufreq_policy *policy, const char *buf,
106 struct cpufreq_stats *stats = policy->stats;
124 static ssize_t show_trans_table(struct cpufreq_policy *policy, char *buf)
126 struct cpufreq_stats *stats = policy->stats;
194 void cpufreq_stats_free_table(struct cpufreq_policy *policy)
196 struct cpufreq_stats *stats = policy->stats;
204 sysfs_remove_group(&policy->kobj, &stats_attr_group);
207 policy->stats = NULL;
210 void cpufreq_stats_create_table(struct cpufreq_policy *policy)
217 count = cpufreq_table_count_valid_entries(policy);
222 if (policy->stats)
245 cpufreq_for_each_valid_entry(pos, policy->freq_table)
246 if (policy->freq_table_sorted != CPUFREQ_TABLE_UNSORTED ||
252 stats->last_index = freq_table_get_index(stats, policy->cur);
254 policy->stats = stats;
255 if (!sysfs_create_group(&policy->kobj, &stats_attr_group))
259 policy->stats = NULL;
265 void cpufreq_stats_record_transition(struct cpufreq_policy *policy,
268 struct cpufreq_stats *stats = policy->stats;