Currently opcode is being assigned to a dereferenced pointer sqe before sqe is being assigned. It appears the order of these two assignments cs the wrong way around. Fix this by swapping the order of the assignments. Fixes: 31dc41afdef2 ("io_uring: add support for IORING_SETUP_SQE_MIXED") Signed-off-by: Colin Ian King --- io_uring/fdinfo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/io_uring/fdinfo.c b/io_uring/fdinfo.c index d5aa64203de5..5b26b2a97e1b 100644 --- a/io_uring/fdinfo.c +++ b/io_uring/fdinfo.c @@ -100,8 +100,8 @@ static void __io_uring_show_fdinfo(struct io_ring_ctx *ctx, struct seq_file *m) if (sq_idx > sq_mask) continue; - opcode = READ_ONCE(sqe->opcode); sqe = &ctx->sq_sqes[sq_idx << sq_shift]; + opcode = READ_ONCE(sqe->opcode); if (sq_shift) { sqe128 = true; } else if (io_issue_defs[opcode].is_128) { -- 2.51.0