1eba8b6baSopenharmony_ci#![allow(non_camel_case_types, non_upper_case_globals, non_snake_case)]
2eba8b6baSopenharmony_ci#![cfg_attr(not(feature = "std"), no_std)]
3eba8b6baSopenharmony_ci
4eba8b6baSopenharmony_ci#[cfg(feature = "std")]
5eba8b6baSopenharmony_cipub use std::os::raw as ctypes;
6eba8b6baSopenharmony_ci
7eba8b6baSopenharmony_ci#[cfg(all(not(feature = "std"), feature = "no_std"))]
8eba8b6baSopenharmony_cipub mod ctypes {
9eba8b6baSopenharmony_ci    // The signedness of `char` is platform-specific, however a consequence
10eba8b6baSopenharmony_ci    // of it being platform-specific is that any code which depends on the
11eba8b6baSopenharmony_ci    // signedness of `char` is already non-portable. So we can just use `u8`
12eba8b6baSopenharmony_ci    // here and no portable code will notice.
13eba8b6baSopenharmony_ci    pub type c_char = u8;
14eba8b6baSopenharmony_ci
15eba8b6baSopenharmony_ci    // The following assumes that Linux is always either ILP32 or LP64,
16eba8b6baSopenharmony_ci    // and char is always 8-bit.
17eba8b6baSopenharmony_ci    //
18eba8b6baSopenharmony_ci    // In theory, `c_long` and `c_ulong` could be `isize` and `usize`
19eba8b6baSopenharmony_ci    // respectively, however in practice Linux doesn't use them in that way
20eba8b6baSopenharmony_ci    // consistently. So stick with the convention followed by `libc` and
21eba8b6baSopenharmony_ci    // others and use the fixed-width types.
22eba8b6baSopenharmony_ci    pub type c_schar = i8;
23eba8b6baSopenharmony_ci    pub type c_uchar = u8;
24eba8b6baSopenharmony_ci    pub type c_short = i16;
25eba8b6baSopenharmony_ci    pub type c_ushort = u16;
26eba8b6baSopenharmony_ci    pub type c_int = i32;
27eba8b6baSopenharmony_ci    pub type c_uint = u32;
28eba8b6baSopenharmony_ci    #[cfg(target_pointer_width = "32")]
29eba8b6baSopenharmony_ci    pub type c_long = i32;
30eba8b6baSopenharmony_ci    #[cfg(target_pointer_width = "32")]
31eba8b6baSopenharmony_ci    pub type c_ulong = u32;
32eba8b6baSopenharmony_ci    #[cfg(target_pointer_width = "64")]
33eba8b6baSopenharmony_ci    pub type c_long = i64;
34eba8b6baSopenharmony_ci    #[cfg(target_pointer_width = "64")]
35eba8b6baSopenharmony_ci    pub type c_ulong = u64;
36eba8b6baSopenharmony_ci    pub type c_longlong = i64;
37eba8b6baSopenharmony_ci    pub type c_ulonglong = u64;
38eba8b6baSopenharmony_ci    pub type c_float = f32;
39eba8b6baSopenharmony_ci    pub type c_double = f64;
40eba8b6baSopenharmony_ci
41eba8b6baSopenharmony_ci    pub use core::ffi::c_void;
42eba8b6baSopenharmony_ci}
43eba8b6baSopenharmony_ci
44eba8b6baSopenharmony_ci// Confirm that our type definitions above match the actual type definitions.
45eba8b6baSopenharmony_ci#[cfg(test)]
46eba8b6baSopenharmony_cimod assertions {
47eba8b6baSopenharmony_ci    use super::ctypes;
48eba8b6baSopenharmony_ci    static_assertions::assert_eq_size!(ctypes::c_char, libc::c_char);
49eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_schar, libc::c_schar);
50eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_uchar, libc::c_uchar);
51eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_short, libc::c_short);
52eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_ushort, libc::c_ushort);
53eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_int, libc::c_int);
54eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_uint, libc::c_uint);
55eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_long, libc::c_long);
56eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_ulong, libc::c_ulong);
57eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_longlong, libc::c_longlong);
58eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_ulonglong, libc::c_ulonglong);
59eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_float, libc::c_float);
60eba8b6baSopenharmony_ci    static_assertions::assert_type_eq_all!(ctypes::c_double, libc::c_double);
61eba8b6baSopenharmony_ci}
62eba8b6baSopenharmony_ci
63eba8b6baSopenharmony_ci// We don't enable `derive_eq` in bindgen because adding `PartialEq`/`Eq` to
64eba8b6baSopenharmony_ci// *all* structs noticeably increases compile times. But we can add a few
65eba8b6baSopenharmony_ci// manual impls where they're especially useful.
66eba8b6baSopenharmony_ci#[cfg(feature = "general")]
67eba8b6baSopenharmony_ciimpl PartialEq for general::__kernel_timespec {
68eba8b6baSopenharmony_ci    fn eq(&self, other: &Self) -> bool {
69eba8b6baSopenharmony_ci        ({
70eba8b6baSopenharmony_ci            let Self { tv_sec, tv_nsec } = self;
71eba8b6baSopenharmony_ci            (tv_sec, tv_nsec)
72eba8b6baSopenharmony_ci        }) == ({
73eba8b6baSopenharmony_ci            let Self { tv_sec, tv_nsec } = other;
74eba8b6baSopenharmony_ci            (tv_sec, tv_nsec)
75eba8b6baSopenharmony_ci        })
76eba8b6baSopenharmony_ci    }
77eba8b6baSopenharmony_ci}
78eba8b6baSopenharmony_ci#[cfg(feature = "general")]
79eba8b6baSopenharmony_ciimpl Eq for general::__kernel_timespec {}
80eba8b6baSopenharmony_ci
81eba8b6baSopenharmony_ci#[cfg(feature = "general")]
82eba8b6baSopenharmony_cipub mod cmsg_macros {
83eba8b6baSopenharmony_ci    use crate::ctypes::{c_long, c_uint, c_uchar};
84eba8b6baSopenharmony_ci    use crate::general::{cmsghdr, msghdr};
85eba8b6baSopenharmony_ci    use core::mem::size_of;
86eba8b6baSopenharmony_ci    use core::ptr;
87eba8b6baSopenharmony_ci
88eba8b6baSopenharmony_ci    pub unsafe fn CMSG_ALIGN(len: c_uint) -> c_uint {
89eba8b6baSopenharmony_ci        let c_long_size = size_of::<c_long>() as c_uint;
90eba8b6baSopenharmony_ci        (len + c_long_size - 1) & !(c_long_size - 1)
91eba8b6baSopenharmony_ci    }
92eba8b6baSopenharmony_ci
93eba8b6baSopenharmony_ci    pub unsafe fn CMSG_DATA(cmsg: *const cmsghdr) -> *mut c_uchar {
94eba8b6baSopenharmony_ci        (cmsg as *mut c_uchar).offset(size_of::<cmsghdr>() as isize)
95eba8b6baSopenharmony_ci    }
96eba8b6baSopenharmony_ci
97eba8b6baSopenharmony_ci    pub unsafe fn CMSG_SPACE(len: c_uint) -> c_uint {
98eba8b6baSopenharmony_ci        size_of::<cmsghdr>() as c_uint + CMSG_ALIGN(len)
99eba8b6baSopenharmony_ci    }
100eba8b6baSopenharmony_ci
101eba8b6baSopenharmony_ci    pub unsafe fn CMSG_LEN(len: c_uint) -> c_uint {
102eba8b6baSopenharmony_ci        size_of::<cmsghdr>() as c_uint + len
103eba8b6baSopenharmony_ci    }
104eba8b6baSopenharmony_ci
105eba8b6baSopenharmony_ci    pub unsafe fn CMSG_FIRSTHDR(mhdr: *const msghdr) -> *mut cmsghdr {
106eba8b6baSopenharmony_ci        if (*mhdr).msg_controllen < size_of::<cmsghdr>() as _ {
107eba8b6baSopenharmony_ci            return ptr::null_mut();
108eba8b6baSopenharmony_ci        }
109eba8b6baSopenharmony_ci
110eba8b6baSopenharmony_ci        (*mhdr).msg_control as *mut cmsghdr
111eba8b6baSopenharmony_ci    }
112eba8b6baSopenharmony_ci
113eba8b6baSopenharmony_ci    pub unsafe fn CMSG_NXTHDR(mhdr: *const msghdr, cmsg: *const cmsghdr) -> *mut cmsghdr {
114eba8b6baSopenharmony_ci        // We convert from raw pointers to isize here, which may not be sound in a future version of Rust.
115eba8b6baSopenharmony_ci        // Once the provenance rules are set in stone, it will be a good idea to give this function a once-over.
116eba8b6baSopenharmony_ci
117eba8b6baSopenharmony_ci        let cmsg_len = (*cmsg).cmsg_len;
118eba8b6baSopenharmony_ci        let next_cmsg = (cmsg as *mut u8).offset(CMSG_ALIGN(cmsg_len as _) as isize) as *mut cmsghdr;
119eba8b6baSopenharmony_ci        let max = ((*mhdr).msg_control as usize) + ((*mhdr).msg_controllen as usize);
120eba8b6baSopenharmony_ci
121eba8b6baSopenharmony_ci        if cmsg_len < size_of::<cmsghdr>() as _ {
122eba8b6baSopenharmony_ci            return ptr::null_mut();
123eba8b6baSopenharmony_ci        }
124eba8b6baSopenharmony_ci
125eba8b6baSopenharmony_ci        if next_cmsg.offset(1) as usize > max || next_cmsg as usize + CMSG_ALIGN(cmsg_len as _) as usize > max
126eba8b6baSopenharmony_ci        {
127eba8b6baSopenharmony_ci            return ptr::null_mut();
128eba8b6baSopenharmony_ci        }
129eba8b6baSopenharmony_ci
130eba8b6baSopenharmony_ci        next_cmsg
131eba8b6baSopenharmony_ci    }
132eba8b6baSopenharmony_ci}
133eba8b6baSopenharmony_ci
134eba8b6baSopenharmony_ci// The rest of this file is auto-generated!
135eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
136eba8b6baSopenharmony_ci#[cfg(target_arch = "arm")]
137eba8b6baSopenharmony_ci#[path = "arm/errno.rs"]
138eba8b6baSopenharmony_cipub mod errno;
139eba8b6baSopenharmony_ci#[cfg(feature = "general")]
140eba8b6baSopenharmony_ci#[cfg(target_arch = "arm")]
141eba8b6baSopenharmony_ci#[path = "arm/general.rs"]
142eba8b6baSopenharmony_cipub mod general;
143eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
144eba8b6baSopenharmony_ci#[cfg(target_arch = "arm")]
145eba8b6baSopenharmony_ci#[path = "arm/ioctl.rs"]
146eba8b6baSopenharmony_cipub mod ioctl;
147eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
148eba8b6baSopenharmony_ci#[cfg(target_arch = "arm")]
149eba8b6baSopenharmony_ci#[path = "arm/netlink.rs"]
150eba8b6baSopenharmony_cipub mod netlink;
151eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
152eba8b6baSopenharmony_ci#[cfg(target_arch = "aarch64")]
153eba8b6baSopenharmony_ci#[path = "aarch64/errno.rs"]
154eba8b6baSopenharmony_cipub mod errno;
155eba8b6baSopenharmony_ci#[cfg(feature = "general")]
156eba8b6baSopenharmony_ci#[cfg(target_arch = "aarch64")]
157eba8b6baSopenharmony_ci#[path = "aarch64/general.rs"]
158eba8b6baSopenharmony_cipub mod general;
159eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
160eba8b6baSopenharmony_ci#[cfg(target_arch = "aarch64")]
161eba8b6baSopenharmony_ci#[path = "aarch64/ioctl.rs"]
162eba8b6baSopenharmony_cipub mod ioctl;
163eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
164eba8b6baSopenharmony_ci#[cfg(target_arch = "aarch64")]
165eba8b6baSopenharmony_ci#[path = "aarch64/netlink.rs"]
166eba8b6baSopenharmony_cipub mod netlink;
167eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
168eba8b6baSopenharmony_ci#[cfg(target_arch = "mips")]
169eba8b6baSopenharmony_ci#[path = "mips/errno.rs"]
170eba8b6baSopenharmony_cipub mod errno;
171eba8b6baSopenharmony_ci#[cfg(feature = "general")]
172eba8b6baSopenharmony_ci#[cfg(target_arch = "mips")]
173eba8b6baSopenharmony_ci#[path = "mips/general.rs"]
174eba8b6baSopenharmony_cipub mod general;
175eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
176eba8b6baSopenharmony_ci#[cfg(target_arch = "mips")]
177eba8b6baSopenharmony_ci#[path = "mips/ioctl.rs"]
178eba8b6baSopenharmony_cipub mod ioctl;
179eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
180eba8b6baSopenharmony_ci#[cfg(target_arch = "mips")]
181eba8b6baSopenharmony_ci#[path = "mips/netlink.rs"]
182eba8b6baSopenharmony_cipub mod netlink;
183eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
184eba8b6baSopenharmony_ci#[cfg(target_arch = "mips64")]
185eba8b6baSopenharmony_ci#[path = "mips64/errno.rs"]
186eba8b6baSopenharmony_cipub mod errno;
187eba8b6baSopenharmony_ci#[cfg(feature = "general")]
188eba8b6baSopenharmony_ci#[cfg(target_arch = "mips64")]
189eba8b6baSopenharmony_ci#[path = "mips64/general.rs"]
190eba8b6baSopenharmony_cipub mod general;
191eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
192eba8b6baSopenharmony_ci#[cfg(target_arch = "mips64")]
193eba8b6baSopenharmony_ci#[path = "mips64/ioctl.rs"]
194eba8b6baSopenharmony_cipub mod ioctl;
195eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
196eba8b6baSopenharmony_ci#[cfg(target_arch = "mips64")]
197eba8b6baSopenharmony_ci#[path = "mips64/netlink.rs"]
198eba8b6baSopenharmony_cipub mod netlink;
199eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
200eba8b6baSopenharmony_ci#[cfg(target_arch = "powerpc")]
201eba8b6baSopenharmony_ci#[path = "powerpc/errno.rs"]
202eba8b6baSopenharmony_cipub mod errno;
203eba8b6baSopenharmony_ci#[cfg(feature = "general")]
204eba8b6baSopenharmony_ci#[cfg(target_arch = "powerpc")]
205eba8b6baSopenharmony_ci#[path = "powerpc/general.rs"]
206eba8b6baSopenharmony_cipub mod general;
207eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
208eba8b6baSopenharmony_ci#[cfg(target_arch = "powerpc")]
209eba8b6baSopenharmony_ci#[path = "powerpc/ioctl.rs"]
210eba8b6baSopenharmony_cipub mod ioctl;
211eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
212eba8b6baSopenharmony_ci#[cfg(target_arch = "powerpc")]
213eba8b6baSopenharmony_ci#[path = "powerpc/netlink.rs"]
214eba8b6baSopenharmony_cipub mod netlink;
215eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
216eba8b6baSopenharmony_ci#[cfg(target_arch = "powerpc64")]
217eba8b6baSopenharmony_ci#[path = "powerpc64/errno.rs"]
218eba8b6baSopenharmony_cipub mod errno;
219eba8b6baSopenharmony_ci#[cfg(feature = "general")]
220eba8b6baSopenharmony_ci#[cfg(target_arch = "powerpc64")]
221eba8b6baSopenharmony_ci#[path = "powerpc64/general.rs"]
222eba8b6baSopenharmony_cipub mod general;
223eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
224eba8b6baSopenharmony_ci#[cfg(target_arch = "powerpc64")]
225eba8b6baSopenharmony_ci#[path = "powerpc64/ioctl.rs"]
226eba8b6baSopenharmony_cipub mod ioctl;
227eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
228eba8b6baSopenharmony_ci#[cfg(target_arch = "powerpc64")]
229eba8b6baSopenharmony_ci#[path = "powerpc64/netlink.rs"]
230eba8b6baSopenharmony_cipub mod netlink;
231eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
232eba8b6baSopenharmony_ci#[cfg(target_arch = "riscv32")]
233eba8b6baSopenharmony_ci#[path = "riscv32/errno.rs"]
234eba8b6baSopenharmony_cipub mod errno;
235eba8b6baSopenharmony_ci#[cfg(feature = "general")]
236eba8b6baSopenharmony_ci#[cfg(target_arch = "riscv32")]
237eba8b6baSopenharmony_ci#[path = "riscv32/general.rs"]
238eba8b6baSopenharmony_cipub mod general;
239eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
240eba8b6baSopenharmony_ci#[cfg(target_arch = "riscv32")]
241eba8b6baSopenharmony_ci#[path = "riscv32/ioctl.rs"]
242eba8b6baSopenharmony_cipub mod ioctl;
243eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
244eba8b6baSopenharmony_ci#[cfg(target_arch = "riscv32")]
245eba8b6baSopenharmony_ci#[path = "riscv32/netlink.rs"]
246eba8b6baSopenharmony_cipub mod netlink;
247eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
248eba8b6baSopenharmony_ci#[cfg(target_arch = "riscv64")]
249eba8b6baSopenharmony_ci#[path = "riscv64/errno.rs"]
250eba8b6baSopenharmony_cipub mod errno;
251eba8b6baSopenharmony_ci#[cfg(feature = "general")]
252eba8b6baSopenharmony_ci#[cfg(target_arch = "riscv64")]
253eba8b6baSopenharmony_ci#[path = "riscv64/general.rs"]
254eba8b6baSopenharmony_cipub mod general;
255eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
256eba8b6baSopenharmony_ci#[cfg(target_arch = "riscv64")]
257eba8b6baSopenharmony_ci#[path = "riscv64/ioctl.rs"]
258eba8b6baSopenharmony_cipub mod ioctl;
259eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
260eba8b6baSopenharmony_ci#[cfg(target_arch = "riscv64")]
261eba8b6baSopenharmony_ci#[path = "riscv64/netlink.rs"]
262eba8b6baSopenharmony_cipub mod netlink;
263eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
264eba8b6baSopenharmony_ci#[cfg(target_arch = "s390x")]
265eba8b6baSopenharmony_ci#[path = "s390x/errno.rs"]
266eba8b6baSopenharmony_cipub mod errno;
267eba8b6baSopenharmony_ci#[cfg(feature = "general")]
268eba8b6baSopenharmony_ci#[cfg(target_arch = "s390x")]
269eba8b6baSopenharmony_ci#[path = "s390x/general.rs"]
270eba8b6baSopenharmony_cipub mod general;
271eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
272eba8b6baSopenharmony_ci#[cfg(target_arch = "s390x")]
273eba8b6baSopenharmony_ci#[path = "s390x/ioctl.rs"]
274eba8b6baSopenharmony_cipub mod ioctl;
275eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
276eba8b6baSopenharmony_ci#[cfg(target_arch = "s390x")]
277eba8b6baSopenharmony_ci#[path = "s390x/netlink.rs"]
278eba8b6baSopenharmony_cipub mod netlink;
279eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
280eba8b6baSopenharmony_ci#[cfg(target_arch = "sparc")]
281eba8b6baSopenharmony_ci#[path = "sparc/errno.rs"]
282eba8b6baSopenharmony_cipub mod errno;
283eba8b6baSopenharmony_ci#[cfg(feature = "general")]
284eba8b6baSopenharmony_ci#[cfg(target_arch = "sparc")]
285eba8b6baSopenharmony_ci#[path = "sparc/general.rs"]
286eba8b6baSopenharmony_cipub mod general;
287eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
288eba8b6baSopenharmony_ci#[cfg(target_arch = "sparc")]
289eba8b6baSopenharmony_ci#[path = "sparc/ioctl.rs"]
290eba8b6baSopenharmony_cipub mod ioctl;
291eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
292eba8b6baSopenharmony_ci#[cfg(target_arch = "sparc")]
293eba8b6baSopenharmony_ci#[path = "sparc/netlink.rs"]
294eba8b6baSopenharmony_cipub mod netlink;
295eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
296eba8b6baSopenharmony_ci#[cfg(target_arch = "sparc64")]
297eba8b6baSopenharmony_ci#[path = "sparc64/errno.rs"]
298eba8b6baSopenharmony_cipub mod errno;
299eba8b6baSopenharmony_ci#[cfg(feature = "general")]
300eba8b6baSopenharmony_ci#[cfg(target_arch = "sparc64")]
301eba8b6baSopenharmony_ci#[path = "sparc64/general.rs"]
302eba8b6baSopenharmony_cipub mod general;
303eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
304eba8b6baSopenharmony_ci#[cfg(target_arch = "sparc64")]
305eba8b6baSopenharmony_ci#[path = "sparc64/ioctl.rs"]
306eba8b6baSopenharmony_cipub mod ioctl;
307eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
308eba8b6baSopenharmony_ci#[cfg(target_arch = "sparc64")]
309eba8b6baSopenharmony_ci#[path = "sparc64/netlink.rs"]
310eba8b6baSopenharmony_cipub mod netlink;
311eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
312eba8b6baSopenharmony_ci#[cfg(target_arch = "x86")]
313eba8b6baSopenharmony_ci#[path = "x86/errno.rs"]
314eba8b6baSopenharmony_cipub mod errno;
315eba8b6baSopenharmony_ci#[cfg(feature = "general")]
316eba8b6baSopenharmony_ci#[cfg(target_arch = "x86")]
317eba8b6baSopenharmony_ci#[path = "x86/general.rs"]
318eba8b6baSopenharmony_cipub mod general;
319eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
320eba8b6baSopenharmony_ci#[cfg(target_arch = "x86")]
321eba8b6baSopenharmony_ci#[path = "x86/ioctl.rs"]
322eba8b6baSopenharmony_cipub mod ioctl;
323eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
324eba8b6baSopenharmony_ci#[cfg(target_arch = "x86")]
325eba8b6baSopenharmony_ci#[path = "x86/netlink.rs"]
326eba8b6baSopenharmony_cipub mod netlink;
327eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
328eba8b6baSopenharmony_ci#[cfg(all(target_arch = "x86_64", target_pointer_width = "64"))]
329eba8b6baSopenharmony_ci#[path = "x86_64/errno.rs"]
330eba8b6baSopenharmony_cipub mod errno;
331eba8b6baSopenharmony_ci#[cfg(feature = "general")]
332eba8b6baSopenharmony_ci#[cfg(all(target_arch = "x86_64", target_pointer_width = "64"))]
333eba8b6baSopenharmony_ci#[path = "x86_64/general.rs"]
334eba8b6baSopenharmony_cipub mod general;
335eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
336eba8b6baSopenharmony_ci#[cfg(all(target_arch = "x86_64", target_pointer_width = "64"))]
337eba8b6baSopenharmony_ci#[path = "x86_64/ioctl.rs"]
338eba8b6baSopenharmony_cipub mod ioctl;
339eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
340eba8b6baSopenharmony_ci#[cfg(all(target_arch = "x86_64", target_pointer_width = "64"))]
341eba8b6baSopenharmony_ci#[path = "x86_64/netlink.rs"]
342eba8b6baSopenharmony_cipub mod netlink;
343eba8b6baSopenharmony_ci#[cfg(feature = "errno")]
344eba8b6baSopenharmony_ci#[cfg(all(target_arch = "x86_64", target_pointer_width = "32"))]
345eba8b6baSopenharmony_ci#[path = "x32/errno.rs"]
346eba8b6baSopenharmony_cipub mod errno;
347eba8b6baSopenharmony_ci#[cfg(feature = "general")]
348eba8b6baSopenharmony_ci#[cfg(all(target_arch = "x86_64", target_pointer_width = "32"))]
349eba8b6baSopenharmony_ci#[path = "x32/general.rs"]
350eba8b6baSopenharmony_cipub mod general;
351eba8b6baSopenharmony_ci#[cfg(feature = "ioctl")]
352eba8b6baSopenharmony_ci#[cfg(all(target_arch = "x86_64", target_pointer_width = "32"))]
353eba8b6baSopenharmony_ci#[path = "x32/ioctl.rs"]
354eba8b6baSopenharmony_cipub mod ioctl;
355eba8b6baSopenharmony_ci#[cfg(feature = "netlink")]
356eba8b6baSopenharmony_ci#[cfg(all(target_arch = "x86_64", target_pointer_width = "32"))]
357eba8b6baSopenharmony_ci#[path = "x32/netlink.rs"]
358eba8b6baSopenharmony_cipub mod netlink;
359