mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-24 20:40:52 +07:00
nbd: pass MSG_* flags to kernel_recvmsg()
Unlike kernel_sendmsg(), kernel_recvmsg() requires passing flags explicitly via last parameter instead of struct msghdr.msg_flags. Therefore calls to sock_xmit(lo, 0, ..., MSG_WAITALL) have not been processed properly by tcp layer wrt. the flag. Fix it. Signed-off-by: Namhyung Kim <namhyung@gmail.com> Cc: Paul Clements <Paul.Clements@steeleye.com> Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
This commit is contained in:
parent
6df87e65db
commit
35fbf5bcf4
@ -192,7 +192,8 @@ static int sock_xmit(struct nbd_device *lo, int send, void *buf, int size,
|
|||||||
if (lo->xmit_timeout)
|
if (lo->xmit_timeout)
|
||||||
del_timer_sync(&ti);
|
del_timer_sync(&ti);
|
||||||
} else
|
} else
|
||||||
result = kernel_recvmsg(sock, &msg, &iov, 1, size, 0);
|
result = kernel_recvmsg(sock, &msg, &iov, 1, size,
|
||||||
|
msg.msg_flags);
|
||||||
|
|
||||||
if (signal_pending(current)) {
|
if (signal_pending(current)) {
|
||||||
siginfo_t info;
|
siginfo_t info;
|
||||||
|
Loading…
Reference in New Issue
Block a user