File tree 1 file changed +8
-7
lines changed 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)
855
855
if (!io_check_multishot (req , issue_flags ))
856
856
return io_setup_async_msg (req , kmsg , issue_flags );
857
857
858
+ flags = sr -> msg_flags ;
859
+ if (force_nonblock )
860
+ flags |= MSG_DONTWAIT ;
861
+
858
862
retry_multishot :
859
863
if (io_do_buffer_select (req )) {
860
864
void __user * buf ;
@@ -875,10 +879,6 @@ int io_recvmsg(struct io_kiocb *req, unsigned int issue_flags)
875
879
iov_iter_ubuf (& kmsg -> msg .msg_iter , ITER_DEST , buf , len );
876
880
}
877
881
878
- flags = sr -> msg_flags ;
879
- if (force_nonblock )
880
- flags |= MSG_DONTWAIT ;
881
-
882
882
kmsg -> msg .msg_get_inq = 1 ;
883
883
kmsg -> msg .msg_inq = -1 ;
884
884
if (req -> flags & REQ_F_APOLL_MULTISHOT ) {
@@ -964,6 +964,10 @@ int io_recv(struct io_kiocb *req, unsigned int issue_flags)
964
964
msg .msg_iocb = NULL ;
965
965
msg .msg_ubuf = NULL ;
966
966
967
+ flags = sr -> msg_flags ;
968
+ if (force_nonblock )
969
+ flags |= MSG_DONTWAIT ;
970
+
967
971
retry_multishot :
968
972
if (io_do_buffer_select (req )) {
969
973
void __user * buf ;
@@ -982,9 +986,6 @@ int io_recv(struct io_kiocb *req, unsigned int issue_flags)
982
986
msg .msg_inq = -1 ;
983
987
msg .msg_flags = 0 ;
984
988
985
- flags = sr -> msg_flags ;
986
- if (force_nonblock )
987
- flags |= MSG_DONTWAIT ;
988
989
if (flags & MSG_WAITALL )
989
990
min_ret = iov_iter_count (& msg .msg_iter );
990
991
You can’t perform that action at this time.
0 commit comments