If the client stream receive code receives an ESHUTDOWN error either
because the server closed the connection, or because it sent a
callback which cannot be processed, then we should shut down
the connection.
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
                read += ret;
                cond_resched();
        }
-       xs_poll_check_readable(transport);
+       if (ret == -ESHUTDOWN)
+               kernel_sock_shutdown(transport->sock, SHUT_RDWR);
+       else
+               xs_poll_check_readable(transport);
 out:
        mutex_unlock(&transport->recv_mutex);
        trace_xs_stream_read_data(&transport->xprt, ret, read);