io_uring: use rsrc prealloc infra for files reg
authorPavel Begunkov <asml.silence@gmail.com>
Thu, 1 Apr 2021 14:43:42 +0000 (15:43 +0100)
committerJens Axboe <axboe@kernel.dk>
Sun, 4 Apr 2021 21:28:41 +0000 (15:28 -0600)
commit7531e346c21d976ddd044fcd519ff366db971087
tree37be77e3aaba69b7bf35238e5a1bdaa7328cc512
parent53f3c7b53954fe312f2756d0240e9097261e640f
io_uring: use rsrc prealloc infra for files reg

Keep it consistent with update and use io_rsrc_node_prealloc() +
io_rsrc_node_get() in io_sqe_files_register() as well, that will be used
in future patches, not as error prone and allows to deduplicate
rsrc_node init.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/cf87321e6be5e38f4dc7fe5079d2aa6945b1ace0.1617287883.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c