diff options
author | 2021-03-16 11:31:16 -0400 | |
---|---|---|
committer | 2021-03-17 09:56:44 +0100 | |
commit | 5de2055d31ea88fd9ae9709ac95c372a505a60fa (patch) | |
tree | 627aa968324f0a86a045733abb7721a4f9aca914 /tools/perf/scripts/python/exported-sql-viewer.py | |
parent | Merge tag 'fuse-fixes-5.12-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse (diff) | |
download | wireguard-linux-5de2055d31ea88fd9ae9709ac95c372a505a60fa.tar.xz wireguard-linux-5de2055d31ea88fd9ae9709ac95c372a505a60fa.zip |
locking/ww_mutex: Simplify use_ww_ctx & ww_ctx handling
The use_ww_ctx flag is passed to mutex_optimistic_spin(), but the
function doesn't use it. The frequent use of the (use_ww_ctx && ww_ctx)
combination is repetitive.
In fact, ww_ctx should not be used at all if !use_ww_ctx. Simplify
ww_mutex code by dropping use_ww_ctx from mutex_optimistic_spin() an
clear ww_ctx if !use_ww_ctx. In this way, we can replace (use_ww_ctx &&
ww_ctx) by just (ww_ctx).
Signed-off-by: Waiman Long <longman@redhat.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Acked-by: Davidlohr Bueso <dbueso@suse.de>
Link: https://lore.kernel.org/r/20210316153119.13802-2-longman@redhat.com
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions