From 6c9ab470400378a8bb1413ec51b5af33e6aebfa1 Mon Sep 17 00:00:00 2001 From: Li-Wen Hsu Date: Tue, 23 Aug 2022 18:51:45 +0800 Subject: [PATCH] Add CPU_SETSIZE const for FreeBSD --- libc-test/semver/freebsd.txt | 1 + src/unix/bsd/freebsdlike/freebsd/mod.rs | 3 +++ 2 files changed, 4 insertions(+) diff --git a/libc-test/semver/freebsd.txt b/libc-test/semver/freebsd.txt index 5e07b6395632a..2ef6844af855f 100644 --- a/libc-test/semver/freebsd.txt +++ b/libc-test/semver/freebsd.txt @@ -173,6 +173,7 @@ CPU_LEVEL_CPUSET CPU_LEVEL_ROOT CPU_LEVEL_WHICH CPU_SET +CPU_SETSIZE CPU_WHICH_CPUSET CPU_WHICH_IRQ CPU_WHICH_JAIL diff --git a/src/unix/bsd/freebsdlike/freebsd/mod.rs b/src/unix/bsd/freebsdlike/freebsd/mod.rs index 5c696f73bcee1..070ec77b33704 100644 --- a/src/unix/bsd/freebsdlike/freebsd/mod.rs +++ b/src/unix/bsd/freebsdlike/freebsd/mod.rs @@ -1890,6 +1890,9 @@ pub const LIO_READV: ::c_int = 6; pub const DEVSTAT_N_TRANS_FLAGS: ::c_int = 4; pub const DEVSTAT_NAME_LEN: ::c_int = 16; +// sys/cpuset.h +pub const CPU_SETSIZE: ::c_int = 256; + pub const SIGEV_THREAD_ID: ::c_int = 4; pub const EXTATTR_NAMESPACE_EMPTY: ::c_int = 0;