Lines Matching full:ls

32 void dlm_add_requestqueue(struct dlm_ls *ls, int nodeid, struct dlm_message *ms)  in dlm_add_requestqueue()  argument
43 e->recover_seq = ls->ls_recover_seq & 0xFFFFFFFF; in dlm_add_requestqueue()
47 mutex_lock(&ls->ls_requestqueue_mutex); in dlm_add_requestqueue()
48 list_add_tail(&e->list, &ls->ls_requestqueue); in dlm_add_requestqueue()
49 mutex_unlock(&ls->ls_requestqueue_mutex); in dlm_add_requestqueue()
63 int dlm_process_requestqueue(struct dlm_ls *ls) in dlm_process_requestqueue() argument
69 mutex_lock(&ls->ls_requestqueue_mutex); in dlm_process_requestqueue()
72 if (list_empty(&ls->ls_requestqueue)) { in dlm_process_requestqueue()
73 mutex_unlock(&ls->ls_requestqueue_mutex); in dlm_process_requestqueue()
77 e = list_entry(ls->ls_requestqueue.next, struct rq_entry, list); in dlm_process_requestqueue()
78 mutex_unlock(&ls->ls_requestqueue_mutex); in dlm_process_requestqueue()
82 log_limit(ls, "dlm_process_requestqueue msg %d from %d " in dlm_process_requestqueue()
88 dlm_receive_message_saved(ls, &e->request, e->recover_seq); in dlm_process_requestqueue()
90 mutex_lock(&ls->ls_requestqueue_mutex); in dlm_process_requestqueue()
94 if (dlm_locking_stopped(ls)) { in dlm_process_requestqueue()
95 log_debug(ls, "process_requestqueue abort running"); in dlm_process_requestqueue()
96 mutex_unlock(&ls->ls_requestqueue_mutex); in dlm_process_requestqueue()
116 void dlm_wait_requestqueue(struct dlm_ls *ls) in dlm_wait_requestqueue() argument
119 mutex_lock(&ls->ls_requestqueue_mutex); in dlm_wait_requestqueue()
120 if (list_empty(&ls->ls_requestqueue)) in dlm_wait_requestqueue()
122 mutex_unlock(&ls->ls_requestqueue_mutex); in dlm_wait_requestqueue()
125 mutex_unlock(&ls->ls_requestqueue_mutex); in dlm_wait_requestqueue()
128 static int purge_request(struct dlm_ls *ls, struct dlm_message *ms, int nodeid) in purge_request() argument
132 /* the ls is being cleaned up and freed by release_lockspace */ in purge_request()
133 if (!ls->ls_count) in purge_request()
136 if (dlm_is_removed(ls, nodeid)) in purge_request()
147 if (!dlm_no_directory(ls)) in purge_request()
153 void dlm_purge_requestqueue(struct dlm_ls *ls) in dlm_purge_requestqueue() argument
158 mutex_lock(&ls->ls_requestqueue_mutex); in dlm_purge_requestqueue()
159 list_for_each_entry_safe(e, safe, &ls->ls_requestqueue, list) { in dlm_purge_requestqueue()
162 if (purge_request(ls, ms, e->nodeid)) { in dlm_purge_requestqueue()
167 mutex_unlock(&ls->ls_requestqueue_mutex); in dlm_purge_requestqueue()