Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
swtpm: cuse: Lock thread_busy_lock reading thread_busy (Coverity)
Coverity is complaining that thread_busy needs to be locked before reading. For consistency reasons now also lock thread_busy before reading it. However, in this case it does not make a difference whether this lock is held when reading thread_busy since file_ops_lock is held when the thread_busy flag is set and when it is read with a call to this function (worker_thread_is_busy). Also while the thread is busy no further commands can be submitted and it can then reset the thread_busy flag without holding the file_ops_lock. Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
- Loading branch information