summaryrefslogtreecommitdiff
path: root/rust/helpers/cpufreq.c
diff options
context:
space:
mode:
authorViresh Kumar <viresh.kumar@linaro.org>2025-01-07 12:51:08 +0530
committerViresh Kumar <viresh.kumar@linaro.org>2025-05-20 11:21:10 +0530
commit2207856ff0bc8d953d6e89bda70b8978c2de8bab (patch)
tree353d3d345dad563f19d2cae0d6f6d2f40dff7f8b /rust/helpers/cpufreq.c
parentce32e2d47ce6c472a931eabe53f841c62b6abfe5 (diff)
rust: cpufreq: Add initial abstractions for cpufreq framework
Introduce initial Rust abstractions for the cpufreq core. This includes basic representations for cpufreq flags, relation types, and the cpufreq table. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Diffstat (limited to 'rust/helpers/cpufreq.c')
-rw-r--r--rust/helpers/cpufreq.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/rust/helpers/cpufreq.c b/rust/helpers/cpufreq.c
new file mode 100644
index 000000000000..7c1343c4d65e
--- /dev/null
+++ b/rust/helpers/cpufreq.c
@@ -0,0 +1,10 @@
+// SPDX-License-Identifier: GPL-2.0
+
+#include <linux/cpufreq.h>
+
+#ifdef CONFIG_CPU_FREQ
+void rust_helper_cpufreq_register_em_with_opp(struct cpufreq_policy *policy)
+{
+ cpufreq_register_em_with_opp(policy);
+}
+#endif