2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-17 17:53:56 +08:00

DLM: close othercon at send/receive error

If an error occurs in the sending / receiving process, if othercon
exists, sending / receiving processing using othercon may also result
in an error. We fix to pre-close othercon as well.

Signed-off-by: Tadashi Miyauchi <miyauchi@toshiba-tops.co.jp>
Signed-off-by: Tsutomu Owa <tsutomu.owa@toshiba.co.jp>
Signed-off-by: David Teigland <teigland@redhat.com>
This commit is contained in:
tsutomu.owa@toshiba.co.jp 2017-09-12 08:56:15 +00:00 committed by David Teigland
parent 5966121241
commit c553e173b0

View File

@ -703,7 +703,7 @@ out_resched:
out_close:
mutex_unlock(&con->sock_mutex);
if (ret != -EAGAIN) {
close_connection(con, false, true, false);
close_connection(con, true, true, false);
/* Reconnect when there is something to send */
}
/* Don't return success if we really got EOF */
@ -1530,7 +1530,7 @@ out:
send_error:
mutex_unlock(&con->sock_mutex);
close_connection(con, false, false, true);
close_connection(con, true, false, true);
/* Requeue the send work. When the work daemon runs again, it will try
a new connection, then call this function again. */
queue_work(send_workqueue, &con->swork);