Hi Jens, Could you please spent some time to look at this? Thanks, Jiufei On 2020/6/1 上午11:26, Jiufei Xue wrote: > Hi Jens, > > On 2020/5/29 下午10:20, Jens Axboe wrote: >> On 5/29/20 1:18 AM, Jiufei Xue wrote: >>> When read from a regular file that was opened O_NONBLOCK, it will >>> return EAGAIN if the page is not cached, which is not expected and >>> fails the application. >>> >>> Applications written before expect that the open flag O_NONBLOCK has >>> no effect on a regular file. >>> >>> Fix this by not setting REQ_F_NOWAIT for regular files. >> >> Agree, this also matches what we do for sockets. You need to update >> the comment as well, though. >> > Reading from an O_NONBLOCK socket will return EAGAIN if there isn't any > unread data in the buffer which is expected.So I don't know what is your > meaning about that. Do you mean the recv() interface? > > Regards, > Jiufei >