Skip to contentSkip to conversation

io_uring: Delete useless variable ‘id’ in io_prep_async_work

PATCH Applied Ye Bin 2 participants 2 messages Jan 5, 2021

Subsystems (2)
lore
Share & tools
lore

Ye Bin

author
#0 lore raw

PATCH 1/1 io_uring: Delete useless variable ‘id’ in io_prep_async_work

Fix follow warning:
fs/io_uring.c:1523:22: warning: variable ‘id’ set but not used [-Wunused-but-set-variable]

  struct io_identity *id;
                        ^~
---
 fs/io_uring.c | 2 --
 1 file changed, 2 deletions(-)
fs/io_uring.c +0 -2
index ca46f314640b..7880cfe01e4b 100644
@@ -1520,10 +1520,8 @@ static void io_prep_async_work(struct io_kiocb *req)
 {
 	const struct io_op_def *def = &io_op_defs[req->opcode];
 	struct io_ring_ctx *ctx = req->ctx;
-	struct io_identity *id;
 
 	io_req_init_async(req);
-	id = req->work.identity;
 
 	if (req->flags & REQ_F_FORCE_ASYNC)
 		req->work.flags |= IO_WQ_WORK_CONCURRENT;
Signature · 1 line
2.16.2.dirty
maintainer Applied
#1 lore raw
Quoted 5 lines · Ye Bin

Fix follow warning:
fs/io_uring.c:1523:22: warning: variable ‘id’ set but not used [-Wunused-but-set-variable]

  struct io_identity *id;
                        ^~

Applied, thanks.

Signature · 1 line
Jens Axboe