io_uring: convert accept4() -ERESTARTSYS into -EINTR
authorJens Axboe <axboe@kernel.dk>
Sun, 10 Nov 2019 02:52:33 +0000 (19:52 -0700)
committerJens Axboe <axboe@kernel.dk>
Mon, 11 Nov 2019 03:29:49 +0000 (20:29 -0700)
commit8e3cca12706231daf8daf90dbde59f1665135e48
treeb16874f8a3afa054af6c1543eb0172b46b6a1e7e
parent46568e9be70ff8211d986685f08d919376c32998
io_uring: convert accept4() -ERESTARTSYS into -EINTR

If we cancel a pending accept operating with a signal, we get
-ERESTARTSYS returned. Turn that into -EINTR for userspace, we should
not be return -ERESTARTSYS.

Fixes: 17f2fe35d080 ("io_uring: add support for IORING_OP_ACCEPT")
Reported-by: Hrvoje Zeba <zeba.hrvoje@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c