Skip to contentSkip to conversation

io_uring: Remove superfluous check for sqe->off in io_connect()

PATCH In review Hrvoje Zeba 2 participants 2 messages Nov 25, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 io_uring: Remove superfluous check for sqe->off in io_connect()

This field contains addrlen value and checking to see if it's set returns -EINVAL.

---
 fs/io_uring.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/io_uring.c +1 -1
index 8cb8f3898c77..f5e81b5511e1 100644
@@ -1998,7 +1998,7 @@ static int io_connect(struct io_kiocb *req, const struct io_uring_sqe *sqe,
 
 	if (unlikely(req->ctx->flags & (IORING_SETUP_IOPOLL|IORING_SETUP_SQPOLL)))
 		return -EINVAL;
-	if (sqe->ioprio || sqe->off || sqe->len || sqe->buf_index ||
+	if (sqe->ioprio || sqe->len || sqe->buf_index ||
 	    sqe->rw_flags)
 		return -EINVAL;
 
Signature · 1 line
2.24.0
maintainer
#1 lore raw
Quoted 2 lines · Hrvoje Zeba

This field contains addrlen value and checking to see if it's set returns -EINVAL.

Folded in, thanks.

Signature · 1 line
Jens Axboe