diff options
author | Alexander Aring <aahringo@redhat.com> | 2024-03-28 16:48:37 +0100 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2024-04-01 20:31:12 +0200 |
commit | 1131f339089bdf7ef7aa0a026bdefe1c9a22e8a1 (patch) | |
tree | b1659d9eef0859d04462bdbd6bb895a8ab7dab54 /fs/dlm | |
parent | dlm: Simplify the allocation of slab caches in dlm_midcomms_cache_create (diff) | |
download | linux-1131f339089bdf7ef7aa0a026bdefe1c9a22e8a1.tar.xz linux-1131f339089bdf7ef7aa0a026bdefe1c9a22e8a1.zip |
dlm: remove lkb from callback tracepoints
Stop using lkb structs in the callback tracepoints so that lkb
references are not needed. This prepares for separating lkb
structs from callbacks.
Signed-off-by: Alexander Aring <aahringo@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.com>
Diffstat (limited to 'fs/dlm')
-rw-r--r-- | fs/dlm/ast.c | 9 | ||||
-rw-r--r-- | fs/dlm/user.c | 9 |
2 files changed, 14 insertions, 4 deletions
diff --git a/fs/dlm/ast.c b/fs/dlm/ast.c index decedc4ee15f..dd7cca3c1472 100644 --- a/fs/dlm/ast.c +++ b/fs/dlm/ast.c @@ -171,6 +171,7 @@ void dlm_callback_work(struct work_struct *work) { struct dlm_lkb *lkb = container_of(work, struct dlm_lkb, lkb_cb_work); struct dlm_ls *ls = lkb->lkb_resource->res_ls; + struct dlm_rsb *rsb = lkb->lkb_resource; void (*castfn) (void *astparam); void (*bastfn) (void *astparam, int mode); struct dlm_callback *cb; @@ -190,14 +191,18 @@ void dlm_callback_work(struct work_struct *work) bastfn = lkb->lkb_bastfn; if (cb->flags & DLM_CB_BAST) { - trace_dlm_bast(ls, lkb, cb->mode); + trace_dlm_bast(ls->ls_global_id, lkb->lkb_id, + cb->mode, rsb->res_name, + rsb->res_length); lkb->lkb_last_bast_time = ktime_get(); lkb->lkb_last_bast_mode = cb->mode; bastfn(lkb->lkb_astparam, cb->mode); } else if (cb->flags & DLM_CB_CAST) { lkb->lkb_lksb->sb_status = cb->sb_status; lkb->lkb_lksb->sb_flags = cb->sb_flags; - trace_dlm_ast(ls, lkb); + trace_dlm_ast(ls->ls_global_id, lkb->lkb_id, + cb->sb_flags, cb->sb_status, + rsb->res_name, rsb->res_length); lkb->lkb_last_cast_time = ktime_get(); castfn(lkb->lkb_astparam); } diff --git a/fs/dlm/user.c b/fs/dlm/user.c index 12a483deeef5..6f99bbeeac9b 100644 --- a/fs/dlm/user.c +++ b/fs/dlm/user.c @@ -805,6 +805,7 @@ static ssize_t device_read(struct file *file, char __user *buf, size_t count, struct dlm_lkb *lkb; DECLARE_WAITQUEUE(wait, current); struct dlm_callback *cb; + struct dlm_rsb *rsb; int rv, ret; if (count == sizeof(struct dlm_device_version)) { @@ -887,12 +888,16 @@ static ssize_t device_read(struct file *file, char __user *buf, size_t count, } spin_unlock(&proc->asts_spin); + rsb = lkb->lkb_resource; if (cb->flags & DLM_CB_BAST) { - trace_dlm_bast(lkb->lkb_resource->res_ls, lkb, cb->mode); + trace_dlm_bast(rsb->res_ls->ls_global_id, lkb->lkb_id, + cb->mode, rsb->res_name, rsb->res_length); } else if (cb->flags & DLM_CB_CAST) { lkb->lkb_lksb->sb_status = cb->sb_status; lkb->lkb_lksb->sb_flags = cb->sb_flags; - trace_dlm_ast(lkb->lkb_resource->res_ls, lkb); + trace_dlm_ast(rsb->res_ls->ls_global_id, lkb->lkb_id, + cb->sb_flags, cb->sb_status, rsb->res_name, + rsb->res_length); } ret = copy_result_to_user(lkb->lkb_ua, |