diff options
| author | Chien-Yu Chen <cychen@google.com> | 2015-08-12 16:46:24 -0700 | 
|---|---|---|
| committer | Chien-Yu Chen <cychen@google.com> | 2015-08-12 17:31:03 -0700 | 
| commit | c96ac8dfcae66a45b7ae67b82dabdf19f60f859d (patch) | |
| tree | e6c6e01b854fc40c4f66805df6c661b41c5b034c /services/camera | |
| parent | 09da86913ca97d7a818a8917b6601527e5e18a24 (diff) | |
| download | frameworks_av-c96ac8dfcae66a45b7ae67b82dabdf19f60f859d.zip frameworks_av-c96ac8dfcae66a45b7ae67b82dabdf19f60f859d.tar.gz frameworks_av-c96ac8dfcae66a45b7ae67b82dabdf19f60f859d.tar.bz2  | |
Camera3Device: Relax InFlightMap size check
Relax InFlightMap size check for high speed configurations to
allow more pending capture requests.
Bug: 23162274
Change-Id: I955fe9a0754f0daed001f4a2b34ccb50f2465a11
Diffstat (limited to 'services/camera')
| -rw-r--r-- | services/camera/libcameraservice/device3/Camera3Device.cpp | 6 | ||||
| -rw-r--r-- | services/camera/libcameraservice/device3/Camera3Device.h | 4 | 
2 files changed, 8 insertions, 2 deletions
diff --git a/services/camera/libcameraservice/device3/Camera3Device.cpp b/services/camera/libcameraservice/device3/Camera3Device.cpp index 3afbd89..5d7423c 100644 --- a/services/camera/libcameraservice/device3/Camera3Device.cpp +++ b/services/camera/libcameraservice/device3/Camera3Device.cpp @@ -2067,8 +2067,12 @@ void Camera3Device::removeInFlightRequestIfReadyLocked(int idx) {      // Sanity check - if we have too many in-flight frames, something has      // likely gone wrong -    if (mInFlightMap.size() > kInFlightWarnLimit) { +    if (!mIsConstrainedHighSpeedConfiguration && mInFlightMap.size() > kInFlightWarnLimit) {          CLOGE("In-flight list too large: %zu", mInFlightMap.size()); +    } else if (mIsConstrainedHighSpeedConfiguration && mInFlightMap.size() > +            kInFlightWarnLimitHighSpeed) { +        CLOGE("In-flight list too large for high speed configuration: %zu", +                mInFlightMap.size());      }  } diff --git a/services/camera/libcameraservice/device3/Camera3Device.h b/services/camera/libcameraservice/device3/Camera3Device.h index 140da98..2026d7a 100644 --- a/services/camera/libcameraservice/device3/Camera3Device.h +++ b/services/camera/libcameraservice/device3/Camera3Device.h @@ -153,9 +153,11 @@ class Camera3Device :    private:      static const size_t        kDumpLockAttempts  = 10;      static const size_t        kDumpSleepDuration = 100000; // 0.10 sec -    static const size_t        kInFlightWarnLimit = 20;      static const nsecs_t       kShutdownTimeout   = 5000000000; // 5 sec      static const nsecs_t       kActiveTimeout     = 500000000;  // 500 ms +    static const size_t        kInFlightWarnLimit = 20; +    static const size_t        kInFlightWarnLimitHighSpeed = 256; // batch size 32 * pipe depth 8 +      struct                     RequestTrigger;      // minimal jpeg buffer size: 256KB + blob header      static const ssize_t       kMinJpegBufferSize = 256 * 1024 + sizeof(camera3_jpeg_blob);  | 
