1 /* -*- mode: c; c-basic-offset: 8; indent-tabs-mode: nil; -*-
2 * vim:expandtab:shiftwidth=8:tabstop=8:
11 int ldlm_cancel_lru(struct ldlm_namespace *ns, ldlm_sync_t sync);
14 int ldlm_resource_putref_locked(struct ldlm_resource *res);
15 void ldlm_resource_insert_lock_after(struct ldlm_lock *original,
16 struct ldlm_lock *new);
19 void ldlm_grant_lock(struct ldlm_lock *lock, struct list_head *work_list);
21 ldlm_lock_create(struct ldlm_namespace *ns,
22 const struct lustre_handle *parent_lock_handle,
23 const struct ldlm_res_id *,
24 ldlm_type_t type, ldlm_mode_t, ldlm_blocking_callback,
25 ldlm_completion_callback, ldlm_glimpse_callback, void *data,
27 ldlm_error_t ldlm_lock_enqueue(struct ldlm_namespace *, struct ldlm_lock **,
28 void *cookie, int *flags);
29 void ldlm_lock_addref_internal(struct ldlm_lock *, __u32 mode);
30 void ldlm_lock_decref_internal(struct ldlm_lock *, __u32 mode);
31 void ldlm_add_ast_work_item(struct ldlm_lock *lock, struct ldlm_lock *new,
32 struct list_head *work_list);
33 int ldlm_reprocess_queue(struct ldlm_resource *res, struct list_head *queue,
34 struct list_head *work_list);
35 int ldlm_run_bl_ast_work(struct list_head *rpc_list);
36 int ldlm_run_cp_ast_work(struct list_head *rpc_list);
37 int ldlm_lock_remove_from_lru_nolock(struct ldlm_lock *lock);
38 void ldlm_lock_destroy_nolock(struct ldlm_lock *lock);
41 int ldlm_bl_to_thread(struct ldlm_namespace *ns, struct ldlm_lock_desc *ld,
42 struct ldlm_lock *lock);
43 void ldlm_handle_bl_callback(struct ldlm_namespace *ns,
44 struct ldlm_lock_desc *ld, struct ldlm_lock *lock);
47 int ldlm_process_plain_lock(struct ldlm_lock *lock, int *flags, int first_enq,
48 ldlm_error_t *err, struct list_head *work_list);
51 int ldlm_process_extent_lock(struct ldlm_lock *lock, int *flags, int first_enq,
52 ldlm_error_t *err, struct list_head *work_list);
55 int ldlm_process_flock_lock(struct ldlm_lock *req, int *flags, int first_enq,
56 ldlm_error_t *err, struct list_head *work_list);
58 /* ldlm_inodebits.c */
59 int ldlm_process_inodebits_lock(struct ldlm_lock *lock, int *flags,
60 int first_enq, ldlm_error_t *err,
61 struct list_head *work_list);
64 void l_check_ns_lock(struct ldlm_namespace *ns);
65 void l_check_no_ns_lock(struct ldlm_namespace *ns);
67 extern cfs_proc_dir_entry_t *ldlm_svc_proc_dir;
70 struct ptlrpc_service *ldlm_cb_service;
71 struct ptlrpc_service *ldlm_cancel_service;
72 struct ptlrpc_client *ldlm_client;
73 struct ptlrpc_connection *ldlm_server_conn;
74 struct ldlm_bl_pool *ldlm_bl_pool;