authorgravatar for halildrk@gmail.comnikneym <halildrk@gmail.com> 2025-02-11 13:18:27+03:00
committergravatar for halildrk@gmail.comnikneym <halildrk@gmail.com> 2025-02-11 13:18:27+03:00
log6f6b85e29827ad269ab397a3db14e9574204cb2d
treec1140f8b50dd3f32abb60bfe9873623bf9afe3f2
parentecfd9cef7d892cddf2a65a64a2906a881bab12fb

linux/io_uring_sqe: add prep_files_update


1 files changed, 15 insertions(+), 0 deletions(-)

lib/std/os/linux/io_uring_sqe.zig+15
......@@ -525,6 +525,21 @@ pub const io_uring_sqe = extern struct {
525525 sqe.rw_flags = flags;
526526 }
527527
528 pub fn prep_files_update(
529 sqe: *linux.io_uring_sqe,
530 fds: []const linux.fd_t,
531 offset: u32,
532 ) void {
533 sqe.prep_rw(.FILES_UPDATE, -1, @intFromPtr(fds.ptr), fds.len, @intCast(offset));
534 }
535
536 pub fn prep_files_update_alloc(
537 sqe: *linux.io_uring_sqe,
538 fds: []linux.fd_t,
539 ) void {
540 sqe.prep_rw(.FILES_UPDATE, -1, @intFromPtr(fds.ptr), fds.len, linux.IORING_FILE_INDEX_ALLOC);
541 }
542
528543 pub fn prep_provide_buffers(
529544 sqe: *linux.io_uring_sqe,
530545 buffers: [*]u8,