aboutsummaryrefslogtreecommitdiffstats
path: root/fs/dlm/lowcomms.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/dlm/lowcomms.c')
-rw-r--r--fs/dlm/lowcomms.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/dlm/lowcomms.c b/fs/dlm/lowcomms.c
index 62a8a6ccd992..58bf3f5cdbe2 100644
--- a/fs/dlm/lowcomms.c
+++ b/fs/dlm/lowcomms.c
@@ -1264,14 +1264,15 @@ static void send_to_sock(struct connection *con)
1264 if (len) { 1264 if (len) {
1265 ret = sendpage(con->sock, e->page, offset, len, 1265 ret = sendpage(con->sock, e->page, offset, len,
1266 msg_flags); 1266 msg_flags);
1267 if (ret == -EAGAIN || ret == 0) 1267 if (ret == -EAGAIN || ret == 0) {
1268 cond_resched();
1268 goto out; 1269 goto out;
1270 }
1269 if (ret <= 0) 1271 if (ret <= 0)
1270 goto send_error; 1272 goto send_error;
1271 } else { 1273 }
1272 /* Don't starve people filling buffers */ 1274 /* Don't starve people filling buffers */
1273 cond_resched(); 1275 cond_resched();
1274 }
1275 1276
1276 spin_lock(&con->writequeue_lock); 1277 spin_lock(&con->writequeue_lock);
1277 e->offset += ret; 1278 e->offset += ret;