diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2025-06-12 14:23:56 +0300 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2025-06-12 14:23:56 +0300 |
commit | 332d6a94ce80efae2e6b38e01a46e92230577354 (patch) | |
tree | ca697ecc8168ed4d9ca9315ac08ed530ac204c61 /rust/helpers/cpu.c | |
parent | 19272b37aa4f83ca52bdf9c16d5d81bdd1354494 (diff) | |
parent | c7f005f70d22cd5613cac30bf6d34867189e36a9 (diff) | |
download | linux-332d6a94ce80efae2e6b38e01a46e92230577354.tar.xz |
Merge tag 'cpufreq-arm-fixes-6.16-rc' of git://git.kernel.org/pub/scm/linux/kernel/git/vireshk/pm
Merge CPUFreq fixes for 6.16-rc from Viresh Kumar:
"- Implement CpuId rust abstraction and use it to fix doctest failure
(Viresh Kumar).
- Minor cleanups in the `# Safety` sections for cpufreq abstractions
(Viresh Kumar)."
* tag 'cpufreq-arm-fixes-6.16-rc' of git://git.kernel.org/pub/scm/linux/kernel/git/vireshk/pm:
rust: cpu: Add CpuId::current() to retrieve current CPU ID
rust: Use CpuId in place of raw CPU numbers
rust: cpu: Introduce CpuId abstraction
cpufreq: Convert `/// SAFETY` lines to `# Safety` sections
Diffstat (limited to 'rust/helpers/cpu.c')
-rw-r--r-- | rust/helpers/cpu.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/rust/helpers/cpu.c b/rust/helpers/cpu.c new file mode 100644 index 000000000000..824e0adb19d4 --- /dev/null +++ b/rust/helpers/cpu.c @@ -0,0 +1,8 @@ +// SPDX-License-Identifier: GPL-2.0 + +#include <linux/smp.h> + +unsigned int rust_helper_raw_smp_processor_id(void) +{ + return raw_smp_processor_id(); +} |