diff options
author | Joseph Qi <[email protected]> | 2014-12-18 16:17:34 -0800 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2014-12-18 19:08:11 -0800 |
commit | 1e5895816030eaadb952c89eb9f4054e5c0082c3 (patch) | |
tree | 00476a915aed960c74bef81f8541cc88eb2899e8 /lib/memory-notifier-error-inject.c | |
parent | f62f12b3a426c8f65b10011b1ec40ba4277cbf5f (diff) |
ocfs2/dlm: fix race between dispatched_work and dlm_lockres_grab_inflight_worker
Commit ac4fef4d23ed ("ocfs2/dlm: do not purge lockres that is queued for
assert master") may have the following possible race case:
dlm_dispatch_assert_master dlm_wq
========================================================================
queue_work(dlm->quedlm_worker,
&dlm->dispatched_work);
dispatch work,
dlm_lockres_drop_inflight_worker
*BUG_ON(res->inflight_assert_workers == 0)*
dlm_lockres_grab_inflight_worker
inflight_assert_workers++
So ensure inflight_assert_workers to be increased first.
Signed-off-by: Joseph Qi <[email protected]>
Signed-off-by: Xue jiufei <[email protected]>
Cc: Joel Becker <[email protected]>
Reviewed-by: Mark Fasheh <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'lib/memory-notifier-error-inject.c')
0 files changed, 0 insertions, 0 deletions