Skip to content

Commit

Permalink
Auto merge of rust-lang#2798 - devnexen:dfbsd_kvm_update2, r=Amanieu
Browse files Browse the repository at this point in the history
dragonflybsd adding vmspace data.
  • Loading branch information
bors committed May 24, 2022
2 parents 474d87e + 72b64be commit 13afe8a
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
1 change: 1 addition & 0 deletions libc-test/semver/dragonfly.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1524,6 +1524,7 @@ uuid
uuid_t
vm_map_entry_t
vm_size_t
vmspace
wait4
waitid
xucred
31 changes: 31 additions & 0 deletions src/unix/bsd/freebsdlike/dragonfly/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ pub type vm_eflags_t = ::c_uint;
pub type vm_map_t = *mut __c_anonymous_vm_map;
pub type vm_map_entry_t = *mut vm_map_entry;

pub type pmap = __c_anonymous_pmap;

#[cfg_attr(feature = "extra_traits", derive(Debug))]
pub enum sem {}
impl ::Copy for sem {}
Expand Down Expand Up @@ -360,6 +362,35 @@ s! {
pub id: ::vm_subsys_t,
}

pub struct __c_anonymous_pmap {
_priv1: [::uintptr_t; 32],
_priv2: [::uintptr_t; 32],
_priv3: [::uintptr_t; 32],
_priv4: [::uintptr_t; 32],
_priv5: [::uintptr_t; 8],
}

pub struct vmspace {
vm_map: __c_anonymous_vm_map,
vm_pmap: __c_anonymous_pmap,
pub vm_flags: ::c_int,
pub vm_shm: *mut ::c_char,
pub vm_rssize: ::segsz_t,
pub vm_swrss: ::segsz_t,
pub vm_tsize: ::segsz_t,
pub vm_dsize: ::segsz_t,
pub vm_ssize: ::segsz_t,
pub vm_taddr: *mut ::c_char,
pub vm_daddr: *mut ::c_char,
pub vm_maxsaddr: *mut ::c_char,
pub vm_minsaddr: *mut ::c_char,
_unused1: ::c_int,
_unused2: ::c_int,
pub vm_pagesupply: ::c_int,
pub vm_holdcnt: ::c_uint,
pub vm_refcnt: ::c_uint,
}

pub struct cpuctl_msr_args_t {
pub msr: ::c_int,
pub data: u64,
Expand Down

0 comments on commit 13afe8a

Please sign in to comment.