Skip to content

Commit

Permalink
musl: Reorganize some statfs-related types for a cleaner diff
Browse files Browse the repository at this point in the history
This moves similar types together (e.g. statfs and statfs64) so removing
them is cleaner.

Co-authored-by: Andy Caldwell <andycaldwell@microsoft.com>
  • Loading branch information
tgross35 and bossmc committed Nov 25, 2024
1 parent ca3a399 commit 6c0952e
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 34 deletions.
8 changes: 4 additions & 4 deletions src/unix/linux_like/linux/musl/b32/x86/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ s! {
pub st_ino: ::ino_t,
}

pub struct mcontext_t {
__private: [u32; 22],
}

pub struct stack_t {
pub ss_sp: *mut ::c_void,
pub ss_flags: ::c_int,
Expand Down Expand Up @@ -112,10 +116,6 @@ s! {
pub f_spare: [::c_ulong; 4],
}

pub struct mcontext_t {
__private: [u32; 22],
}

pub struct siginfo_t {
pub si_signo: ::c_int,
pub si_errno: ::c_int,
Expand Down
60 changes: 30 additions & 30 deletions src/unix/linux_like/linux/musl/b64/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,36 +3,6 @@ pub type c_ulong = u64;
pub type regoff_t = ::c_long;

s! {
pub struct statfs64 {
pub f_type: ::c_ulong,
pub f_bsize: ::c_ulong,
pub f_blocks: ::fsblkcnt_t,
pub f_bfree: ::fsblkcnt_t,
pub f_bavail: ::fsblkcnt_t,
pub f_files: ::fsfilcnt_t,
pub f_ffree: ::fsfilcnt_t,
pub f_fsid: ::fsid_t,
pub f_namelen: ::c_ulong,
pub f_frsize: ::c_ulong,
pub f_flags: ::c_ulong,
pub f_spare: [::c_ulong; 4],
}

pub struct statvfs64 {
pub f_bsize: ::c_ulong,
pub f_frsize: ::c_ulong,
pub f_blocks: u64,
pub f_bfree: u64,
pub f_bavail: u64,
pub f_files: u64,
pub f_ffree: u64,
pub f_favail: u64,
pub f_fsid: ::c_ulong,
pub f_flag: ::c_ulong,
pub f_namemax: ::c_ulong,
__f_spare: [::c_int; 6],
}

pub struct stack_t {
pub ss_sp: *mut ::c_void,
pub ss_flags: ::c_int,
Expand Down Expand Up @@ -89,6 +59,36 @@ s! {
pub f_spare: [::c_ulong; 4],
}

pub struct statfs64 {
pub f_type: ::c_ulong,
pub f_bsize: ::c_ulong,
pub f_blocks: ::fsblkcnt_t,
pub f_bfree: ::fsblkcnt_t,
pub f_bavail: ::fsblkcnt_t,
pub f_files: ::fsfilcnt_t,
pub f_ffree: ::fsfilcnt_t,
pub f_fsid: ::fsid_t,
pub f_namelen: ::c_ulong,
pub f_frsize: ::c_ulong,
pub f_flags: ::c_ulong,
pub f_spare: [::c_ulong; 4],
}

pub struct statvfs64 {
pub f_bsize: ::c_ulong,
pub f_frsize: ::c_ulong,
pub f_blocks: u64,
pub f_bfree: u64,
pub f_bavail: u64,
pub f_files: u64,
pub f_ffree: u64,
pub f_favail: u64,
pub f_fsid: ::c_ulong,
pub f_flag: ::c_ulong,
pub f_namemax: ::c_ulong,
__f_spare: [::c_int; 6],
}

pub struct msghdr {
pub msg_name: *mut ::c_void,
pub msg_namelen: ::socklen_t,
Expand Down

0 comments on commit 6c0952e

Please sign in to comment.