Lines Matching full:cpufreq

5 //! This module provides rust abstractions for interacting with the cpufreq subsystem.
7 //! C header: [`include/linux/cpufreq.h`](srctree/include/linux/cpufreq.h)
9 //! Reference: <https://docs.kernel.org/admin-guide/pm/cpufreq.html>
54 /// Supports multiple clock domains with per-policy governors in `cpu/cpuN/cpufreq/`.
209 /// use kernel::cpufreq::{Policy, TableIndex};
325 /// use kernel::cpufreq::{TableBuilder, TableIndex};
402 /// use kernel::cpufreq::{DEFAULT_TRANSITION_LATENCY_NS, Policy};
540 /// Gets [`cpumask::Cpumask`] for a cpufreq [`Policy`].
838 /// The following example demonstrates how to register a cpufreq driver.
842 /// cpufreq,
854 /// impl cpufreq::Driver for SampleDriver {
855 /// const NAME: &'static CStr = c"cpufreq-sample";
856 /// const FLAGS: u16 = cpufreq::flags::NEED_INITIAL_FREQ_CHECK | cpufreq::flags::IS_COOLING_DEV;
861 /// fn init(policy: &mut cpufreq::Policy) -> Result<Self::PData> {
866 /// fn exit(_policy: &mut cpufreq::Policy, _data: Option<Self::PData>) -> Result {
870 /// fn suspend(policy: &mut cpufreq::Policy) -> Result {
874 /// fn verify(data: &mut cpufreq::PolicyData) -> Result {
878 /// fn target_index(policy: &mut cpufreq::Policy, index: cpufreq::TableIndex) -> Result {
883 /// fn get(policy: &mut cpufreq::Policy) -> Result<u32> {
896 /// cpufreq::Registration::<SampleDriver>::new_foreign_owned(pdev.as_ref())?;
909 /// SAFETY: Registration with and unregistration from the cpufreq subsystem can happen from any
1034 /// Registers a CPU frequency driver with the cpufreq core.
1036 // We can't use `&Self::VTABLE` directly because the cpufreq core modifies some fields in
1064 /// - This function may only be called from the cpufreq C infrastructure.
1082 /// - This function may only be called from the cpufreq C infrastructure.
1097 /// - This function may only be called from the cpufreq C infrastructure.
1112 /// - This function may only be called from the cpufreq C infrastructure.
1127 /// - This function may only be called from the cpufreq C infrastructure.
1142 /// - This function may only be called from the cpufreq C infrastructure.
1157 /// - This function may only be called from the cpufreq C infrastructure.
1170 /// - This function may only be called from the cpufreq C infrastructure.
1185 /// - This function may only be called from the cpufreq C infrastructure.
1200 /// - This function may only be called from the cpufreq C infrastructure.
1219 /// - This function may only be called from the cpufreq C infrastructure.
1242 /// - This function may only be called from the cpufreq C infrastructure.
1258 /// - This function may only be called from the cpufreq C infrastructure.
1277 /// - This function may only be called from the cpufreq C infrastructure.
1298 /// - This function may only be called from the cpufreq C infrastructure.
1321 /// - This function may only be called from the cpufreq C infrastructure.
1333 /// - This function may only be called from the cpufreq C infrastructure.
1346 /// - This function may only be called from the cpufreq C infrastructure.
1364 /// - This function may only be called from the cpufreq C infrastructure.
1382 /// - This function may only be called from the cpufreq C infrastructure.
1393 /// Unregisters with the cpufreq core.