From: Jens Axboe Date: Wed, 4 Jun 2025 14:49:32 +0000 (-0600) Subject: io_uring/futex: get rid of struct io_futex addr union X-Git-Tag: v6.16-rc1~27^2~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=6a8118a77eec5fc4dfec69cc6bdc52229943f6ef;p=thirdparty%2Flinux.git io_uring/futex: get rid of struct io_futex addr union Rather than use a union of a u32 and struct futex_waitv user address, consolidate it into a single void __user pointer instead. This also makes prep easier to use as the store happens to the member that will be used. No functional changes in this patch. Signed-off-by: Jens Axboe --- diff --git a/io_uring/futex.c b/io_uring/futex.c index fa374afbaa51..5a3991b0d1a7 100644 --- a/io_uring/futex.c +++ b/io_uring/futex.c @@ -14,10 +14,7 @@ struct io_futex { struct file *file; - union { - u32 __user *uaddr; - struct futex_waitv __user *uwaitv; - }; + void __user *uaddr; unsigned long futex_val; unsigned long futex_mask; unsigned long futexv_owned; @@ -186,7 +183,7 @@ int io_futexv_prep(struct io_kiocb *req, const struct io_uring_sqe *sqe) if (!futexv) return -ENOMEM; - ret = futex_parse_waitv(futexv, iof->uwaitv, iof->futex_nr, + ret = futex_parse_waitv(futexv, iof->uaddr, iof->futex_nr, io_futex_wakev_fn, req); if (ret) { kfree(futexv);