summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2021-07-27 19:43:16 +0000
committerbors <bors@rust-lang.org>2021-07-27 19:43:16 +0000
commita6773b85bdc2c55a6cc56264cdf4c161cc8a0e2d (patch)
tree9d4a552a1ba8c432eb095598bc54dc039f332458
parent36a6a8e254db89cd31d178b4ba102055ceabf9a8 (diff)
parent399d798929f404ccae732549b9293c3de1fc6ee9 (diff)
downloadrust-libc-a6773b85bdc2c55a6cc56264cdf4c161cc8a0e2d.tar.gz
Auto merge of #2302 - devnexen:obsd_kinfo_vmentry, r=JohnTitor
openbsd adding kinfo_vmentry
-rw-r--r--libc-test/semver/openbsd.txt1
-rw-r--r--src/unix/bsd/netbsdlike/openbsd/mod.rs17
2 files changed, 18 insertions, 0 deletions
diff --git a/libc-test/semver/openbsd.txt b/libc-test/semver/openbsd.txt
index b76b426f39..240192d92a 100644
--- a/libc-test/semver/openbsd.txt
+++ b/libc-test/semver/openbsd.txt
@@ -962,6 +962,7 @@ iso_args
kevent
key_t
killpg
+kinfo_vmentry
kqueue
labs
lastlog
diff --git a/src/unix/bsd/netbsdlike/openbsd/mod.rs b/src/unix/bsd/netbsdlike/openbsd/mod.rs
index 038048ef17..b22c03785b 100644
--- a/src/unix/bsd/netbsdlike/openbsd/mod.rs
+++ b/src/unix/bsd/netbsdlike/openbsd/mod.rs
@@ -384,6 +384,23 @@ s! {
pub dlpi_phdr: *const Elf_Phdr,
pub dlpi_phnum: Elf_Half,
}
+
+ // sys/sysctl.h
+ pub struct kinfo_vmentry {
+ pub kve_start: ::c_ulong,
+ pub kve_end: ::c_ulong,
+ pub kve_guard: ::c_ulong,
+ pub kve_fspace: ::c_ulong,
+ pub kve_fspace_augment: ::c_ulong,
+ pub kve_offset: u64,
+ pub kve_wired_count: ::c_int,
+ pub kve_etype: ::c_int,
+ pub kve_protection: ::c_int,
+ pub kve_max_protection: ::c_int,
+ pub kve_advice: ::c_int,
+ pub kve_inheritance: ::c_int,
+ pub kve_flags: u8,
+ }
}
impl siginfo_t {