CERROR("%s: Can't allocate new meta-sequence, rc %d\n",
seq->lcs_name, rc);
return rc;
- } else {
- CDEBUG(D_INFO, "%s: New range - "DRANGE"\n",
- seq->lcs_name, PRANGE(&seq->lcs_space));
}
+ CDEBUG(D_INFO, "%s: New range - "DRANGE"\n",
+ seq->lcs_name, PRANGE(&seq->lcs_space));
} else {
rc = 0;
}
else
spin_lock(&stats->ls_lock);
return 1;
- } else {
- return stats->ls_biggest_alloc_num;
}
+ return stats->ls_biggest_alloc_num;
}
}
DEBUG_REQ(D_NET, req, "processing error (%d)", rc);
req->rq_status = rc;
return ptlrpc_send_error(req, 1);
- } else {
- DEBUG_REQ(D_NET, req, "sending reply");
}
+ DEBUG_REQ(D_NET, req, "sending reply");
return ptlrpc_send_reply(req, PTLRPC_REPLY_MAYBE_DIFFICULT);
}
prev->mode_link = &mode_end->l_sl_mode;
prev->policy_link = &req->l_sl_policy;
return;
- } else if (lock->l_resource->lr_type == LDLM_IBITS) {
+ }
+
+ if (lock->l_resource->lr_type == LDLM_IBITS) {
for (;;) {
policy_end =
list_entry(lock->l_sl_policy.prev,
prev->mode_link = &mode_end->l_sl_mode;
prev->policy_link = &req->l_sl_policy;
return;
- } else {
- LDLM_ERROR(lock,
- "is not LDLM_PLAIN or LDLM_IBITS lock");
- LBUG();
}
+
+ LDLM_ERROR(lock, "is not LDLM_PLAIN or LDLM_IBITS lock");
+ LBUG();
}
/* insert point is last lock on the queue,
if (thread_test_and_clear_flags(thread, SVC_STOPPING))
break;
- else
- thread_test_and_clear_flags(thread, SVC_EVENT);
+ thread_test_and_clear_flags(thread, SVC_EVENT);
}
thread_set_flags(thread, SVC_STOPPED);
if (tmp & 1) {
if (quit)
break;
- else
- quit = 1;
+ quit = 1;
shift = 0;
}
tmp >>= 1;
if (IS_ERR(c)) {
CDEBUG(D_INFO, "alloc capa failed!\n");
return PTR_ERR(c);
- } else {
- c->c_capa = *capa;
- *oc = c;
- return 0;
}
+
+ c->c_capa = *capa;
+ *oc = c;
+ return 0;
}
static inline int mdc_queue_wait(struct ptlrpc_request *req)
if (env != NULL) {
if (!cl_io_is_going(env))
return env;
- else {
- cl_env_put(env, &nest->cen_refcheck);
- nest->cen_cookie = cl_env_reenter();
- }
+ cl_env_put(env, &nest->cen_refcheck);
+ nest->cen_cookie = cl_env_reenter();
}
env = cl_env_get(&nest->cen_refcheck);
if (IS_ERR(env)) {
loghandle->lgh_last_idx < LLOG_BITMAP_SIZE(llh) - 1) {
up_read(&cathandle->lgh_lock);
return loghandle;
- } else {
- up_write(&loghandle->lgh_lock);
}
+ up_write(&loghandle->lgh_lock);
}
up_read(&cathandle->lgh_lock);
if (loghandle->lgh_last_idx < LLOG_BITMAP_SIZE(llh) - 1) {
up_write(&cathandle->lgh_lock);
return loghandle;
- } else {
- up_write(&loghandle->lgh_lock);
}
+ up_write(&loghandle->lgh_lock);
}
CDEBUG(D_INODE, "use next log\n");
/* It is from enqueue RPC reply upcall for
* updating state. Do not re-enqueue. */
return -ENAVAIL;
- else
- olck->ols_state = OLS_NEW;
+ olck->ols_state = OLS_NEW;
} else {
LASSERT(lock->cll_error);
return lock->cll_error;
if (client->cl_import->imp_state == LUSTRE_IMP_FULL &&
client->cl_avail_grant > brw_size)
return 1;
- else
- osc_update_next_shrink(client);
+
+ osc_update_next_shrink(client);
}
return 0;
}
ldlm_lock_decref(lockh, mode);
LDLM_LOCK_PUT(matched);
return -ECANCELED;
- } else if (osc_set_lock_data_with_check(matched, einfo)) {
+ }
+
+ if (osc_set_lock_data_with_check(matched, einfo)) {
*flags |= LDLM_FL_LVB_READY;
/* addref the lock only if not async requests and PW
* lock is matched whereas we asked for PR. */
ldlm_lock_decref(lockh, einfo->ei_mode);
LDLM_LOCK_PUT(matched);
return ELDLM_OK;
- } else {
- ldlm_lock_decref(lockh, mode);
- LDLM_LOCK_PUT(matched);
}
+
+ ldlm_lock_decref(lockh, mode);
+ LDLM_LOCK_PUT(matched);
}
no_match:
thread_is_stopping(thread) ||
thread_is_event(thread),
&lwi);
- if (thread_test_and_clear_flags(thread, SVC_STOPPING)) {
+ if (thread_test_and_clear_flags(thread, SVC_STOPPING))
break;
- } else {
- /* woken after adding import to reset timer */
- thread_test_and_clear_flags(thread, SVC_EVENT);
- }
+ /* woken after adding import to reset timer */
+ thread_test_and_clear_flags(thread, SVC_EVENT);
}
}