From 72a675953c87f748ef83bf9f7c3f3a0a868da16d Mon Sep 17 00:00:00 2001 From: Jens Axboe Date: Sun, 13 Jan 2019 09:15:32 -0700 Subject: [PATCH] io_uring: ensure that the io_uring_register() structs are 32-bit safe Signed-off-by: Jens Axboe --- os/linux/io_uring.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/os/linux/io_uring.h b/os/linux/io_uring.h index 3693d125..71e92026 100644 --- a/os/linux/io_uring.h +++ b/os/linux/io_uring.h @@ -137,12 +137,18 @@ struct io_uring_params { #define IORING_UNREGISTER_FILES 3 struct io_uring_register_buffers { - struct iovec *iovecs; + union { + struct iovec *iovecs; + __u64 pad; + }; __u32 nr_iovecs; }; struct io_uring_register_files { - __s32 *fds; + union { + __s32 *fds; + __u64 pad; + }; __u32 nr_fds; }; -- 2.25.1