From cf6e6e2e60972a0d344813d304092f2b5db7ab3f Mon Sep 17 00:00:00 2001 From: Shukla Mradul Date: Fri, 5 May 2017 12:09:11 +0530 Subject: msm8996-common: camera: HAL3: Error occurs while unmapping buffer Issue: STL operation such as erase ,push_back needs to be atomic. List to keep reprocessed meta and buffer is prone to simultaneous access from other part of codes causing STL operations to fail. Fix: Keeping STL operation of list for buffer and meta both in mutex. Change-Id: I8b966ee993a981ae64099093ff131d305f0cca94 --- camera/QCamera2/HAL3/QCamera3Channel.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'camera/QCamera2/HAL3/QCamera3Channel.h') diff --git a/camera/QCamera2/HAL3/QCamera3Channel.h b/camera/QCamera2/HAL3/QCamera3Channel.h index 38b6c81..4495072 100644 --- a/camera/QCamera2/HAL3/QCamera3Channel.h +++ b/camera/QCamera2/HAL3/QCamera3Channel.h @@ -568,6 +568,8 @@ private: int32_t resetToCamPerfNormal(uint32_t frameNumber); android::List mOfflineBuffers; android::List mOfflineMetaBuffers; + Mutex mOfflineBuffersLock; + Mutex mOfflineMetaBuffersLock; int32_t mOfflineBuffersIndex; int32_t mOfflineMetaIndex; uint32_t mFrameLen; -- cgit v1.2.3