| //! Header: `uapi/linux/pidfd.h` | ||
| use crate::prelude::*; | ||
| use crate::{ | ||
| Ioctl, | ||
| _IO, | ||
| _IOWR, | ||
| }; | ||
| /* Flags for pidfd_open(). */ | ||
| pub const PIDFD_NONBLOCK: c_uint = crate::O_NONBLOCK as c_uint; | ||
| pub const PIDFD_THREAD: c_uint = crate::O_EXCL as c_uint; | ||
| /* Flags for pidfd_send_signal(). */ | ||
| pub const PIDFD_SIGNAL_THREAD: c_uint = 1 << 0; | ||
| pub const PIDFD_SIGNAL_THREAD_GROUP: c_uint = 1 << 1; | ||
| pub const PIDFD_SIGNAL_PROCESS_GROUP: c_uint = 1 << 2; | ||
| /* Flags for pidfd_info. */ | ||
| pub const PIDFD_INFO_PID: c_uint = 1 << 0; | ||
| pub const PIDFD_INFO_CREDS: c_uint = 1 << 1; | ||
| pub const PIDFD_INFO_CGROUPID: c_uint = 1 << 2; | ||
| pub const PIDFD_INFO_EXIT: c_uint = 1 << 3; | ||
| pub const PIDFD_INFO_SIZE_VER0: c_uint = 64; | ||
| s! { | ||
| #[non_exhaustive] | ||
| pub struct pidfd_info { | ||
| pub mask: crate::__u64, | ||
| pub cgroupid: crate::__u64, | ||
| pub pid: crate::__u32, | ||
| pub tgid: crate::__u32, | ||
| pub ppid: crate::__u32, | ||
| pub ruid: crate::__u32, | ||
| pub rgid: crate::__u32, | ||
| pub euid: crate::__u32, | ||
| pub egid: crate::__u32, | ||
| pub suid: crate::__u32, | ||
| pub sgid: crate::__u32, | ||
| pub fsuid: crate::__u32, | ||
| pub fsgid: crate::__u32, | ||
| pub exit_code: crate::__s32, | ||
| } | ||
| } | ||
| const PIDFS_IOCTL_MAGIC: c_uint = 0xFF; | ||
| pub const PIDFD_GET_CGROUP_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 1); | ||
| pub const PIDFD_GET_IPC_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 2); | ||
| pub const PIDFD_GET_MNT_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 3); | ||
| pub const PIDFD_GET_NET_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 4); | ||
| pub const PIDFD_GET_PID_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 5); | ||
| pub const PIDFD_GET_PID_FOR_CHILDREN_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 6); | ||
| pub const PIDFD_GET_TIME_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 7); | ||
| pub const PIDFD_GET_TIME_FOR_CHILDREN_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 8); | ||
| pub const PIDFD_GET_USER_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 9); | ||
| pub const PIDFD_GET_UTS_NAMESPACE: Ioctl = _IO(PIDFS_IOCTL_MAGIC, 10); | ||
| pub const PIDFD_GET_INFO: Ioctl = _IOWR::<pidfd_info>(PIDFS_IOCTL_MAGIC, 11); |
| //! Header: `sys/file.h` | ||
| //! | ||
| //! <https://github.com/NetBSD/src/blob/trunk/sys/sys/file.h> | ||
| use crate::prelude::*; | ||
| pub const DTYPE_VNODE: c_int = 1; | ||
| pub const DTYPE_SOCKET: c_int = 2; | ||
| pub const DTYPE_PIPE: c_int = 3; | ||
| pub const DTYPE_KQUEUE: c_int = 4; | ||
| pub const DTYPE_MISC: c_int = 5; | ||
| pub const DTYPE_CRYPTO: c_int = 6; | ||
| pub const DTYPE_MQUEUE: c_int = 7; | ||
| pub const DTYPE_SEM: c_int = 8; | ||
| pub const DTYPE_EVENTFD: c_int = 9; | ||
| pub const DTYPE_TIMERFD: c_int = 10; |
| //! Header: `sys/socket.h` | ||
| //! | ||
| //! <https://github.com/NetBSD/src/blob/trunk/sys/sys/socket.h> | ||
| //! | ||
| use crate::prelude::*; | ||
| s_no_extra_traits! { | ||
| pub union __c_anonymous_pcb_sockaddr_src { | ||
| pub _kis_src: crate::sockaddr, | ||
| _kis_pad: Padding<[c_char; 256 + 8]>, | ||
| } | ||
| pub union __c_anonymous_pcb_sockaddr_dst { | ||
| pub _kid_dst: crate::sockaddr, | ||
| _kid_pad: Padding<[c_char; 256 + 8]>, | ||
| } | ||
| pub struct kinfo_pcb { | ||
| pub ki_pcbaddr: u64, | ||
| pub ki_ppcbaddr: u64, | ||
| pub ki_sockaddr: u64, | ||
| pub ki_family: u32, | ||
| pub ki_type: u32, | ||
| pub ki_protocol: u32, | ||
| pub ki_pflags: u32, | ||
| pub ki_sostate: u32, | ||
| pub ki_prstate: u32, | ||
| pub ki_tstate: i32, | ||
| pub ki_tflags: u32, | ||
| pub ki_rcvq: u64, | ||
| pub ki_sndq: u64, | ||
| pub ki_s: __c_anonymous_pcb_sockaddr_src, | ||
| pub ki_d: __c_anonymous_pcb_sockaddr_dst, | ||
| pub ki_inode: u64, | ||
| pub ki_vnode: u64, | ||
| pub ki_conn: u64, | ||
| pub ki_refs: u64, | ||
| pub ki_nextref: u64, | ||
| } | ||
| } | ||
| pub const PCB_SLOP: c_int = 20; | ||
| pub const PCB_ALL: c_int = 0; |
| { | ||
| "git": { | ||
| "sha1": "e879ee90b6cd8f79b352d4d4d1f8ca05f94f2f53" | ||
| "sha1": "5660e6fc058d1c6c27788e3ea2bc7d3e79d3c22d" | ||
| }, | ||
| "path_in_vcs": "" | ||
| } |
+3
-3
@@ -55,3 +55,3 @@ use std::env::VarError; | ||
| /// Musl architectures that set `#define _REDIR_TIME64 1`. | ||
| const MUSL_REDIR_TIME64_ARCHES: &[&str] = &["arm", "mips", "powerpc", "x86"]; | ||
| const MUSL_REDIR_TIME64_ARCHES: &[&str] = &["arm", "hexagon", "mips", "powerpc", "x86"]; | ||
@@ -114,4 +114,4 @@ fn main() { | ||
| // loongarch64 and ohos only exist with recent musl | ||
| if target_arch == "loongarch64" || target_env == "ohos" { | ||
| // loongarch64, hexagon, and ohos only exist with recent musl | ||
| if target_arch == "loongarch64" || target_arch == "hexagon" || target_env == "ohos" { | ||
| musl_v1_2_3 = true; | ||
@@ -118,0 +118,0 @@ } |
+1
-1
@@ -7,3 +7,3 @@ # This file is automatically @generated by Cargo. | ||
| name = "libc" | ||
| version = "0.2.182" | ||
| version = "0.2.183" | ||
| dependencies = [ | ||
@@ -10,0 +10,0 @@ "rustc-std-workspace-core", |
+1
-1
@@ -16,3 +16,3 @@ # THIS FILE IS AUTOMATICALLY GENERATED BY CARGO | ||
| name = "libc" | ||
| version = "0.2.182" | ||
| version = "0.2.183" | ||
| authors = ["The Rust Project Developers"] | ||
@@ -19,0 +19,0 @@ build = "build.rs" |
+1
-0
@@ -111,2 +111,3 @@ //! Hermit C type definitions | ||
| #[derive(Default)] | ||
| pub struct timespec { | ||
@@ -113,0 +114,0 @@ pub tv_sec: time_t, |
+1
-0
@@ -30,2 +30,3 @@ //! libc - Raw FFI bindings to platforms' system libraries | ||
| #![cfg_attr(feature = "rustc-dep-of-std", allow(internal_features))] | ||
| #![cfg_attr(feature = "rustc-dep-of-std", allow(unused_features))] | ||
| // DIFF(1.0): The thread local references that raise this lint were removed in 1.0 | ||
@@ -32,0 +33,0 @@ #![cfg_attr(feature = "rustc-dep-of-std", allow(static_mut_refs))] |
@@ -9,1 +9,2 @@ //! Directory: `linux/` | ||
| pub(crate) mod netlink; | ||
| pub(crate) mod pidfd; |
+3
-0
@@ -187,2 +187,3 @@ //! This module contains the future directory structure. If possible, new definitions should | ||
| pub use linux::netlink::*; | ||
| pub use linux::pidfd::*; | ||
| #[cfg(target_env = "gnu")] | ||
@@ -199,3 +200,5 @@ pub use net::route::*; | ||
| pub use net::if_::*; | ||
| pub use sys::file::*; | ||
| pub use sys::ipc::*; | ||
| pub use sys::socket::*; | ||
| pub use sys::statvfs::*; | ||
@@ -202,0 +205,0 @@ pub use sys::time::*; |
@@ -5,3 +5,5 @@ //! Directory: `sys/` | ||
| pub(crate) mod file; | ||
| pub(crate) mod ipc; | ||
| pub(crate) mod socket; | ||
| pub(crate) mod statvfs; | ||
@@ -8,0 +10,0 @@ pub(crate) mod time; |
@@ -140,2 +140,3 @@ //! QuRT (Qualcomm Real-Time OS) bindings | ||
| #[derive(Default)] | ||
| pub struct timespec { | ||
@@ -146,2 +147,3 @@ pub tv_sec: time_t, | ||
| #[derive(Default)] | ||
| pub struct timeval { | ||
@@ -148,0 +150,0 @@ pub tv_sec: time_t, |
+1
-0
@@ -172,2 +172,3 @@ //! Interface to the [SOLID] C library | ||
| #[derive(Default)] | ||
| pub struct timeval { | ||
@@ -174,0 +175,0 @@ pub tv_sec: c_long, |
+1
-0
| //! Switch C type definitions | ||
| use crate::prelude::*; | ||
@@ -3,0 +4,0 @@ pub type intmax_t = i64; |
+2
-0
@@ -102,2 +102,3 @@ //! Libc bindings for teeos | ||
| #[derive(Default)] | ||
| pub struct timespec { | ||
@@ -108,2 +109,3 @@ pub tv_sec: time_t, | ||
| #[derive(Default)] | ||
| pub struct timeval { | ||
@@ -110,0 +112,0 @@ pub tv_sec: time_t, |
+1
-0
@@ -30,2 +30,3 @@ use crate::prelude::*; | ||
| #[derive(Default)] | ||
| pub struct timespec { | ||
@@ -32,0 +33,0 @@ pub tv_sec: time_t, |
@@ -6,2 +6,3 @@ //! 64-bit specific Apple (ios/darwin) definitions | ||
| s! { | ||
| #[derive(Default)] | ||
| pub struct timeval32 { | ||
@@ -8,0 +9,0 @@ pub tv_sec: i32, |
@@ -322,2 +322,3 @@ use crate::off64_t; | ||
| // See https://sourceware.org/bugzilla/show_bug.cgi?id=16437 | ||
| #[derive(Default)] | ||
| pub struct timespec { | ||
@@ -324,0 +325,0 @@ pub tv_sec: time_t, |
@@ -100,2 +100,4 @@ use crate::prelude::*; | ||
| pub const SOMAXCONN: c_int = 128; | ||
| extern "C" { | ||
@@ -102,0 +104,0 @@ pub fn pthread_create( |
@@ -5,3 +5,3 @@ use crate::prelude::*; | ||
| pub type blkcnt_t = c_ulong; | ||
| pub type blkcnt_t = c_longlong; | ||
| pub type blksize_t = c_long; | ||
@@ -157,3 +157,3 @@ pub type clock_t = c_long; | ||
| pub sa_sigaction: crate::sighandler_t, | ||
| pub sa_flags: c_ulong, | ||
| pub sa_flags: c_int, | ||
| pub sa_restorer: Option<extern "C" fn()>, | ||
@@ -160,0 +160,0 @@ pub sa_mask: crate::sigset_t, |
+2
-0
@@ -90,2 +90,3 @@ //! [wasi-libc](https://github.com/WebAssembly/wasi-libc) definitions. | ||
| #[derive(Default)] | ||
| pub struct timeval { | ||
@@ -96,2 +97,3 @@ pub tv_sec: time_t, | ||
| #[derive(Default)] | ||
| pub struct timespec { | ||
@@ -98,0 +100,0 @@ pub tv_sec: time_t, |
@@ -75,2 +75,3 @@ //! Windows CRT definitions | ||
| #[derive(Default)] | ||
| pub struct timeval { | ||
@@ -81,2 +82,3 @@ pub tv_sec: c_long, | ||
| #[derive(Default)] | ||
| pub struct timespec { | ||
@@ -83,0 +85,0 @@ pub tv_sec: time_t, |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display