Closed Eugene-Usachev closed 1 month ago
Sometimes this can be caused by the kernel version. Perhaps SendZc isn't supported on the kernel you are trying. Often looking at the man page for liburing will tell you when the io_uring feature you are trying to use was introduced to the kernel.
I tried to use SendZc and got "{ code: 22, kind: InvalidInput, message: "Invalid argument" }". This is strange because when I use Send for the same task I don't get any errors. I use SendZc like
fn send_zc(&mut self, fd: Fd, buf_ptr: *const u8, len: usize, data: u64) { self.register_entry(opcode::SendZc::new(types::Fd(fd), buf_ptr, len as _).build(), data); }
where self.register_entry just register the entry with the data.
I've read a code of the crate tests and there just SendZc is used instead of Send. Need I to set some flags or give some new guarantees?