[libcamera-devel,v3,0/5] Apply clang thread safety annotation libcamera-core and v4l2
mbox series

Message ID 20221103132041.64644-1-umang.jain@ideasonboard.com
Headers show
Series
  • Apply clang thread safety annotation libcamera-core and v4l2
Related show

Message

Umang Jain Nov. 3, 2022, 1:20 p.m. UTC
(Original cover letter by Hiro)
This applies clang thread safety annotations to libcamera/base, and
libcamera/camera_manager and v4l2. I cannot annotate Signal and some
variables in thread.cpp is because the used Mutexes are invisible
from their header files.

Changes in v3:
- Address Laurent's reviews from v2
  - No functional changes, improve readability by reflowing statements
- Remove TSA for exitCode_ from 2/5
- Protect cameras_ on cleanup() by taking a lock in 3/5 so that TSA
  is satisfied

Hirokazu Honda (5):
  libcamera: base: semaphore: Apply clang thread safety annotation
  libcamera: base: thread: Apply clang thread safety annotation
  libcamera: camera_manager: Apply clang thread safety annotation
  v4l2: v4l2_camera_proxy: Apply clang thread safety annotation
  v4l2: v4l2_camera: Apply clang thread safety annotation

 include/libcamera/base/semaphore.h | 10 +++++-----
 src/libcamera/base/semaphore.cpp   |  4 +++-
 src/libcamera/base/thread.cpp      | 10 +++++++---
 src/libcamera/camera_manager.cpp   | 24 +++++++++++++++---------
 src/v4l2/v4l2_camera.cpp           |  5 ++---
 src/v4l2/v4l2_camera.h             | 14 ++++++++------
 src/v4l2/v4l2_camera_proxy.h       | 12 +++++++-----
 7 files changed, 47 insertions(+), 32 deletions(-)