aboutsummaryrefslogtreecommitdiff
path: root/scripts/generate_rust_analyzer.py
diff options
context:
space:
mode:
authorMichal Schmidt <[email protected]>2023-10-27 10:59:35 -0700
committerJakub Kicinski <[email protected]>2023-10-27 15:35:49 -0700
commit5902ee6dc651f4bb536fbc19e654edc7b6d711d2 (patch)
tree426ea9765a6416ebfc1f7bff5426204d9ede6c74 /scripts/generate_rust_analyzer.py
parent77361cb9c1d6587d460215f096590e9d1f75f9f3 (diff)
iavf: simplify mutex_trylock+sleep loops
This pattern appears in two places in the iavf source code: while (!mutex_trylock(...)) usleep_range(...); That's just mutex_lock with extra steps. The pattern is a leftover from when iavf used bit flags instead of mutexes for locking. Commit 5ac49f3c2702 ("iavf: use mutexes for locking of critical sections") replaced test_and_set_bit with !mutex_trylock, preserving the pattern. Simplify it to mutex_lock. Signed-off-by: Michal Schmidt <[email protected]> Reviewed-by: Wojciech Drewek <[email protected]> Tested-by: Rafal Romanowski <[email protected]> Signed-off-by: Jacob Keller <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'scripts/generate_rust_analyzer.py')
0 files changed, 0 insertions, 0 deletions