webrtc/modules/video_capture
Michael Olbrich a9d497b52d Video capture PipeWire: fix thread and lock annotations
There are two threads involved here, the thread that calls the API
functions and the pipwire main loop. Using one race checker for both is
wrong and triggers aborts.

Use a different race checker for all variables that are used by the
pipewire main loop or guarded against concurrent access with the
thread_loop_lock.

In one case, two RTC_CHECK_RUNS_SERIALIZED() checks are needed, so
enhance the macro to generate unique variable names.

Bug: webrtc:15181
Change-Id: Ib41514eb7aa98fe85d830461aa0c71e42ba821bd
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/326781
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org>
Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#41198}
2023-11-20 18:18:04 +00:00
..
linux Video capture PipeWire: fix thread and lock annotations 2023-11-20 18:18:04 +00:00
test Revert "Disable VideoCaptureTest due to flakyness" 2023-07-17 09:02:44 +00:00
windows In VideoCaptureDS::{Start|Stop}Capture do not lock 2023-06-26 10:13:33 +00:00
BUILD.gn In VideoCaptureImpl and subclasses add thread and lock annotations 2023-06-22 13:34:40 +00:00
DEPS
device_info_impl.cc modules/video_capture: add NV12 support on Linux 2022-11-29 11:59:52 +00:00
device_info_impl.h Remove top-level const from parameters in function declarations. 2022-01-26 11:05:25 +00:00
OWNERS add ilnik as owner of modules/video_capture 2022-05-10 11:06:10 +00:00
raw_video_sink_interface.h Add callback for raw frames for video capture 2023-01-13 09:54:41 +00:00
video_capture.h Move some users to use webrtc::RefCountInterface 2023-11-02 14:45:57 +00:00
video_capture_config.h Reformat the WebRTC code base 2018-06-19 14:00:39 +00:00
video_capture_defines.h Include module_common_types.h only where needed 2019-09-24 08:22:38 +00:00
video_capture_factory.cc Add pipewire/portal video capture support 2023-02-02 17:20:04 +00:00
video_capture_factory.h Build video capture implementation for chromium 2023-02-20 15:29:43 +00:00
video_capture_factory_null.cc Add support for stand-alone Fuchsia build. 2022-05-30 09:24:43 +00:00
video_capture_impl.cc Check ConvertToI420 result for all errors in VideoCaptureImpl::IncomingFrame 2023-09-18 15:15:34 +00:00
video_capture_impl.h In VideoCaptureImpl and subclasses add thread and lock annotations 2023-06-22 13:34:40 +00:00
video_capture_options.cc PipeWire video capture: split portal and PipeWire implementations 2023-05-25 17:04:53 +00:00
video_capture_options.h Use a constant for invalid PipeWire file descriptor 2023-05-26 11:38:49 +00:00