[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210519113058.1979817-3-memxor@gmail.com>
Date: Wed, 19 May 2021 17:00:57 +0530
From: Kumar Kartikeya Dwivedi <memxor@...il.com>
To: io-uring@...r.kernel.org
Cc: Pavel Emelyanov <xemul@...nvz.org>,
Kumar Kartikeya Dwivedi <memxor@...il.com>,
Alexander Viro <viro@...iv.linux.org.uk>,
Jens Axboe <axboe@...nel.dk>,
Pavel Begunkov <asml.silence@...il.com>,
Daniel Colascione <dancol@...gle.com>,
Paul Moore <paul@...l-moore.com>,
Lokesh Gidra <lokeshgidra@...gle.com>,
Eric Biggers <ebiggers@...gle.com>,
linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH 2/2] fs: io_uring: convert to use anon_inode_getfile_secure
Make io_uring use anon_inode_getfile_secure helper exposed in previous
commit. This gives each io_uring instance a distinct inode.
Signed-off-by: Kumar Kartikeya Dwivedi <memxor@...il.com>
---
fs/io_uring.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/io_uring.c b/fs/io_uring.c
index 65a17d560a73..001fcfb63f33 100644
--- a/fs/io_uring.c
+++ b/fs/io_uring.c
@@ -9454,8 +9454,8 @@ static struct file *io_uring_get_file(struct io_ring_ctx *ctx)
return ERR_PTR(ret);
#endif
- file = anon_inode_getfile("[io_uring]", &io_uring_fops, ctx,
- O_RDWR | O_CLOEXEC);
+ file = anon_inode_getfile_secure("[io_uring]", &io_uring_fops, ctx,
+ O_RDWR | O_CLOEXEC, NULL);
#if defined(CONFIG_UNIX)
if (IS_ERR(file)) {
sock_release(ctx->ring_sock);
--
2.31.1
Powered by blists - more mailing lists