| /linux/drivers/cpufreq/ |
| H A D | cpufreq.c | 83 static unsigned int __cpufreq_get(struct cpufreq_policy *policy); 84 static int cpufreq_init_governor(struct cpufreq_policy *policy); 85 static void cpufreq_exit_governor(struct cpufreq_policy *policy); 86 static void cpufreq_governor_limits(struct cpufreq_policy *policy); 87 static int cpufreq_set_policy(struct cpufreq_policy *policy, 94 * Two notifier lists: the "policy" list is involved in the 95 * validation process for a new CPU frequency policy; the 124 struct kobject *get_governor_parent_kobj(struct cpufreq_policy *policy) in get_governor_parent_kobj() argument 127 return &policy->kobj; in get_governor_parent_kobj() 149 * - policy in get_cpu_idle_time_jiffy() 178 cpufreq_generic_init(struct cpufreq_policy * policy,struct cpufreq_frequency_table * table,unsigned int transition_latency) cpufreq_generic_init() argument 195 struct cpufreq_policy *policy = per_cpu(cpufreq_cpu_data, cpu); cpufreq_cpu_get_raw() local 209 struct cpufreq_policy *policy = cpufreq_cpu_get_raw(cpu); cpufreq_generic_get() local 234 struct cpufreq_policy *policy = NULL; cpufreq_cpu_get() local 260 cpufreq_cpu_put(struct cpufreq_policy * policy) cpufreq_cpu_put() argument 314 cpufreq_notify_transition(struct cpufreq_policy * policy,struct cpufreq_freqs * freqs,unsigned int state) cpufreq_notify_transition() argument 366 cpufreq_notify_post_transition(struct cpufreq_policy * policy,struct cpufreq_freqs * freqs,int transition_failed) cpufreq_notify_post_transition() argument 378 cpufreq_freq_transition_begin(struct cpufreq_policy * policy,struct cpufreq_freqs * freqs) cpufreq_freq_transition_begin() argument 412 cpufreq_freq_transition_end(struct cpufreq_policy * policy,struct cpufreq_freqs * freqs,int transition_failed) cpufreq_freq_transition_end() argument 465 cpufreq_enable_fast_switch(struct cpufreq_policy * policy) cpufreq_enable_fast_switch() argument 489 cpufreq_disable_fast_switch(struct cpufreq_policy * policy) cpufreq_disable_fast_switch() argument 501 __resolve_freq(struct cpufreq_policy * policy,unsigned int target_freq,unsigned int min,unsigned int max,unsigned int relation) __resolve_freq() argument 530 cpufreq_driver_resolve_freq(struct cpufreq_policy * policy,unsigned int target_freq) cpufreq_driver_resolve_freq() argument 551 cpufreq_policy_transition_delay_us(struct cpufreq_policy * policy) cpufreq_policy_transition_delay_us() argument 597 show_local_boost(struct cpufreq_policy * policy,char * buf) show_local_boost() argument 602 policy_set_boost(struct cpufreq_policy * policy,bool enable) policy_set_boost() argument 627 store_local_boost(struct cpufreq_policy * policy,const char * buf,size_t count) store_local_boost() argument 735 cpufreq_avg_freq_supported(struct cpufreq_policy * policy) cpufreq_avg_freq_supported() argument 740 show_scaling_cur_freq(struct cpufreq_policy * policy,char * buf) show_scaling_cur_freq() argument 782 show_cpuinfo_cur_freq(struct cpufreq_policy * policy,char * buf) show_cpuinfo_cur_freq() argument 796 show_cpuinfo_avg_freq(struct cpufreq_policy * policy,char * buf) show_cpuinfo_avg_freq() argument 809 show_scaling_governor(struct cpufreq_policy * policy,char * buf) show_scaling_governor() argument 823 store_scaling_governor(struct cpufreq_policy * policy,const char * buf,size_t count) store_scaling_governor() argument 860 show_scaling_driver(struct cpufreq_policy * policy,char * buf) show_scaling_driver() argument 868 show_scaling_available_governors(struct cpufreq_policy * policy,char * buf) show_scaling_available_governors() argument 915 show_related_cpus(struct cpufreq_policy * policy,char * buf) show_related_cpus() argument 923 show_affected_cpus(struct cpufreq_policy * policy,char * buf) show_affected_cpus() argument 928 store_scaling_setspeed(struct cpufreq_policy * policy,const char * buf,size_t count) store_scaling_setspeed() argument 946 show_scaling_setspeed(struct cpufreq_policy * policy,char * buf) show_scaling_setspeed() argument 957 show_bios_limit(struct cpufreq_policy * policy,char * buf) show_bios_limit() argument 1005 struct cpufreq_policy *policy = to_policy(kobj); show() local 1022 struct cpufreq_policy *policy = to_policy(kobj); store() local 1038 struct cpufreq_policy *policy = to_policy(kobj); cpufreq_sysfs_release() local 1054 add_cpu_dev_symlink(struct cpufreq_policy * policy,unsigned int cpu,struct device * dev) add_cpu_dev_symlink() argument 1068 remove_cpu_dev_symlink(struct cpufreq_policy * policy,int cpu,struct device * dev) remove_cpu_dev_symlink() argument 1076 cpufreq_add_dev_interface(struct cpufreq_policy * policy) cpufreq_add_dev_interface() argument 1131 cpufreq_init_policy(struct cpufreq_policy * policy) cpufreq_init_policy() argument 1180 cpufreq_add_policy_cpu(struct cpufreq_policy * policy,unsigned int cpu) cpufreq_add_policy_cpu() argument 1204 refresh_frequency_limits(struct cpufreq_policy * policy) refresh_frequency_limits() argument 1216 struct cpufreq_policy *policy = handle_update() local 1229 struct cpufreq_policy *policy = container_of(nb, struct cpufreq_policy, nb_min); cpufreq_notifier_min() local 1238 struct cpufreq_policy *policy = container_of(nb, struct cpufreq_policy, nb_max); cpufreq_notifier_max() local 1244 cpufreq_policy_put_kobj(struct cpufreq_policy * policy) cpufreq_policy_put_kobj() argument 1268 struct cpufreq_policy *policy; cpufreq_policy_alloc() local 1349 cpufreq_policy_free(struct cpufreq_policy * policy) cpufreq_policy_free() argument 1400 cpufreq_policy_online(struct cpufreq_policy * policy,unsigned int cpu,bool new_policy) cpufreq_policy_online() argument 1588 struct cpufreq_policy *policy; cpufreq_online() local 1653 struct cpufreq_policy *policy; cpufreq_add_dev() local 1673 __cpufreq_offline(unsigned int cpu,struct cpufreq_policy * policy) __cpufreq_offline() argument 1722 struct cpufreq_policy *policy; cpufreq_offline() local 1747 struct cpufreq_policy *policy = per_cpu(cpufreq_cpu_data, cpu); cpufreq_remove_dev() local 1786 cpufreq_out_of_sync(struct cpufreq_policy * policy,unsigned int new_freq) cpufreq_out_of_sync() argument 1801 cpufreq_verify_current_freq(struct cpufreq_policy * policy,bool update) cpufreq_verify_current_freq() argument 1901 __cpufreq_get(struct cpufreq_policy * policy) __cpufreq_get() argument 1938 cpufreq_generic_suspend(struct cpufreq_policy * policy) cpufreq_generic_suspend() argument 1970 struct cpufreq_policy *policy; cpufreq_suspend() local 2004 struct cpufreq_policy *policy; cpufreq_resume() local 2196 cpufreq_driver_fast_switch(struct cpufreq_policy * policy,unsigned int target_freq) cpufreq_driver_fast_switch() argument 2243 cpufreq_driver_adjust_perf(struct cpufreq_policy * policy,unsigned long min_perf,unsigned long target_perf,unsigned long capacity) cpufreq_driver_adjust_perf() argument 2263 __target_intermediate(struct cpufreq_policy * policy,struct cpufreq_freqs * freqs,int index) __target_intermediate() argument 2288 __target_index(struct cpufreq_policy * policy,int index) __target_index() argument 2348 __cpufreq_driver_target(struct cpufreq_policy * policy,unsigned int target_freq,unsigned int relation) __cpufreq_driver_target() argument 2391 cpufreq_driver_target(struct cpufreq_policy * policy,unsigned int target_freq,unsigned int relation) cpufreq_driver_target() argument 2406 cpufreq_init_governor(struct cpufreq_policy * policy) cpufreq_init_governor() argument 2452 cpufreq_exit_governor(struct cpufreq_policy * policy) cpufreq_exit_governor() argument 2465 cpufreq_start_governor(struct cpufreq_policy * policy) cpufreq_start_governor() argument 2491 cpufreq_stop_governor(struct cpufreq_policy * policy) cpufreq_stop_governor() argument 2502 cpufreq_governor_limits(struct cpufreq_policy * policy) cpufreq_governor_limits() argument 2538 struct cpufreq_policy *policy; cpufreq_unregister_governor() local 2576 cpufreq_update_pressure(struct cpufreq_policy * policy) cpufreq_update_pressure() argument 2617 cpufreq_set_policy(struct cpufreq_policy * policy,struct cpufreq_governor * new_gov,unsigned int new_pol) cpufreq_set_policy() argument 2720 cpufreq_policy_refresh(struct cpufreq_policy * policy) cpufreq_policy_refresh() argument 2777 cpufreq_boost_set_sw(struct cpufreq_policy * policy,int state) cpufreq_boost_set_sw() argument 2794 struct cpufreq_policy *policy; cpufreq_boost_trigger_state() local [all...] |
| H A D | freq_table.c | 17 static bool policy_has_boost_freq(struct cpufreq_policy *policy) in policy_has_boost_freq() argument 19 struct cpufreq_frequency_table *pos, *table = policy->freq_table; in policy_has_boost_freq() 31 int cpufreq_frequency_table_cpuinfo(struct cpufreq_policy *policy) in cpufreq_frequency_table_cpuinfo() argument 33 struct cpufreq_frequency_table *pos, *table = policy->freq_table; in cpufreq_frequency_table_cpuinfo() 41 if ((!cpufreq_boost_enabled() || !policy->boost_enabled) in cpufreq_frequency_table_cpuinfo() 52 policy->cpuinfo.min_freq = min_freq; in cpufreq_frequency_table_cpuinfo() 57 if (policy->cpuinfo.max_freq < max_freq) in cpufreq_frequency_table_cpuinfo() 58 policy->cpuinfo.max_freq = max_freq; in cpufreq_frequency_table_cpuinfo() 66 int cpufreq_frequency_table_verify(struct cpufreq_policy_data *policy) 68 struct cpufreq_frequency_table *pos, *table = policy in cpufreq_frequency_table_verify() 67 cpufreq_frequency_table_verify(struct cpufreq_policy_data * policy) cpufreq_frequency_table_verify() argument 106 cpufreq_generic_frequency_table_verify(struct cpufreq_policy_data * policy) cpufreq_generic_frequency_table_verify() argument 115 cpufreq_table_index_unsorted(struct cpufreq_policy * policy,unsigned int target_freq,unsigned int min,unsigned int max,unsigned int relation) cpufreq_table_index_unsorted() argument 208 cpufreq_frequency_table_get_index(struct cpufreq_policy * policy,unsigned int freq) cpufreq_frequency_table_get_index() argument 230 show_available_freqs(struct cpufreq_policy * policy,char * buf,bool show_boost) show_available_freqs() argument 270 scaling_available_frequencies_show(struct cpufreq_policy * policy,char * buf) scaling_available_frequencies_show() argument 281 scaling_boost_frequencies_show(struct cpufreq_policy * policy,char * buf) scaling_boost_frequencies_show() argument 288 set_freq_table_sorted(struct cpufreq_policy * policy) set_freq_table_sorted() argument 343 cpufreq_table_validate_and_sort(struct cpufreq_policy * policy) cpufreq_table_validate_and_sort() argument [all...] |
| H A D | cpufreq_userspace.c | 31 static int cpufreq_set(struct cpufreq_policy *policy, unsigned int freq) in cpufreq_set() argument 34 struct userspace_policy *userspace = policy->governor_data; in cpufreq_set() 36 pr_debug("cpufreq_set for cpu %u, freq %u kHz\n", policy->cpu, freq); in cpufreq_set() 44 ret = __cpufreq_driver_target(policy, freq, CPUFREQ_RELATION_L); in cpufreq_set() 50 static ssize_t show_speed(struct cpufreq_policy *policy, char *buf) in show_speed() argument 52 struct userspace_policy *userspace = policy->governor_data; in show_speed() 57 static int cpufreq_userspace_policy_init(struct cpufreq_policy *policy) in cpufreq_userspace_policy_init() argument 67 policy->governor_data = userspace; in cpufreq_userspace_policy_init() 75 static void cpufreq_userspace_policy_exit(struct cpufreq_policy *policy) in cpufreq_userspace_policy_exit() argument 77 kfree(policy->governor_data); in cpufreq_userspace_policy_exit() [all …]
|
| H A D | virtual-cpufreq.c | 92 static unsigned int virt_cpufreq_set_perf(struct cpufreq_policy *policy, in virt_cpufreq_set_perf() argument 96 base + policy->cpu * PER_CPU_OFFSET + REG_SET_PERF_STATE_OFFSET); in virt_cpufreq_set_perf() 100 static unsigned int virt_cpufreq_fast_switch(struct cpufreq_policy *policy, in virt_cpufreq_fast_switch() argument 103 virt_cpufreq_set_perf(policy, target_freq); in virt_cpufreq_fast_switch() 115 static int virt_cpufreq_target(struct cpufreq_policy *policy, in virt_cpufreq_target() argument 122 freqs.old = policy->cur; in virt_cpufreq_target() 125 cpufreq_freq_transition_begin(policy, &freqs); in virt_cpufreq_target() 126 ret = virt_cpufreq_set_perf(policy, target_freq); in virt_cpufreq_target() 127 cpufreq_freq_transition_end(policy, &freqs, ret != 0); in virt_cpufreq_target() 132 static int virt_cpufreq_get_sharing_cpus(struct cpufreq_policy *policy) in virt_cpufreq_get_sharing_cpus() argument 156 virt_cpufreq_get_freq_info(struct cpufreq_policy * policy) virt_cpufreq_get_freq_info() argument 187 virt_cpufreq_cpu_init(struct cpufreq_policy * policy) virt_cpufreq_cpu_init() argument 232 virt_cpufreq_cpu_exit(struct cpufreq_policy * policy) virt_cpufreq_cpu_exit() argument 238 virt_cpufreq_online(struct cpufreq_policy * policy) virt_cpufreq_online() argument 244 virt_cpufreq_offline(struct cpufreq_policy * policy) virt_cpufreq_offline() argument 250 virt_cpufreq_verify_policy(struct cpufreq_policy_data * policy) virt_cpufreq_verify_policy() argument [all...] |
| H A D | amd-pstate.c | 237 static int msr_update_perf(struct cpufreq_policy *policy, u8 min_perf, in msr_update_perf() argument 240 struct amd_cpudata *cpudata = policy->driver_data; in msr_update_perf() 258 policy->boost_enabled, in msr_update_perf() 281 static inline int amd_pstate_update_perf(struct cpufreq_policy *policy, 286 return static_call(amd_pstate_update_perf)(policy, min_perf, des_perf, in amd_pstate_update_perf() 290 static int msr_set_epp(struct cpufreq_policy *policy, u8 epp) in amd_pstate_update_perf() 292 struct amd_cpudata *cpudata = policy->driver_data; in msr_set_epp() argument 308 policy->boost_enabled, in msr_set_epp() 329 static inline int amd_pstate_set_epp(struct cpufreq_policy *policy, u8 epp) 331 return static_call(amd_pstate_set_epp)(policy, ep 283 amd_pstate_update_perf(struct cpufreq_policy * policy,u8 min_perf,u8 des_perf,u8 max_perf,u8 epp,bool fast_switch) amd_pstate_update_perf() argument 332 amd_pstate_set_epp(struct cpufreq_policy * policy,u8 epp) amd_pstate_set_epp() argument 337 amd_pstate_set_floor_perf(struct cpufreq_policy * policy,u8 perf) amd_pstate_set_floor_perf() argument 371 amd_pstate_init_floor_perf(struct cpufreq_policy * policy) amd_pstate_init_floor_perf() argument 406 shmem_set_epp(struct cpufreq_policy * policy,u8 epp) shmem_set_epp() argument 447 msr_cppc_enable(struct cpufreq_policy * policy) msr_cppc_enable() argument 452 shmem_cppc_enable(struct cpufreq_policy * policy) shmem_cppc_enable() argument 459 amd_pstate_cppc_enable(struct cpufreq_policy * policy) amd_pstate_cppc_enable() argument 557 shmem_update_perf(struct cpufreq_policy * policy,u8 min_perf,u8 des_perf,u8 max_perf,u8 epp,bool fast_switch) shmem_update_perf() argument 642 amd_pstate_update(struct cpufreq_policy * policy,u8 min_perf,u8 des_perf,u8 max_perf,bool fast_switch,int gov_flags) amd_pstate_update() argument 701 amd_pstate_update_min_max_limit(struct cpufreq_policy * policy) amd_pstate_update_min_max_limit() argument 733 amd_pstate_update_freq(struct cpufreq_policy * policy,unsigned int target_freq,bool fast_switch) amd_pstate_update_freq() argument 772 amd_pstate_target(struct cpufreq_policy * policy,unsigned int target_freq,unsigned int relation) amd_pstate_target() argument 779 amd_pstate_fast_switch(struct cpufreq_policy * policy,unsigned int target_freq) amd_pstate_fast_switch() argument 787 amd_pstate_adjust_perf(struct cpufreq_policy * policy,unsigned long _min_perf,unsigned long target_perf,unsigned long capacity) amd_pstate_adjust_perf() argument 827 amd_pstate_cpu_boost_update(struct cpufreq_policy * policy,bool on) amd_pstate_cpu_boost_update() argument 849 amd_pstate_set_boost(struct cpufreq_policy * policy,int state) amd_pstate_set_boost() argument 923 amd_pstate_update_limits(struct cpufreq_policy * policy) amd_pstate_update_limits() argument 1048 amd_pstate_cpu_init(struct cpufreq_policy * policy) amd_pstate_cpu_init() argument 1142 amd_pstate_cpu_exit(struct cpufreq_policy * policy) amd_pstate_cpu_exit() argument 1157 amd_pstate_get_balanced_epp(struct cpufreq_policy * policy) amd_pstate_get_balanced_epp() argument 1250 amd_pstate_clear_dynamic_epp(struct cpufreq_policy * policy) amd_pstate_clear_dynamic_epp() argument 1265 amd_pstate_set_dynamic_epp(struct cpufreq_policy * policy) amd_pstate_set_dynamic_epp() argument 1327 show_amd_pstate_max_freq(struct cpufreq_policy * policy,char * buf) show_amd_pstate_max_freq() argument 1335 show_amd_pstate_lowest_nonlinear_freq(struct cpufreq_policy * policy,char * buf) show_amd_pstate_lowest_nonlinear_freq() argument 1352 show_amd_pstate_highest_perf(struct cpufreq_policy * policy,char * buf) show_amd_pstate_highest_perf() argument 1362 show_amd_pstate_prefcore_ranking(struct cpufreq_policy * policy,char * buf) show_amd_pstate_prefcore_ranking() argument 1373 show_amd_pstate_hw_prefcore(struct cpufreq_policy * policy,char * buf) show_amd_pstate_hw_prefcore() argument 1385 show_energy_performance_available_preferences(struct cpufreq_policy * policy,char * buf) show_energy_performance_available_preferences() argument 1402 store_energy_performance_preference(struct cpufreq_policy * policy,const char * buf,size_t count) store_energy_performance_preference() argument 1446 show_energy_performance_preference(struct cpufreq_policy * policy,char * buf) show_energy_performance_preference() argument 1477 store_amd_pstate_floor_freq(struct cpufreq_policy * policy,const char * buf,size_t count) store_amd_pstate_floor_freq() argument 1502 show_amd_pstate_floor_freq(struct cpufreq_policy * policy,char * buf) show_amd_pstate_floor_freq() argument 1509 show_amd_pstate_floor_count(struct cpufreq_policy * policy,char * buf) show_amd_pstate_floor_count() argument 1880 amd_pstate_epp_cpu_init(struct cpufreq_policy * policy) amd_pstate_epp_cpu_init() argument 1974 amd_pstate_epp_cpu_exit(struct cpufreq_policy * policy) amd_pstate_epp_cpu_exit() argument 1995 amd_pstate_epp_update_limit(struct cpufreq_policy * policy,bool policy_change) amd_pstate_epp_update_limit() argument 2017 amd_pstate_epp_set_policy(struct cpufreq_policy * policy) amd_pstate_epp_set_policy() argument 2040 amd_pstate_cpu_online(struct cpufreq_policy * policy) amd_pstate_cpu_online() argument 2055 amd_pstate_cpu_offline(struct cpufreq_policy * policy) amd_pstate_cpu_offline() argument 2077 amd_pstate_suspend(struct cpufreq_policy * policy) amd_pstate_suspend() argument 2106 amd_pstate_resume(struct cpufreq_policy * policy) amd_pstate_resume() argument 2124 amd_pstate_epp_resume(struct cpufreq_policy * policy) amd_pstate_epp_resume() argument [all...] |
| H A D | gx-suspmod.c | 136 /* For the default policy, we want at least some processing power 250 static void gx_set_cpuspeed(struct cpufreq_policy *policy, unsigned int khz) in gx_set_cpuspeed() argument 264 cpufreq_freq_transition_begin(policy, &freqs); in gx_set_cpuspeed() 313 cpufreq_freq_transition_end(policy, &freqs, 0); in gx_set_cpuspeed() 331 static int cpufreq_gx_verify(struct cpufreq_policy_data *policy) in cpufreq_gx_verify() argument 336 if (!stock_freq || !policy) in cpufreq_gx_verify() 339 policy->cpu = 0; in cpufreq_gx_verify() 340 cpufreq_verify_within_limits(policy, (stock_freq / max_duration), in cpufreq_gx_verify() 344 * within policy->min and policy in cpufreq_gx_verify() 371 cpufreq_gx_target(struct cpufreq_policy * policy,unsigned int target_freq,unsigned int relation) cpufreq_gx_target() argument 398 cpufreq_gx_cpu_init(struct cpufreq_policy * policy) cpufreq_gx_cpu_init() argument [all...] |
| H A D | cpufreq_governor.c | 90 * (that may be a single policy or a bunch of them if governor tunables are 93 * Call under the @dbs_data->attr_set.update_lock. The per-policy 94 * update_mutex is acquired and released internally for each policy. 110 for_each_cpu(j, policy_dbs->policy->cpus) { in gov_update_cpu_data() 122 unsigned int dbs_update(struct cpufreq_policy *policy) in dbs_update() 124 struct policy_dbs_info *policy_dbs = policy->governor_data; in dbs_update() 146 for_each_cpu(j, policy->cpus) { in dbs_update() 251 struct cpufreq_policy *policy; in dbs_work_handler() 255 policy = policy_dbs->policy; in dbs_work_handler() 114 dbs_update(struct cpufreq_policy * policy) dbs_update() argument 236 struct cpufreq_policy *policy; dbs_work_handler() local 326 struct cpufreq_policy *policy = policy_dbs->policy; gov_set_update_util() local 340 gov_clear_update_util(struct cpufreq_policy * policy) gov_clear_update_util() argument 350 alloc_policy_dbs_info(struct cpufreq_policy * policy,struct dbs_governor * gov) alloc_policy_dbs_info() argument 401 cpufreq_dbs_governor_init(struct cpufreq_policy * policy) cpufreq_dbs_governor_init() argument 491 cpufreq_dbs_governor_exit(struct cpufreq_policy * policy) cpufreq_dbs_governor_exit() argument 514 cpufreq_dbs_governor_start(struct cpufreq_policy * policy) cpufreq_dbs_governor_start() argument 552 cpufreq_dbs_governor_stop(struct cpufreq_policy * policy) cpufreq_dbs_governor_stop() argument 564 cpufreq_dbs_governor_limits(struct cpufreq_policy * policy) cpufreq_dbs_governor_limits() argument [all...] |
| H A D | amd-pstate-ut.c | 153 struct cpufreq_policy *policy __free(put_cpufreq_policy) = NULL; in amd_pstate_ut_check_perf() 156 policy = cpufreq_cpu_get(cpu); in amd_pstate_ut_check_perf() 157 if (!policy) in amd_pstate_ut_check_perf() 159 cpudata = policy->driver_data; in amd_pstate_ut_check_perf() 225 struct cpufreq_policy *policy __free(put_cpufreq_policy) = NULL; in amd_pstate_ut_check_freq() 228 policy = cpufreq_cpu_get(cpu); in amd_pstate_ut_check_freq() 229 if (!policy) in amd_pstate_ut_check_freq() 231 cpudata = policy->driver_data; in amd_pstate_ut_check_freq() 233 if (!((policy->cpuinfo.max_freq >= cpudata->nominal_freq) && in amd_pstate_ut_check_freq() 235 (cpudata->lowest_nonlinear_freq >= policy->cpuinfo.min_freq) && in amd_pstate_ut_check_freq() [all …]
|
| H A D | qcom-cpufreq-hw.c | 60 struct cpufreq_policy *policy; 74 static int qcom_cpufreq_set_bw(struct cpufreq_policy *policy, in qcom_cpufreq_set_bw() 82 dev = get_cpu_device(policy->cpu); in qcom_cpufreq_set_bw() 115 static int qcom_cpufreq_hw_target_index(struct cpufreq_policy *policy, in qcom_cpufreq_hw_target_index() 118 struct qcom_cpufreq_data *data = policy->driver_data; in qcom_cpufreq_hw_target_index() 120 unsigned long freq = policy->freq_table[index].frequency; in qcom_cpufreq_hw_target_index() 126 for (i = 1; i < cpumask_weight(policy->related_cpus); i++) in qcom_cpufreq_hw_target_index() 130 qcom_cpufreq_set_bw(policy, freq); in qcom_cpufreq_hw_target_index() 148 static unsigned int qcom_cpufreq_get_freq(struct cpufreq_policy *policy) in qcom_cpufreq_get_freq() 154 if (!policy) in qcom_cpufreq_get_freq() 58 struct cpufreq_policy *policy; global() member 72 qcom_cpufreq_set_bw(struct cpufreq_policy * policy,unsigned long freq_khz) qcom_cpufreq_set_bw() argument 113 qcom_cpufreq_hw_target_index(struct cpufreq_policy * policy,unsigned int index) qcom_cpufreq_hw_target_index() argument 146 qcom_cpufreq_get_freq(struct cpufreq_policy * policy) qcom_cpufreq_get_freq() argument 164 __qcom_cpufreq_hw_get(struct cpufreq_policy * policy) __qcom_cpufreq_hw_get() argument 184 qcom_cpufreq_hw_fast_switch(struct cpufreq_policy * policy,unsigned int target_freq) qcom_cpufreq_hw_fast_switch() argument 203 qcom_cpufreq_hw_read_lut(struct device * cpu_dev,struct cpufreq_policy * policy) qcom_cpufreq_hw_read_lut() argument 328 struct cpufreq_policy *policy = data->policy; qcom_lmh_dcvs_notify() local 428 qcom_cpufreq_hw_lmh_init(struct cpufreq_policy * policy,int index) qcom_cpufreq_hw_lmh_init() argument 465 qcom_cpufreq_hw_cpu_online(struct cpufreq_policy * policy) qcom_cpufreq_hw_cpu_online() argument 486 qcom_cpufreq_hw_cpu_offline(struct cpufreq_policy * policy) qcom_cpufreq_hw_cpu_offline() argument 512 qcom_cpufreq_hw_cpu_init(struct cpufreq_policy * policy) qcom_cpufreq_hw_cpu_init() argument 572 qcom_cpufreq_hw_cpu_exit(struct cpufreq_policy * policy) qcom_cpufreq_hw_cpu_exit() argument 584 qcom_cpufreq_ready(struct cpufreq_policy * policy) qcom_cpufreq_ready() argument [all...] |
| H A D | cpufreq_ondemand.c | 37 static unsigned int generic_powersave_bias_target(struct cpufreq_policy *policy, in generic_powersave_bias_target() argument 44 struct policy_dbs_info *policy_dbs = policy->governor_data; in generic_powersave_bias_target() 48 struct cpufreq_frequency_table *freq_table = policy->freq_table; in generic_powersave_bias_target() 56 index = cpufreq_frequency_table_target(policy, freq_next, policy->min, in generic_powersave_bias_target() 57 policy->max, relation); in generic_powersave_bias_target() 63 index = cpufreq_table_find_index_h(policy, freq_avg, in generic_powersave_bias_target() 66 index = cpufreq_table_find_index_l(policy, freq_avg, in generic_powersave_bias_target() 85 static void ondemand_powersave_bias_init(struct cpufreq_policy *policy) in ondemand_powersave_bias_init() argument 87 struct od_policy_dbs_info *dbs_info = to_dbs_info(policy->governor_data); in ondemand_powersave_bias_init() 92 static void dbs_freq_increase(struct cpufreq_policy *policy, unsigned int freq) in dbs_freq_increase() argument [all …]
|
| H A D | longrun.c | 30 * longrun_get_policy - get the current LongRun policy 31 * @policy: struct cpufreq_policy where current policy is written into 33 * Reads the current LongRun policy by access to MSR_TMTA_LONGRUN_FLAGS 36 static void longrun_get_policy(struct cpufreq_policy *policy) in longrun_get_policy() 43 policy->policy = CPUFREQ_POLICY_PERFORMANCE; in longrun_get_policy() 45 policy->policy = CPUFREQ_POLICY_POWERSAVE; in longrun_get_policy() 54 policy in longrun_get_policy() 35 longrun_get_policy(struct cpufreq_policy * policy) longrun_get_policy() argument 71 longrun_set_policy(struct cpufreq_policy * policy) longrun_set_policy() argument 125 longrun_verify_policy(struct cpufreq_policy_data * policy) longrun_verify_policy() argument 252 longrun_cpu_init(struct cpufreq_policy * policy) longrun_cpu_init() argument [all...] |
| H A D | mediatek-cpufreq-hw.c | 100 struct cpufreq_policy *policy; in mtk_cpufreq_get_cpu_power() local 103 policy = cpufreq_cpu_get_raw(cpu_dev->id); in mtk_cpufreq_get_cpu_power() 104 if (!policy) in mtk_cpufreq_get_cpu_power() 107 data = policy->driver_data; in mtk_cpufreq_get_cpu_power() 124 struct cpufreq_policy *policy) in mtk_cpufreq_hw_fdvfs_switch() argument 126 struct mtk_cpufreq_domain *data = policy->driver_data; in mtk_cpufreq_hw_fdvfs_switch() 131 for_each_cpu(cpu, policy->real_cpus) { in mtk_cpufreq_hw_fdvfs_switch() 136 static int mtk_cpufreq_hw_target_index(struct cpufreq_policy *policy, in mtk_cpufreq_hw_target_index() argument 139 struct mtk_cpufreq_domain *data = policy->driver_data; in mtk_cpufreq_hw_target_index() 143 target_freq = policy->freq_table[index].frequency; in mtk_cpufreq_hw_target_index() [all …]
|
| H A D | apple-soc-cpufreq.c | 137 struct cpufreq_policy *policy; in apple_soc_cpufreq_get_rate() local 142 policy = cpufreq_cpu_get_raw(cpu); in apple_soc_cpufreq_get_rate() 143 if (unlikely(!policy)) in apple_soc_cpufreq_get_rate() 146 priv = policy->driver_data; in apple_soc_cpufreq_get_rate() 162 cpufreq_for_each_valid_entry(p, policy->freq_table) in apple_soc_cpufreq_get_rate() 171 static int apple_soc_cpufreq_set_target(struct cpufreq_policy *policy, in apple_soc_cpufreq_set_target() argument 174 struct apple_cpu_priv *priv = policy->driver_data; in apple_soc_cpufreq_set_target() 175 unsigned int pstate = policy->freq_table[index].driver_data; in apple_soc_cpufreq_set_target() 199 static unsigned int apple_soc_cpufreq_fast_switch(struct cpufreq_policy *policy, in apple_soc_cpufreq_set_target() 202 if (apple_soc_cpufreq_set_target(policy, polic in apple_soc_cpufreq_fast_switch() 201 apple_soc_cpufreq_fast_switch(struct cpufreq_policy * policy,unsigned int target_freq) apple_soc_cpufreq_fast_switch() argument 210 apple_soc_cpufreq_find_cluster(struct cpufreq_policy * policy,void __iomem ** reg_base,const struct apple_soc_cpufreq_info ** info) apple_soc_cpufreq_find_cluster() argument 238 apple_soc_cpufreq_init(struct cpufreq_policy * policy) apple_soc_cpufreq_init() argument 332 apple_soc_cpufreq_exit(struct cpufreq_policy * policy) apple_soc_cpufreq_exit() argument [all...] |
| H A D | scpi-cpufreq.c | 32 struct cpufreq_policy *policy; in scpi_cpufreq_get_rate() local 36 policy = cpufreq_cpu_get_raw(cpu); in scpi_cpufreq_get_rate() 37 if (unlikely(!policy)) in scpi_cpufreq_get_rate() 40 priv = policy->driver_data; in scpi_cpufreq_get_rate() 47 scpi_cpufreq_set_target(struct cpufreq_policy *policy, unsigned int index) in scpi_cpufreq_set_target() argument 49 unsigned long freq_khz = policy->freq_table[index].frequency; in scpi_cpufreq_set_target() 50 struct scpi_data *priv = policy->driver_data; in scpi_cpufreq_set_target() 91 static int scpi_cpufreq_init(struct cpufreq_policy *policy) in scpi_cpufreq_init() argument 99 cpu_dev = get_cpu_device(policy->cpu); in scpi_cpufreq_init() 101 pr_err("failed to get cpu%d device\n", policy->cpu); in scpi_cpufreq_init() [all …]
|
| H A D | cpufreq_conservative.c | 38 struct cpufreq_policy *policy) in get_freq_step() argument 40 unsigned int freq_step = (cs_tuners->freq_step * policy->max) / 100; in get_freq_step() 58 static unsigned int cs_dbs_update(struct cpufreq_policy *policy) in cs_dbs_update() argument 60 struct policy_dbs_info *policy_dbs = policy->governor_data; in cs_dbs_update() 65 unsigned int load = dbs_update(policy); in cs_dbs_update() 80 if (requested_freq > policy->max || requested_freq < policy->min) { in cs_dbs_update() 81 requested_freq = policy->cur; in cs_dbs_update() 85 freq_step = get_freq_step(cs_tuners, policy); in cs_dbs_update() 94 if (requested_freq > policy in cs_dbs_update() 308 cs_start(struct cpufreq_policy * policy) cs_start() argument 316 cs_limits(struct cpufreq_policy * policy) cs_limits() argument [all...] |
| H A D | cpufreq_stats.c | 58 static ssize_t show_total_trans(struct cpufreq_policy *policy, char *buf) in show_total_trans() argument 60 struct cpufreq_stats *stats = policy->stats; in show_total_trans() 69 static ssize_t show_time_in_state(struct cpufreq_policy *policy, char *buf) in show_time_in_state() argument 71 struct cpufreq_stats *stats = policy->stats; in show_time_in_state() 103 static ssize_t store_reset(struct cpufreq_policy *policy, const char *buf, in store_reset() argument 106 struct cpufreq_stats *stats = policy->stats; in store_reset() 124 static ssize_t show_trans_table(struct cpufreq_policy *policy, char *buf) in show_trans_table() argument 126 struct cpufreq_stats *stats = policy->stats; in show_trans_table() 194 void cpufreq_stats_free_table(struct cpufreq_policy *policy) in cpufreq_stats_free_table() argument 196 struct cpufreq_stats *stats = policy->stats; in cpufreq_stats_free_table() [all …]
|
| /linux/fs/crypto/ |
| H A D | policy.c | 38 int fscrypt_policy_to_key_spec(const union fscrypt_policy *policy, in fscrypt_policy_to_key_spec() argument 41 switch (policy->version) { in fscrypt_policy_to_key_spec() 44 memcpy(key_spec->u.descriptor, policy->v1.master_key_descriptor, in fscrypt_policy_to_key_spec() 49 memcpy(key_spec->u.identifier, policy->v2.master_key_identifier, in fscrypt_policy_to_key_spec() 122 static bool supported_iv_ino_lblk_policy(const struct fscrypt_policy_v2 *policy, in supported_iv_ino_lblk_policy() argument 125 const char *type = (policy->flags & FSCRYPT_POLICY_FLAG_IV_INO_LBLK_64) in supported_iv_ino_lblk_policy() 136 if (policy->contents_encryption_mode != FSCRYPT_MODE_AES_256_XTS) { in supported_iv_ino_lblk_policy() 174 fscrypt_policy_v2_du_bits(policy, inode)) > 32) { in supported_iv_ino_lblk_policy() 183 static bool fscrypt_supported_v1_policy(const struct fscrypt_policy_v1 *policy, in fscrypt_supported_v1_policy() argument 186 if (!fscrypt_valid_enc_modes_v1(policy->contents_encryption_mode, in fscrypt_supported_v1_policy() [all …]
|
| /linux/Documentation/translations/zh_CN/cpu-freq/ |
| H A D | cpu-drivers.rst | 58 .init - 一个指向per-policy初始化函数的指针。 78 .exit - 一个指向per-policy清理函数的指针,该函数在CPU热插拔过程的CPU_POST_DEAD 81 .suspend - 一个指向per-policy暂停函数的指针,该函数在关中断且在该策略的调节器停止 84 .resume - 一个指向per-policy恢复函数的指针,该函数在关中断且在调节器再一次启动前被 87 .ready - 一个指向per-policy准备函数的指针,该函数在策略完全初始化之后被调用。 94 .set_boost - 一个指向per-policy函数的指针,该函数用来开启/关闭提升(boost)频率功能。 101 略不存在,则会调用per-policy的初始化函数cpufreq_driver.init。请注意,.init()和.exit()例程 103 *policy`` 作为参数。现在该怎么做呢? 110 |policy->cpuinfo.min_freq和 | 该CPU支持的最低和最高频率(kHz) | 111 |policy->cpuinfo.max_freq | | [all …]
|
| /linux/Documentation/translations/zh_TW/cpu-freq/ |
| H A D | cpu-drivers.rst | 58 .init - 一個指向per-policy初始化函數的指針。 78 .exit - 一個指向per-policy清理函數的指針,該函數在CPU熱插拔過程的CPU_POST_DEAD 81 .suspend - 一個指向per-policy暫停函數的指針,該函數在關中斷且在該策略的調節器停止 84 .resume - 一個指向per-policy恢復函數的指針,該函數在關中斷且在調節器再一次啓動前被 87 .ready - 一個指向per-policy準備函數的指針,該函數在策略完全初始化之後被調用。 94 .set_boost - 一個指向per-policy函數的指針,該函數用來開啓/關閉提升(boost)頻率功能。 101 略不存在,則會調用per-policy的初始化函數cpufreq_driver.init。請注意,.init()和.exit()例程 103 *policy`` 作爲參數。現在該怎麼做呢? 110 |policy->cpuinfo.min_freq和 | 該CPU支持的最低和最高頻率(kHz) | 111 |policy->cpuinfo.max_freq | | [all …]
|
| /linux/drivers/hwtracing/stm/ |
| H A D | policy.c | 31 struct stp_policy *policy; member 110 stm = policy_node->policy->stm; in stp_policy_node_masters_store() 157 stm = policy_node->policy->stm; in stp_policy_node_channels_store() 228 struct stp_policy *policy; in stp_policy_node_make() local 231 policy = container_of(group, struct stp_policy, group); in stp_policy_node_make() 235 policy = parent_node->policy; in stp_policy_node_make() 238 if (!policy->stm) in stp_policy_node_make() 241 pdrv = policy->stm->pdrv; in stp_policy_node_make() 251 if (policy->stm->pdrv_node_type) in stp_policy_node_make() 252 type = policy->stm->pdrv_node_type; in stp_policy_node_make() [all …]
|
| /linux/drivers/thermal/ |
| H A D | cpufreq_cooling.c | 60 * @policy: cpufreq policy. 73 struct cpufreq_policy *policy; member 237 struct cpufreq_policy *policy = cpufreq_cdev->policy; in cpufreq_get_requested_power() local 239 freq = cpufreq_quick_get(policy->cpu); in cpufreq_get_requested_power() 241 for_each_cpu(cpu, policy->related_cpus) { in cpufreq_get_requested_power() 256 trace_thermal_power_cpu_get_power_simple(policy->cpu, *power); in cpufreq_get_requested_power() 285 num_cpus = cpumask_weight(cpufreq_cdev->policy->cpus); in cpufreq_state2power() 320 struct cpufreq_policy *policy in cpufreq_power2state() local 334 struct cpufreq_policy *policy; em_is_sane() local 392 struct cpufreq_policy *policy; get_state_freq() local 516 __cpufreq_cooling_register(struct device_node * np,struct cpufreq_policy * policy,struct em_perf_domain * em) __cpufreq_cooling_register() argument 625 cpufreq_cooling_register(struct cpufreq_policy * policy) cpufreq_cooling_register() argument 648 of_cpufreq_cooling_register(struct cpufreq_policy * policy) of_cpufreq_cooling_register() argument [all...] |
| /linux/net/netlink/ |
| H A D | policy.c | 22 const struct nla_policy *policy; member 28 const struct nla_policy *policy, in add_policy() argument 34 if (!policy) in add_policy() 38 if (state->policies[i].policy == policy && in add_policy() 42 if (!state->policies[i].policy) { in add_policy() 43 state->policies[i].policy = policy; in add_policy() 60 state->policies[old_n_alloc].policy = policy; in add_policy() 83 netlink_policy_dump_get_policy_idx(struct netlink_policy_dump_state * state,const struct nla_policy * policy,unsigned int maxtype) netlink_policy_dump_get_policy_idx() argument 127 netlink_policy_dump_add_policy(struct netlink_policy_dump_state ** pstate,const struct nla_policy * policy,unsigned int maxtype) netlink_policy_dump_add_policy() argument 152 const struct nla_policy *policy; netlink_policy_dump_add_policy() local 438 struct nlattr *policy; netlink_policy_dump_write() local [all...] |
| /linux/kernel/sched/ |
| H A D | syscalls.c | 19 static inline int __normal_prio(int policy, int rt_prio, int nice) in __normal_prio() argument 23 if (dl_policy(policy)) in __normal_prio() 25 else if (rt_policy(policy)) in __normal_prio() 42 return __normal_prio(p->policy, p->rt_priority, PRIO_TO_NICE(p->static_prio)); in normal_prio() 244 int policy = attr->sched_policy; in DEFINE_CLASS() local 246 if (policy == SETPARAM_POLICY) in DEFINE_CLASS() 247 policy = p->policy; in DEFINE_CLASS() 249 p->policy = policy; in DEFINE_CLASS() 251 if (dl_policy(policy)) in DEFINE_CLASS() 253 else if (fair_policy(policy)) in DEFINE_CLASS() [all …]
|
| /linux/tools/perf/Documentation/ |
| H A D | security.txt | 13 Targeted policy with perf_event_open() access control capabilities: 15 1. Download selinux-policy SRPM package (e.g. selinux-policy-3.14.4-48.fc31.src.rpm on FC31) 18 # rpm -Uhv selinux-policy-3.14.4-48.fc31.src.rpm 22 # rpmbuild -bp selinux-policy.spec 24 3. Place patch below at rpmbuild/BUILD/selinux-policy-b86eaaf4dbcf2d51dd4432df7185c0eaf3cbcc02 27 # patch -p1 < selinux-policy-perf-events-perfmon.patch 28 patching file policy/flask/access_vectors 29 patching file policy/flask/security_classes 30 # cat selinux-policy-perf-events-perfmon.patch 31 diff -Nura a/policy/flask/access_vectors b/policy/flask/access_vectors [all …]
|
| /linux/security/selinux/ss/ |
| H A D | services.c | 242 struct selinux_policy *policy; in security_mls_enabled() local 248 policy = rcu_dereference(selinux_state.policy); in security_mls_enabled() 249 mls_enabled = policy->policydb.mls_enabled; in security_mls_enabled() 725 static int security_validtrans_handle_fail(struct selinux_policy *policy, in security_validtrans_handle_fail() argument 731 struct policydb *p = &policy->policydb; in security_validtrans_handle_fail() 732 struct sidtab *sidtab = policy->sidtab; in security_validtrans_handle_fail() 759 struct selinux_policy *policy; in security_compute_validatetrans() local 776 policy = rcu_dereference(selinux_state.policy); in security_compute_validatetrans() 777 policydb = &policy->policydb; in security_compute_validatetrans() 778 sidtab = policy->sidtab; in security_compute_validatetrans() [all …]
|