diff options
author | Alexander Aring <aahringo@redhat.com> | 2022-11-17 23:11:43 +0100 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2022-11-21 16:45:49 +0100 |
commit | 554d849616769339b9dce833a4830251fc4b91ba (patch) | |
tree | 17a91cbd09f514aec1c6a3cad9fd59282662ea2f /fs/dlm/ast.c | |
parent | fs: dlm: ast do WARN_ON_ONCE() on hotpath (diff) | |
download | linux-554d849616769339b9dce833a4830251fc4b91ba.tar.xz linux-554d849616769339b9dce833a4830251fc4b91ba.zip |
fs: dlm: rename DLM_IFL_NEED_SCHED to DLM_IFL_CB_PENDING
This patch renames DLM_IFL_NEED_SCHED to DLM_IFL_CB_PENDING because
CB_PENDING is a proper name to describe this flag. This flag is set when
callback enqueue will return DLM_ENQUEUE_CALLBACK_NEED_SCHED because the
callback worker need to be queued. The flag tells that callbacks are
currently pending to be called and will be unset if the callback work
for the specific lkb is done. The term need schedule is part of this
time but a proper name is to say that there are some callbacks pending
to being called.
Signed-off-by: Alexander Aring <aahringo@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.com>
Diffstat (limited to 'fs/dlm/ast.c')
-rw-r--r-- | fs/dlm/ast.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/fs/dlm/ast.c b/fs/dlm/ast.c index 7dd072b8ea38..26fef9945cc9 100644 --- a/fs/dlm/ast.c +++ b/fs/dlm/ast.c @@ -45,8 +45,7 @@ void dlm_purge_lkb_callbacks(struct dlm_lkb *lkb) kref_put(&cb->ref, dlm_release_callback); } - /* TODO */ - lkb->lkb_flags &= ~DLM_IFL_NEED_SCHED; + lkb->lkb_flags &= ~DLM_IFL_CB_PENDING; /* invalidate */ dlm_callback_set_last_ptr(&lkb->lkb_last_cast, NULL); @@ -104,8 +103,8 @@ int dlm_enqueue_lkb_callback(struct dlm_lkb *lkb, uint32_t flags, int mode, cb->sb_status = status; cb->sb_flags = (sbflags & 0x000000FF); kref_init(&cb->ref); - if (!(lkb->lkb_flags & DLM_IFL_NEED_SCHED)) { - lkb->lkb_flags |= DLM_IFL_NEED_SCHED; + if (!(lkb->lkb_flags & DLM_IFL_CB_PENDING)) { + lkb->lkb_flags |= DLM_IFL_CB_PENDING; rv = DLM_ENQUEUE_CALLBACK_NEED_SCHED; } list_add_tail(&cb->list, &lkb->lkb_callbacks); @@ -210,7 +209,7 @@ void dlm_callback_work(struct work_struct *work) spin_lock(&lkb->lkb_cb_lock); rv = dlm_dequeue_lkb_callback(lkb, &cb); if (rv == DLM_DEQUEUE_CALLBACK_EMPTY) { - lkb->lkb_flags &= ~DLM_IFL_NEED_SCHED; + lkb->lkb_flags &= ~DLM_IFL_CB_PENDING; spin_unlock(&lkb->lkb_cb_lock); break; } |