Skip to content

Commit 966fde1

Browse files
authored
Add IORING_MSG_RING_FLAGS_PASS. (#1034)
And, implement `Default` for `io_uring_sync_cancel_reg`.
1 parent 4c3335c commit 966fde1

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

src/io_uring.rs

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -632,6 +632,9 @@ bitflags::bitflags! {
632632
/// `IORING_MSG_RING_CQE_SKIP`
633633
const CQE_SKIP = sys::IORING_MSG_RING_CQE_SKIP;
634634

635+
/// `IORING_MSG_RING_FLAGS_PASS`
636+
const FLAGS_PASS = sys::IORING_MSG_RING_FLAGS_PASS;
637+
635638
/// <https://docs.rs/bitflags/*/bitflags/#externally-defined-flags>
636639
const _ = !0;
637640
}
@@ -1159,6 +1162,22 @@ pub struct io_uring_sync_cancel_reg {
11591162
pub pad: [u64; 4],
11601163
}
11611164

1165+
impl Default for io_uring_sync_cancel_reg {
1166+
#[inline]
1167+
fn default() -> Self {
1168+
Self {
1169+
addr: Default::default(),
1170+
fd: Default::default(),
1171+
flags: Default::default(),
1172+
timeout: Timespec {
1173+
tv_sec: 0,
1174+
tv_nsec: 0,
1175+
},
1176+
pad: Default::default(),
1177+
}
1178+
}
1179+
}
1180+
11621181
/// An io_uring Completion Queue Entry.
11631182
///
11641183
/// This does not derive `Copy` or `Clone` because the `big_cqe` field is not

0 commit comments

Comments
 (0)