diff options
Diffstat (limited to 'fs/ocfs2/stack_o2cb.c')
| -rw-r--r-- | fs/ocfs2/stack_o2cb.c | 15 | 
1 files changed, 4 insertions, 11 deletions
| diff --git a/fs/ocfs2/stack_o2cb.c b/fs/ocfs2/stack_o2cb.c index fa9dd79c3615..7020e1253ffa 100644 --- a/fs/ocfs2/stack_o2cb.c +++ b/fs/ocfs2/stack_o2cb.c | |||
| @@ -163,28 +163,21 @@ static void o2dlm_lock_ast_wrapper(void *astarg) | |||
| 163 | { | 163 | { | 
| 164 | struct ocfs2_dlm_lksb *lksb = astarg; | 164 | struct ocfs2_dlm_lksb *lksb = astarg; | 
| 165 | 165 | ||
| 166 | BUG_ON(o2cb_stack.sp_proto == NULL); | 166 | lksb->lksb_conn->cc_proto->lp_lock_ast(lksb); | 
| 167 | |||
| 168 | o2cb_stack.sp_proto->lp_lock_ast(lksb); | ||
| 169 | } | 167 | } | 
| 170 | 168 | ||
| 171 | static void o2dlm_blocking_ast_wrapper(void *astarg, int level) | 169 | static void o2dlm_blocking_ast_wrapper(void *astarg, int level) | 
| 172 | { | 170 | { | 
| 173 | struct ocfs2_dlm_lksb *lksb = astarg; | 171 | struct ocfs2_dlm_lksb *lksb = astarg; | 
| 174 | 172 | ||
| 175 | BUG_ON(o2cb_stack.sp_proto == NULL); | 173 | lksb->lksb_conn->cc_proto->lp_blocking_ast(lksb, level); | 
| 176 | |||
| 177 | o2cb_stack.sp_proto->lp_blocking_ast(lksb, level); | ||
| 178 | } | 174 | } | 
| 179 | 175 | ||
| 180 | static void o2dlm_unlock_ast_wrapper(void *astarg, enum dlm_status status) | 176 | static void o2dlm_unlock_ast_wrapper(void *astarg, enum dlm_status status) | 
| 181 | { | 177 | { | 
| 182 | struct ocfs2_dlm_lksb *lksb = astarg; | 178 | struct ocfs2_dlm_lksb *lksb = astarg; | 
| 183 | |||
| 184 | int error = dlm_status_to_errno(status); | 179 | int error = dlm_status_to_errno(status); | 
| 185 | 180 | ||
| 186 | BUG_ON(o2cb_stack.sp_proto == NULL); | ||
| 187 | |||
| 188 | /* | 181 | /* | 
| 189 | * In o2dlm, you can get both the lock_ast() for the lock being | 182 | * In o2dlm, you can get both the lock_ast() for the lock being | 
| 190 | * granted and the unlock_ast() for the CANCEL failing. A | 183 | * granted and the unlock_ast() for the CANCEL failing. A | 
| @@ -199,7 +192,7 @@ static void o2dlm_unlock_ast_wrapper(void *astarg, enum dlm_status status) | |||
| 199 | if (status == DLM_CANCELGRANT) | 192 | if (status == DLM_CANCELGRANT) | 
| 200 | return; | 193 | return; | 
| 201 | 194 | ||
| 202 | o2cb_stack.sp_proto->lp_unlock_ast(lksb, error); | 195 | lksb->lksb_conn->cc_proto->lp_unlock_ast(lksb, error); | 
| 203 | } | 196 | } | 
| 204 | 197 | ||
| 205 | static int o2cb_dlm_lock(struct ocfs2_cluster_connection *conn, | 198 | static int o2cb_dlm_lock(struct ocfs2_cluster_connection *conn, | 
| @@ -284,7 +277,7 @@ static int o2cb_cluster_connect(struct ocfs2_cluster_connection *conn) | |||
| 284 | struct dlm_protocol_version fs_version; | 277 | struct dlm_protocol_version fs_version; | 
| 285 | 278 | ||
| 286 | BUG_ON(conn == NULL); | 279 | BUG_ON(conn == NULL); | 
| 287 | BUG_ON(o2cb_stack.sp_proto == NULL); | 280 | BUG_ON(conn->cc_proto == NULL); | 
| 288 | 281 | ||
| 289 | /* for now we only have one cluster/node, make sure we see it | 282 | /* for now we only have one cluster/node, make sure we see it | 
| 290 | * in the heartbeat universe */ | 283 | * in the heartbeat universe */ | 
