diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2019-11-24 17:31:09 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-11-24 17:31:09 +0000 |
commit | f3bf1df774a6cb89cf04dced385ec073908508b0 (patch) | |
tree | 45d85c77d0e616e221f380ad2125a68b0e878165 /CHANGELOG.md | |
parent | 3c7a23b52d238bd502392883a55c5b792af3a05e (diff) | |
parent | 18c20381b094d7d8273d1a961052c22493c6b21c (diff) | |
download | nix-f3bf1df774a6cb89cf04dced385ec073908508b0.zip |
Merge #1148
1148: Implement sched::sched_getaffinity() r=asomers a=thib-ack
Hello,
I found the function `sched::sched_setaffinity()` but I also needed to get the process affinity and I did not find the function `sched::sched_getaffinity()`
So I added the function which maps [sched_getaffinity(2)](https://linux.die.net/man/2/sched_getaffinity) which "get a process's CPU affinity mask" to the sched.rs file.
I hope the code match your guidelines (returned `Result<CpuSet>` instead of pointer parameter)
If that's not the case, tell me, I will fix asap.
I hope this will help !
Thanks,
Thibaut
Co-authored-by: Thibaut Ackermann <thibaut@ackermann.dev>
Diffstat (limited to 'CHANGELOG.md')
-rw-r--r-- | CHANGELOG.md | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index d0f6b087..e4fe67da 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -30,6 +30,9 @@ This project adheres to [Semantic Versioning](http://semver.org/). - Added `linkat` ([#1101](https://github.com/nix-rust/nix/pull/1101)) +- Added `sched_getaffinity`. + ([#1148](https://github.com/nix-rust/nix/pull/1148)) + ### Changed - `sys::socket::recvfrom` now returns `Result<(usize, Option<SockAddr>)>` instead of `Result<(usize, SockAddr)>`. |