Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 196838
b: refs/heads/master
c: c3470cd
h: refs/heads/master
v: v3
  • Loading branch information
Lars Ellenberg authored and Philipp Reisner committed May 17, 2010
1 parent e5f1072 commit dfc0288
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8d1894ebe441093cfd967affcbc56b764960575e
refs/heads/master: c3470cde57ea34d9b4bd34891ec040e46b9fb3bf
5 changes: 4 additions & 1 deletion trunk/drivers/block/drbd/drbd_receiver.c
Original file line number Diff line number Diff line change
Expand Up @@ -1331,6 +1331,9 @@ static int drbd_drain_block(struct drbd_conf *mdev, int data_size)
int rr, rv = 1;
void *data;

if (!data_size)
return TRUE;

page = drbd_pp_alloc(mdev, 1);

data = kmap(page);
Expand Down Expand Up @@ -1946,7 +1949,7 @@ static int receive_DataRequest(struct drbd_conf *mdev, struct p_header *h)
"no local data.\n");
drbd_send_ack_rp(mdev, h->command == P_DATA_REQUEST ? P_NEG_DREPLY :
P_NEG_RS_DREPLY , p);
return TRUE;
return drbd_drain_block(mdev, h->length - brps);
}

/* GFP_NOIO, because we must not cause arbitrary write-out: in a DRBD
Expand Down

0 comments on commit dfc0288

Please sign in to comment.