summaryrefslogtreecommitdiffstats
path: root/io_uring
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2024-09-23 18:35:36 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2024-09-23 18:35:36 +0200
commitf8ffbc365f703d74ecca8ca787318d05bbee2bf7 (patch)
treecdb3e023473e02a186b39fe541eb719ed2ffcb7f /io_uring
parentmm: fix build on 32-bit targets without MAX_PHYSMEM_BITS (diff)
parentadd struct fd constructors, get rid of __to_fd() (diff)
downloadlinux-f8ffbc365f703d74ecca8ca787318d05bbee2bf7.tar.xz
linux-f8ffbc365f703d74ecca8ca787318d05bbee2bf7.zip
Merge tag 'pull-stable-struct_fd' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Pull 'struct fd' updates from Al Viro: "Just the 'struct fd' layout change, with conversion to accessor helpers" * tag 'pull-stable-struct_fd' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: add struct fd constructors, get rid of __to_fd() struct fd: representation change introduce fd_file(), convert all accessors to it.
Diffstat (limited to 'io_uring')
-rw-r--r--io_uring/sqpoll.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/io_uring/sqpoll.c b/io_uring/sqpoll.c
index 272df9d00f45..4a59a024278a 100644
--- a/io_uring/sqpoll.c
+++ b/io_uring/sqpoll.c
@@ -109,14 +109,14 @@ static struct io_sq_data *io_attach_sq_data(struct io_uring_params *p)
struct fd f;
f = fdget(p->wq_fd);
- if (!f.file)
+ if (!fd_file(f))
return ERR_PTR(-ENXIO);
- if (!io_is_uring_fops(f.file)) {
+ if (!io_is_uring_fops(fd_file(f))) {
fdput(f);
return ERR_PTR(-EINVAL);
}
- ctx_attach = f.file->private_data;
+ ctx_attach = fd_file(f)->private_data;
sqd = ctx_attach->sq_data;
if (!sqd) {
fdput(f);
@@ -419,9 +419,9 @@ __cold int io_sq_offload_create(struct io_ring_ctx *ctx,
struct fd f;
f = fdget(p->wq_fd);
- if (!f.file)
+ if (!fd_file(f))
return -ENXIO;
- if (!io_is_uring_fops(f.file)) {
+ if (!io_is_uring_fops(fd_file(f))) {
fdput(f);
return -EINVAL;
}