Skip to content

Commit

Permalink
Merge pull request #1121 from smibarber/signalfd-sigsys
Browse files Browse the repository at this point in the history
Add support for SIGSYS in signalfd
  • Loading branch information
gnzlbg authored Nov 10, 2018
2 parents 9c5e70a + 2475278 commit 5d3025b
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 6 deletions.
8 changes: 7 additions & 1 deletion libc-test/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -841,7 +841,13 @@ fn main() {
// musl seems to define this as an *anonymous* bitfield
(musl && struct_ == "statvfs" && field == "__f_unused") ||
// sigev_notify_thread_id is actually part of a sigev_un union
(struct_ == "sigevent" && field == "sigev_notify_thread_id")
(struct_ == "sigevent" && field == "sigev_notify_thread_id") ||
// signalfd had SIGSYS fields added in Linux 4.18, but no libc release has them yet.
(struct_ == "signalfd_siginfo" && (field == "ssi_addr_lsb" ||
field == "_pad2" ||
field == "ssi_syscall" ||
field == "ssi_call_addr" ||
field == "ssi_arch"))
});

cfg.fn_cname(move |name, cname| {
Expand Down
7 changes: 6 additions & 1 deletion src/fuchsia/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -685,7 +685,12 @@ s! {
pub ssi_utime: ::uint64_t,
pub ssi_stime: ::uint64_t,
pub ssi_addr: ::uint64_t,
_pad: [::uint8_t; 48],
pub ssi_addr_lsb: ::uint16_t,
_pad2: ::uint16_t,
pub ssi_syscall: ::int32_t,
pub ssi_call_addr: ::uint64_t,
pub ssi_arch: ::uint32_t,
_pad: [::uint8_t; 28],
}

pub struct itimerspec {
Expand Down
6 changes: 5 additions & 1 deletion src/unix/notbsd/android/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,11 @@ s! {
pub ssi_stime: ::c_ulonglong,
pub ssi_addr: ::c_ulonglong,
pub ssi_addr_lsb: ::uint16_t,
_pad: [::uint8_t; 46],
_pad2: ::uint16_t,
pub ssi_syscall: ::int32_t,
pub ssi_call_addr: ::uint64_t,
pub ssi_arch: ::uint32_t,
_pad: [::uint8_t; 28],
}

pub struct ucred {
Expand Down
7 changes: 6 additions & 1 deletion src/unix/notbsd/emscripten.rs
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,12 @@ s! {
pub ssi_utime: ::uint64_t,
pub ssi_stime: ::uint64_t,
pub ssi_addr: ::uint64_t,
_pad: [::uint8_t; 48],
pub ssi_addr_lsb: ::uint16_t,
_pad2: ::uint16_t,
pub ssi_syscall: ::int32_t,
pub ssi_call_addr: ::uint64_t,
pub ssi_arch: ::uint32_t,
_pad: [::uint8_t; 28],
}

pub struct fsid_t {
Expand Down
7 changes: 6 additions & 1 deletion src/unix/notbsd/linux/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,12 @@ s! {
pub ssi_utime: ::uint64_t,
pub ssi_stime: ::uint64_t,
pub ssi_addr: ::uint64_t,
_pad: [::uint8_t; 48],
pub ssi_addr_lsb: ::uint16_t,
_pad2: ::uint16_t,
pub ssi_syscall: ::int32_t,
pub ssi_call_addr: ::uint64_t,
pub ssi_arch: ::uint32_t,
_pad: [::uint8_t; 28],
}

pub struct itimerspec {
Expand Down
7 changes: 6 additions & 1 deletion src/unix/uclibc/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,12 @@ s! {
pub ssi_utime: ::uint64_t,
pub ssi_stime: ::uint64_t,
pub ssi_addr: ::uint64_t,
_pad: [::uint8_t; 48],
pub ssi_addr_lsb: ::uint16_t,
_pad2: ::uint16_t,
pub ssi_syscall: ::int32_t,
pub ssi_call_addr: ::uint64_t,
pub ssi_arch: ::uint32_t,
_pad: [::uint8_t; 28],
}

pub struct fsid_t {
Expand Down

0 comments on commit 5d3025b

Please sign in to comment.