summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* flo: Restoring XTRA GPS assistanceHEADo8.1Wyatt Riley2018-06-171-3/+3
| | | | | | | | | | | | Pointing the base config.xml to XTRA v3 and removing the redundant overlays Bug: 36356863 Test: Fast GPS fix after delete all on Angler, and build confirmation on Bullhead's identical fix. Change-Id: I255b864808dc1b59fde3b2e013335ad81c3ef0e6
* flo: Xtra Fixes - https, version check & version 3Wyatt Riley2018-06-171-3/+12
| | | | | | | | | | | | | | Tells Qualcomm GPS hardware to: 1) Use https 2) Use the more secure version 3 file 3) Check that the XTRA file version downloaded matches the version expected - i.e. the more secure (signed) version 3 Test: Tested live on device, on nyc-mr1 Bug: 31470303 Change-Id: Ib8b3494d622d760e349cac03bad15faaf0477093
* flo: Add carrier specific GPS configurationsHyejin Kim2018-06-171-0/+19
| | | | Change-Id: I901bbcb59f20d46861e5a78171d18dd3105cf8ce
* flo: Migrating XTRA from gpsonextra.net to cloud based izatcloud.netPandari Sabhapathi2018-06-171-3/+3
| | | | | | | | | | | | | | *Added logic to remove xtra1.gpsonextra.net from URLs received from modem *Added logic to override modem URLs with those configured in gps.conf *Replaced all instances of xtra{1,2,3}.gpsonextra.net domain URLs in gps.conf with xtrapath{1,2,3}.izatcloud.net URLs. *Replaced all commented instances of xtra.bin in gps.conf with xtra2.bin. CRs-fixed: 643816 Change-Id: I803b26bce22f06910dcaa1ee057902b9381667bf
* flo: Restore gps.conf from stockArtem Borisov2018-06-172-0/+95
| | | | | | Somehow it got removed during 14.1 bringup... Change-Id: I3cc9ca348a19936400fa56887ecb6ef4b28898bc
* flo: Inform Trust about legacy encryption supportBruno Martins2018-06-171-0/+4
| | | | | | | * Encryption causes noticeable performances loss, because HW crypto is not suported. Change-Id: I4336c0cd050584020780d8ff97f454e40c7e6125
* Revert "flo: Build Snap camera"Artem Borisov2018-06-171-1/+0
| | | | | | | | | Snap doesn't go very well with our new camera hal. Let's use glorious Camera2 instead. This reverts commit 5547916083919ad0e5dfd045c40cc112cf9d7a7b. Change-Id: I799b852b4f51bd8929121701fd6fc32bd89bc717
* flo: sepolicy: Resolve cameraserver text relocationsArtem Borisov2018-06-171-0/+1
| | | | Change-Id: I0366948280f701187e52ead2e0a23fd8eb53e4ac
* flo: Define vendor security patch levelArtem Borisov2018-06-171-0/+3
| | | | | | Taken from the latest 6.0.1 (MOB30X) factory image. Change-Id: Iac499c012814196194b83ef32f6d590e0f07daf1
* Revert "flo: build camera HAL1"Artem Borisov2018-06-171-1/+1
| | | | | | This reverts commit 762539b3d413d9f670374b7af8bb9cdeed97d152. Change-Id: Ie56f294e09951581f6e5048de4f1a69b8ab4b805
* camera: fix/hack static metadata reportingDaniel Jarai2018-06-172-151/+609
| | | | | | | | | | | | | | Unfortunately, our camera blobs are too old to implement camera HAL 3.2 properly. These hacks fix most camera functionality with HAL 3.2, but they're not exactly clean... Some pieces are based on the hammerhead HAL. This isn't passing CTS, but it's not too far away. Sadly, in the foreseeable future, I won't have time to clean it up... Change-Id: Iff4f0f25fe767e498db6e56fc2f47a13c4a97364 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* QCamera3: Scene Mode FixShuzhen Wang2018-06-171-2/+3
| | | | | | | | | | Map FACE_PRIORITY mode as Auto Scene Mode, so that we don't have undefined behavior. Bug: 11045793 Change-Id: Iaa7a30eef902c2ca0a700c498f88b7c77aa441fa Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Avoid starting streams twiceMansoor Aftab2018-06-171-0/+5
| | | | | | | | | | | | | | | | | The start method of some streams (most notably the metadata) could be called twice. This scenario should be handled by returning immediatly and avoiding the initialization of new threads and resources. This change is authored by Emilian Peev <epeevs@codeaurora.org> Bug: 18258028 Bug: 17912331 Change-Id: Ife6613bdca069bc63193802e0bb88273e63998f9 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Validate request rate based on metadata rather than buffersMansoor Aftab2018-06-172-5/+7
| | | | | | Bug: 11011342 Change-Id: I68c054027bb8b39ad30b0a3ca932b6cb888409c9 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Rework flush functionalityShuzhen Wang2018-06-172-75/+108
| | | | | | | | | | | | | | | | | | We can have two output buffers per request for cases like ZSL. When doing flush the process capture result has to be called only once for each frame number and should contain all cancelled output buffers. Doing this on a buffer basis will result in unexpected frame number errors in the upper framework. The buffers should be again grouped depending on their frame number and returned back in single 'process_capture_result()' call. Bug: 17113762 Change-Id: I422e86debb2d8e5e8bca1d402479e42f02d915a4 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Initialize capture result structure before useMansoor Aftab2018-06-171-0/+4
| | | | | | | | | memset camera3_capture_result_t data structure before using it in HAL. Bug: 16132385 Change-Id: I0a55cf47984c1d1413b9a492d79543c47ff5bc23 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Fix invalid file description checkShuzhen Wang2018-06-176-24/+30
| | | | | | | | | | | 0 is a valid file descriptor. Fix the code for checking valid file descriptor. This is a precautionary change. Bug: 17113762 Change-Id: I65b206254eb63d888049b6daf650204b13afa444 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Remove redundant Buffer tracking structureMansoor Aftab2018-06-174-15/+26
| | | | | Change-Id: I972e0868d08384209fe413fd5398c2e113a3fab0 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Remove unnecessary heap allocationsShuzhen Wang2018-06-172-120/+32
| | | | | | | | | | Remove unneeded heap allocations that could lead to future leaks. Bug: 13301331 Change-Id: Ib7671b88ddbe36575beaa8418c147ffaba3ef9de Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* camera: remove PARTIAL_RESULT supportDaniel Jarai2018-06-171-2/+4
| | | | | Change-Id: Ic69c493b83c5a6ce4e5ba33d71208466bc2e73e3 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Remove buffer registration phaseShuzhen Wang2018-06-1711-363/+476
| | | | | | | | | | | Instead of registering all buffers upfront all client buffers are registered on-the-fly during process capture requests. Bug: 13301331 Change-Id: I6230829f9ac8eb1c7ddc26f2408dc948ce7b4682 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* camera: fix ANDROID_SCALER_AVAILABLE_MIN_FRAME_DURATIONSDaniel Jarai2018-06-171-1/+1
| | | | | | | Our old camera blobs don't report this correctly, so let's hardcode. Change-Id: I38b814a3f99a0793cb8084a53844d587cedb0378 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Set register_stream_buffers to NULLShuzhen Wang2018-06-171-1/+1
| | | | | | Bug: 13301331 Change-Id: I6f2ffb7595fcd25d56b1fe14f6e21326a329533e Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Add new static metadataMansoor Aftab2018-06-171-5/+212
| | | | | | | | | | | Add the new static metadata for 3.2 Bug: 13653652, 13516241, 13528518, 13527179, 13527177, 12958238, 12958122, 12958122, 12957740, 12958062, 12957596, 12957732, 12957688, 12957685, 12958201, 12957788, 13527175 Change-Id: Idb2ed5e963683556a0066b77e30bd160b1eb0e29 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Fix memory leak during frame reprocessShuzhen Wang2018-06-171-0/+1
| | | | | | | | | | | | The 'streamCbRoutine()' method of the reprocess channel receive a camera super frame that was previously allocated on heap and must release it after exit Bug: 13301331 Change-Id: Ie90f6b4f945f4b7fcc6c46d541871e44c3f6943b Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera2: Add flash.available tag with new metadata specShuzhen Wang2018-06-171-2/+5
| | | | | | Bug: 12957430 Change-Id: I7c82a7821606dc95310000ea7ea4230454b69403 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Make maximum thumbnail size to be 4x3Shuzhen Wang2018-06-171-2/+7
| | | | | | | | | | This aligns with most max resolution picture size aspect ratio. Also make the supported thumbnail sizes to be in increasing order per spec. Bug: 12101500 Change-Id: I5ed791f08225605b3a538039a05576da458b9109 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Only use Plain Old Data for global variableShuzhen Wang2018-06-171-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a shared library is loaded, the order in which its global variables is not defined. For example, for case like below: A a; int *ptr = NULL; Class A { A() { if (ptr == NULL) { //do this; } else { // do that; } } }; ptr could be initialized before or after A, which causes the behavior of A's constructor to be different. The fix is to use Plain Old Data (integer, float, char, or pointer) as global variable, and defer instantiation of class instance to runtime. Bug: 11822202 Change-Id: I806c527f06e19fc44e880d9a536ee7a060b4fa4f Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Upgrade Camera device version to 3.2Mansoor Aftab2018-06-171-2/+2
| | | | | | Bug: 13609405 Change-Id: I4443126b5fc191798750da73cb750e5b98766e97 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Clean up ALOGE calls in non-error conditionsShuzhen Wang2018-06-1710-38/+36
| | | | | | | | Use ALOGI/ALOGD instead. Bug: 12489802 Change-Id: Id7fc9147395af3a9a0fe135d1017a155aad174fb Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Implement flush call for version 3.1Shuzhen Wang2018-06-173-22/+235
| | | | | | | | | | | | | | | | | | | | | When flush is called, HAL drops all inflight requests and buffers as soon as possible. HAL implements this feature by: 1. Streams off all active streams, 2. Calls process_capture_result with ERROR_BUFFER for pending requests for which metadata is generated, but not all buffers are filled, and 3. Calls process_capture_result with ERROR_RESULT for pending requests for which metadata is not generated yet. This change also fixes a bug in mm-camera-interface so that queued_buffer_count is reset during reg_buf. Bug: 9758581 Change-Id: Ibcb5dc52faf8d50f781ef514e4c79185311dafce Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Reduce log spamShuzhen Wang2018-06-172-6/+6
| | | | | | Bug: 11431304 Change-Id: I9f641188d3ae5c131ed1cd687300cc2b8ccd380e Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Unblock capture_request in correct conditionShuzhen Wang2018-06-172-241/+296
| | | | | | | | | | | | | | | | Previously we were only checking max buffer dequeued when metadata callback happens. HAL needs to do the same check in buffer callback. This change also breaks down the captureResultCb() function which is long overdue. This should help improve latency and performance because we are unblocking capture_request early. Bug: 11011342 Change-Id: I37a37e78a3534f780b4a92e46ab21f5ae78b5329 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Fixes instability during camera closeShuzhen Wang2018-06-172-4/+24
| | | | | | | | | | | - As per documentation 'camera3_stream_t' objects are owned by the framework and will be freed before camera close. These objects are not to be used when the Hal destructor is invoked. BUG: 10689446 Change-Id: I1409319e7340846ca574b3987132a0ca3bbae8e9 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Set name for stream process threadShuzhen Wang2018-06-171-0/+1
| | | | | | | | Name the stream process thread in HAL Bug: 10609699 Change-Id: Ib272cd237fea8ad9e27994352e7acc7a1f56551c Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Fix memory leaks during preview start/stopShuzhen Wang2018-06-171-0/+3
| | | | | | | | | | - The array for holding registerd buffer handles is not released during camera close. Also the metadata frame allocated in 'QCamera3Stream' needs to be freed after returning to camera. Change-Id: Idb9e278583382e08df9c64d20d7f1c2af2488071 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Fix rapid ZSL snapshotsMansoor Aftab2018-06-173-18/+27
| | | | | | | | | | -In case of rapid back to back snapshots framework reuses ZSL YUV frame -Remove code in HAL which assumes that once a buffer is passed as input it will not be used again Change-Id: I72a0f527de99b96508c7020455a47bfe754d9df4 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Set extra usage flags for video stream buffersShuzhen Wang2018-06-173-11/+72
| | | | | | | | | | | For video stream buffers, set READ_RARELY and WRITE_RARELY usage flags so that gralloc may make them uncached. Code cleanup Bug: 10328870 Change-Id: If3bbbbb0976266f69962db7df568c763dad488aa Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Enable livesnapshot for zslMansoor Aftab2018-06-172-24/+29
| | | | | | | Ensure that metadata is handled correctly for different ZSL usecases. Change-Id: Ic521f54b973535384cbc2ec94facea3a3f326648 Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Add reprocess path for ZSLMansoor Aftab2018-06-176-49/+194
| | | | | | | | Add the reprocess path for ZSL to enable WNR, ASF and rotation reprocess Change-Id: I132be710e5fe1cc1436626679a7f533f73f9ae0a Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
* Camera3: Name HAL threadsMansoor Aftab2018-06-179-0/+40
| | | | | | | | Name the HAL threads to make debugging easier Bug: 10609699 Change-Id: Ic953947eca7e4fde7c87bd7c890d1811cc3ff2fb
* QCamera2: Sync stream stop with poll updatesShuzhen Wang2018-06-173-2/+39
| | | | | | | | | | | | | | | | | | | | | The stream command thread will be released as part of the stream stop but the channel poll thread can still run until the channel is released. In this case the synchronous poll delete during stream stop can fail if the asynchronous poll version got triggered immediately before that. The stop will proceed and release the stream command thread resources before the async poll update could be processed. The poll thread could then try and access the command thread resources resulting in a crash. The failing sync poll delete should be handled by syncing to the poll thread again and allowing any previously pending async updates to be processed before releasing any resources. Bug: 14028116 CRs-Fixed: 629996 Change-Id: Ib6252445731d05c01a59503b3cfe70ef089a4ffd
* QCamera2: More informative error message for qbuf/dqbufShuzhen Wang2018-06-171-3/+4
| | | | | Bug: 14028116 Change-Id: I40c819f8bdfd4bd66ead9379e871f8a2fd6a5074
* Camera3: Increase retry count when opening cameraShuzhen Wang2018-06-172-2/+2
| | | | | | | | | | | | This takes care of cases where mm-qcamera-daemon takes a long time to launch. get_camera_info depends on mm-qcamera-daemon being up and running to work. In the worse case, get_camera_info will be held up by HAL for 200ms. Bug: 10577806 Change-Id: I7068b0f60bf75c407b603f4e0a0bbb19b8f51f0c
* Camera3: Fix thumbnail stretch issueAjay Dudani2018-06-171-8/+12
| | | | | | | | | If image is already rotated by post proc, swap the thumbnail destination buffer width and height before giving it to the encoder Change-Id: I328a762887b469fc88d298c131cde356dc2dd03f (cherry picked from commit ab93af6714041141d8a66e6e2c921097e1341a08)
* flo: Use proper paths for vidc firmwareArtem Borisov2018-04-201-7/+7
| | | | Change-Id: Ie4a3a0cb250fcfe9f5ded110b520a669b87aea3b
* flo: Fix vendor's mismatchZipsnet2018-04-111-1/+2
| | | | Change-Id: I2f98e53f2091b0caf91603c732ff6bb62b0c575a
* flo: Disable ZRAMArtem Borisov2018-03-312-9/+0
| | | | | | | | | | | Meh. Even with the relatively good kernel impl this doesn't work really good for us. New zram driver doesn't correlate very well with our ancient code in mm. This leads to a noticeable performance degradation when the kernel starts to swap the pages into zram disk and device becomes a laggy mess after several days of uptime even without very active usage. Change-Id: Ib885bcfe3961bb76ec72985a5b51f86234a6a081
* flo: adapt to DU hwkeysAli B2018-03-061-0/+14
| | | | Change-Id: Ic911ef6000147f345cae499877305d5ac3e37986
* flo & deb: denial FixZips2018-02-183-1/+12
| | | | Change-Id: Icc5e5f7cc8adadbdf781a43d95ebeb06e9a15487