Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

io_uring: convert xattr to use io_cmd_type

Signed-off-by: Jens Axboe <axboe@kernel.dk>

+9 -10
+9 -10
io_uring/io_uring.c
··· 979 979 */ 980 980 struct file *file; 981 981 struct io_cmd_data cmd; 982 - struct io_xattr xattr; 983 982 struct io_uring_cmd uring_cmd; 984 983 }; 985 984 ··· 4401 4402 4402 4403 static inline void __io_xattr_finish(struct io_kiocb *req) 4403 4404 { 4404 - struct io_xattr *ix = &req->xattr; 4405 + struct io_xattr *ix = io_kiocb_to_cmd(req); 4405 4406 4406 4407 if (ix->filename) 4407 4408 putname(ix->filename); ··· 4421 4422 static int __io_getxattr_prep(struct io_kiocb *req, 4422 4423 const struct io_uring_sqe *sqe) 4423 4424 { 4424 - struct io_xattr *ix = &req->xattr; 4425 + struct io_xattr *ix = io_kiocb_to_cmd(req); 4425 4426 const char __user *name; 4426 4427 int ret; 4427 4428 ··· 4464 4465 static int io_getxattr_prep(struct io_kiocb *req, 4465 4466 const struct io_uring_sqe *sqe) 4466 4467 { 4467 - struct io_xattr *ix = &req->xattr; 4468 + struct io_xattr *ix = io_kiocb_to_cmd(req); 4468 4469 const char __user *path; 4469 4470 int ret; 4470 4471 ··· 4485 4486 4486 4487 static int io_fgetxattr(struct io_kiocb *req, unsigned int issue_flags) 4487 4488 { 4488 - struct io_xattr *ix = &req->xattr; 4489 + struct io_xattr *ix = io_kiocb_to_cmd(req); 4489 4490 int ret; 4490 4491 4491 4492 if (issue_flags & IO_URING_F_NONBLOCK) ··· 4501 4502 4502 4503 static int io_getxattr(struct io_kiocb *req, unsigned int issue_flags) 4503 4504 { 4504 - struct io_xattr *ix = &req->xattr; 4505 + struct io_xattr *ix = io_kiocb_to_cmd(req); 4505 4506 unsigned int lookup_flags = LOOKUP_FOLLOW; 4506 4507 struct path path; 4507 4508 int ret; ··· 4530 4531 static int __io_setxattr_prep(struct io_kiocb *req, 4531 4532 const struct io_uring_sqe *sqe) 4532 4533 { 4533 - struct io_xattr *ix = &req->xattr; 4534 + struct io_xattr *ix = io_kiocb_to_cmd(req); 4534 4535 const char __user *name; 4535 4536 int ret; 4536 4537 ··· 4561 4562 static int io_setxattr_prep(struct io_kiocb *req, 4562 4563 const struct io_uring_sqe *sqe) 4563 4564 { 4564 - struct io_xattr *ix = &req->xattr; 4565 + struct io_xattr *ix = io_kiocb_to_cmd(req); 4565 4566 const char __user *path; 4566 4567 int ret; 4567 4568 ··· 4589 4590 static int __io_setxattr(struct io_kiocb *req, unsigned int issue_flags, 4590 4591 struct path *path) 4591 4592 { 4592 - struct io_xattr *ix = &req->xattr; 4593 + struct io_xattr *ix = io_kiocb_to_cmd(req); 4593 4594 int ret; 4594 4595 4595 4596 ret = mnt_want_write(path->mnt); ··· 4616 4617 4617 4618 static int io_setxattr(struct io_kiocb *req, unsigned int issue_flags) 4618 4619 { 4619 - struct io_xattr *ix = &req->xattr; 4620 + struct io_xattr *ix = io_kiocb_to_cmd(req); 4620 4621 unsigned int lookup_flags = LOOKUP_FOLLOW; 4621 4622 struct path path; 4622 4623 int ret;