Files
linux/fs
Jens Axboe fd2206e4e9 io_uring: disallow close of ring itself
A previous commit enabled this functionality, which also enabled O_PATH
to work correctly with io_uring. But we can't safely close the ring
itself, as the file handle isn't reference counted inside
io_uring_enter(). Instead of jumping through hoops to enable ring
closure, add a "soft" ->needs_file option, ->needs_file_no_error. This
enables O_PATH file descriptors to work, but still catches the case of
trying to close the ring itself.

Reported-by: Jann Horn <jannh@google.com>
Fixes: 904fbcb115 ("io_uring: remove 'fd is io_uring' from close path")
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2020-06-02 17:22:24 -06:00
..
2020-03-27 09:29:56 +00:00
2019-11-11 09:21:59 -05:00
2020-06-02 10:59:07 -07:00
2020-05-14 16:44:24 +02:00
2020-05-14 16:44:25 +02:00
2020-02-07 14:48:35 -05:00
2020-04-20 15:45:41 -06:00
2020-03-05 21:00:40 -05:00
2020-05-14 16:44:24 +02:00
2020-03-12 17:33:11 -07:00
2020-05-14 16:44:24 +02:00
2019-12-08 14:37:36 +01:00
2020-05-14 16:44:24 +02:00
2020-04-09 15:33:09 -04:00