Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 242900
b: refs/heads/master
c: cd88d03
h: refs/heads/master
v: v3
  • Loading branch information
Philipp Reisner committed Mar 10, 2011
1 parent 1346936 commit 9afc7c5
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 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: 79a30d2d71f7be862de93228fe9b919ef664af52
refs/heads/master: cd88d030d41a9b0100fd5fee872024e6ebc8b276
12 changes: 10 additions & 2 deletions trunk/drivers/block/drbd/drbd_nl.c
Original file line number Diff line number Diff line change
Expand Up @@ -1952,9 +1952,17 @@ static int drbd_nl_resume_sync(struct drbd_conf *mdev, struct drbd_nl_cfg_req *n
struct drbd_nl_cfg_reply *reply)
{
int retcode = NO_ERROR;
union drbd_state s;

if (drbd_request_state(mdev, NS(user_isp, 0)) == SS_NOTHING_TO_DO)
retcode = ERR_PAUSE_IS_CLEAR;
if (drbd_request_state(mdev, NS(user_isp, 0)) == SS_NOTHING_TO_DO) {
s = mdev->state;
if (s.conn == C_PAUSED_SYNC_S || s.conn == C_PAUSED_SYNC_T) {
retcode = s.aftr_isp ? ERR_PIC_AFTER_DEP :
s.peer_isp ? ERR_PIC_PEER_DEP : ERR_PAUSE_IS_CLEAR;
} else {
retcode = ERR_PAUSE_IS_CLEAR;
}
}

reply->ret_code = retcode;
return 0;
Expand Down
2 changes: 2 additions & 0 deletions trunk/include/linux/drbd.h
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,8 @@ enum drbd_ret_code {
ERR_NEED_APV_93 = 153,
ERR_STONITH_AND_PROT_A = 154,
ERR_CONG_NOT_PROTO_A = 155,
ERR_PIC_AFTER_DEP = 156,
ERR_PIC_PEER_DEP = 157,

/* insert new ones above this line */
AFTER_LAST_ERR_CODE
Expand Down

0 comments on commit 9afc7c5

Please sign in to comment.