File tree Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -855,6 +855,10 @@ int io_recvmsg(struct io_kiocb *req, unsigned int issue_flags)
855855 if (!io_check_multishot (req , issue_flags ))
856856 return io_setup_async_msg (req , kmsg , issue_flags );
857857
858+ flags = sr -> msg_flags ;
859+ if (force_nonblock )
860+ flags |= MSG_DONTWAIT ;
861+
858862retry_multishot :
859863 if (io_do_buffer_select (req )) {
860864 void __user * buf ;
@@ -875,10 +879,6 @@ int io_recvmsg(struct io_kiocb *req, unsigned int issue_flags)
875879 iov_iter_ubuf (& kmsg -> msg .msg_iter , ITER_DEST , buf , len );
876880 }
877881
878- flags = sr -> msg_flags ;
879- if (force_nonblock )
880- flags |= MSG_DONTWAIT ;
881-
882882 kmsg -> msg .msg_get_inq = 1 ;
883883 kmsg -> msg .msg_inq = -1 ;
884884 if (req -> flags & REQ_F_APOLL_MULTISHOT ) {
@@ -964,6 +964,10 @@ int io_recv(struct io_kiocb *req, unsigned int issue_flags)
964964 msg .msg_iocb = NULL ;
965965 msg .msg_ubuf = NULL ;
966966
967+ flags = sr -> msg_flags ;
968+ if (force_nonblock )
969+ flags |= MSG_DONTWAIT ;
970+
967971retry_multishot :
968972 if (io_do_buffer_select (req )) {
969973 void __user * buf ;
@@ -982,9 +986,6 @@ int io_recv(struct io_kiocb *req, unsigned int issue_flags)
982986 msg .msg_inq = -1 ;
983987 msg .msg_flags = 0 ;
984988
985- flags = sr -> msg_flags ;
986- if (force_nonblock )
987- flags |= MSG_DONTWAIT ;
988989 if (flags & MSG_WAITALL )
989990 min_ret = iov_iter_count (& msg .msg_iter );
990991
You can’t perform that action at this time.
0 commit comments