Function sched_setscheduler
pub unsafe fn sched_setscheduler(
pid: i32,
policy: i32,
param: &sched_param_t,
) -> Result<(), i32> ⓘ
Available on crate feature
dep_nc
only.Expand description
Set scheduling parameter.
§Examples
let sched_param = nc::sched_param_t { sched_priority: 12 };
let ret = unsafe { nc::sched_setscheduler(0, nc::SCHED_RR, &sched_param) };
assert_eq!(ret, Err(nc::EPERM));