[RHEL7,COMMIT] kio: Stop always breaking connection in pcs_sockio_send() in case of EAGAIN.

Submitted by Konstantin Khorenko on May 23, 2018, 7:55 a.m.

Details

Message ID 201805230755.w4N7tvkx003112@finist_ce7.work
State New
Series "kio: Stop always breaking connection in pcs_sockio_send() in case of EAGAIN."
Headers show

Commit Message

Konstantin Khorenko May 23, 2018, 7:55 a.m.
The commit is pushed to "branch-rh7-3.10.0-693.21.1.vz7.50.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-693.21.1.vz7.50.1
------>
commit a01088bf34ef8074a5234e0d5e87c568390562ab
Author: Kirill Tkhai <ktkhai@virtuozzo.com>
Date:   Wed May 23 10:55:56 2018 +0300

    kio: Stop always breaking connection in pcs_sockio_send() in case of EAGAIN.
    
    We should just return and not fall into sio_abort(sio, PCS_ERR_NET_ABORT),
    in case EGAIN. The right logic is to we break connection in with
    PCS_ERR_WRITE_TIMEOUT, in case of timeout is expired.
    
    https://pmc.acronis.com/browse/VSTOR-9848
    
    Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
---
 fs/fuse/kio/pcs/pcs_sock_io.c | 1 +
 1 file changed, 1 insertion(+)

Patch hide | download patch | download mbox

diff --git a/fs/fuse/kio/pcs/pcs_sock_io.c b/fs/fuse/kio/pcs/pcs_sock_io.c
index 6936dede5b96..29cd199dffa0 100644
--- a/fs/fuse/kio/pcs/pcs_sock_io.c
+++ b/fs/fuse/kio/pcs/pcs_sock_io.c
@@ -312,6 +312,7 @@  static void pcs_sockio_send(struct pcs_sockio *sio)
 					unsigned long timeout = msg->start_time + sio->send_timeout;
 					if (time_is_before_jiffies(timeout))
 						sio_abort(sio, PCS_ERR_WRITE_TIMEOUT);
+					return;
 				}
 				sio_abort(sio, PCS_ERR_NET_ABORT);
 				return;