Commit b48596ef authored by Ziye Yang's avatar Ziye Yang Committed by Tomasz Zawadzki
Browse files

lib/nbd: Remove errno != EWOULDBLOCK in nbd_socket_rw



In this commit (a1d4a714),
we refactor the code but introduce the new error comparison.

And it causes the hang issue in some cases for RPC, so remove
it.

Change-Id: I4da802dff24b7efc27dd25a05739f1def37c1486
Signed-off-by: default avatarZiye Yang <ziye.yang@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5767


Community-CI: Mellanox Build Bot
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Reviewed-by: default avatar <dongx.yi@intel.com>
Reviewed-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
parent 01f2d0bd
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -439,7 +439,7 @@ nbd_socket_rw(int fd, void *buf, size_t length, bool read_op)
	if (rc == 0) {
		return -EIO;
	} else if (rc == -1) {
		if (errno != EAGAIN && errno != EWOULDBLOCK) {
		if (errno != EAGAIN) {
			return -errno;
		}
		return 0;