#linux #intel #pstate

intel-pstate

Fetch and modify Intel pstate kernel parameters

4 releases

0.2.1 Apr 29, 2020
0.2.0 May 13, 2019
0.1.1 Dec 26, 2018
0.1.0 Dec 6, 2018

#3 in #intel

Download history 40/week @ 2020-04-13 34/week @ 2020-04-20 44/week @ 2020-04-27 44/week @ 2020-05-04 38/week @ 2020-05-11 33/week @ 2020-05-18 61/week @ 2020-05-25 71/week @ 2020-06-01 137/week @ 2020-06-08 80/week @ 2020-06-15 148/week @ 2020-06-22 186/week @ 2020-06-29 167/week @ 2020-07-06 76/week @ 2020-07-13 134/week @ 2020-07-20 93/week @ 2020-07-27

143 downloads per month

MIT license

7KB
113 lines

intel-pstate

Rust crate for fetching and modifying intel_pstate kernel parameters.

use std::io;
use intel_pstate::PState;

fn main() -> io::Result<()> {
    if let Ok(pstate) = PState::new() {
        pstate.set_min_perf_pct(50)?;
        pstate.set_max_perf_pct(100)?;
        pstate.set_no_turbo(false)?;
    }

    Ok(())
}

lib.rs:

Crate for fetching and modifying the intel_pstate kernel parameters.

Example

use std::io;
use intel_pstate::PState;

fn main() -> io::Result<()> {
    if let Ok(pstate) = PState::new() {
        pstate.set_min_perf_pct(50)?;
        pstate.set_max_perf_pct(100)?;
        pstate.set_no_turbo(false)?;
    }

    Ok(())
}

Dependencies

~0.5–0.9MB
~19K SLoC