[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4e08b49c-a0e3-4e17-bfdd-a58182b900d9@kernel.dk>
Date: Wed, 26 Nov 2025 09:51:51 -0700
From: Jens Axboe <axboe@...nel.dk>
To: Gabriel Krisman Bertazi <krisman@...e.de>
Cc: netdev@...r.kernel.org, io-uring@...r.kernel.org,
Jakub Kicinski <kuba@...nel.org>, "David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>, Kuniyuki Iwashima <kuniyu@...gle.com>,
Paolo Abeni <pabeni@...hat.com>, Willem de Bruijn <willemb@...gle.com>,
Simon Horman <horms@...nel.org>
Subject: Re: [PATCH v4 3/3] io_uring: Introduce getsockname io_uring cmd
On 11/25/25 2:18 PM, Gabriel Krisman Bertazi wrote:
> +static int io_uring_cmd_getsockname(struct socket *sock,
> + struct io_uring_cmd *cmd,
> + unsigned int issue_flags)
> +{
> + const struct io_uring_sqe *sqe = cmd->sqe;
> + struct sockaddr __user *uaddr;
> + unsigned int peer;
> + int __user *ulen;
> +
> + if (sqe->ioprio || sqe->__pad1 || sqe->len || sqe->rw_flags)
> + return -EINVAL;
> +
> + uaddr = u64_to_user_ptr(READ_ONCE(sqe->addr));
> + ulen = u64_to_user_ptr(sqe->addr3);
Missing READ_ONCE() for this one. But I can just amend that, pretty
trivial.
Outside of that, this looks good to me. Bigger question is how to stage
this, in terms of the two networking patches. Jakub?
--
Jens Axboe
Powered by blists - more mailing lists