summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-11-02Merge cherrypicks of [16074852, 16074853] into sc-qpr1-d-release.android-12.0.0_r32android-12.0.0_r29android-12.0.0_r27android-12.0.0_r21android-12.0.0_r20android-12.0.0_r19android-12.0.0_r18android12-qpr1-d-s3-releaseandroid12-qpr1-d-s2-releaseandroid12-qpr1-d-s1-releaseandroid12-qpr1-d-releaseAndroid Build Coastguard Worker
Change-Id: I32fadccbc4b159436b3e631e762d070843077608
2021-11-02gralloc4: Do not hold reference for dumping in allocatorAnkit Goyal
Dump buffers are only per process and is not available at the allocator level. Gralloc should not be holding reference to that while allocating a buffer. Fix: 199336554 Test: Do not observe leaks in heap profiling Change-Id: If92cffb2db9ee30ab1a5cee0297d066138c60674 (cherry picked from commit 0e8b1d64d8f2c0af750bee90be57ad4022119cde)
2021-11-02gralloc4: Delete the gralloc handle when freeing the bufferAnkit Goyal
Bug: 199336554 Test: Do not observe leaks in heap profiling Change-Id: Iacab8555a1f425d7746fc7ab0937ddf9b1cf23d8 (cherry picked from commit 4ffbe198a4b30112aa2a29f709de0052750b53ca)
2021-10-09Snap for 7808903 from 03316c5e63d1db54ae060c2f4212868e40fcb0dc to ↵Android Build Coastguard Worker
sc-qpr1-d-release Change-Id: I5de06211af6a926f0d1a2afb24dac659b40fedfa
2021-10-08Merge "Maximize the priority of gralloc allocator thread" into sc-qpr1-devAnkit Goyal
2021-10-06Snap for 7796451 from 94d6294954a90c45be554bbea26f12b1a2d94fea to ↵Android Build Coastguard Worker
sc-qpr1-d-release Change-Id: I362f047b7d3c54ec34e2a72c7cf67889005c7d2e
2021-10-05Maximize the priority of gralloc allocator threadAnkit Goyal
Bug: 201933520 Test: Boot to home Change-Id: I125493e6b06436e4daac73c208cd5ca5ab4b68bd
2021-10-04Add plane layout for R8 and RG88 formatsAnkit Goyal
Bug: 197289575 Test: Capture shot from UW camera, notice no failure logs Change-Id: If41bf5501fe5bdb25300b78c8cda34e1dd353645
2021-09-24Add missing 16 alignment constraint of chroma stride for YV12 am: a48bf1aa7ewenchangliu
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/google/gchips/+/15898342 Change-Id: I21a4ec0fa4f2cc2f26bc6dd1abf6d54b17216aba
2021-09-24Add missing 16 alignment constraint of chroma stride for YV12wenchangliu
Exynos encoder need 16 stride alignment for both luma and chroma in YV12. Add 32 stride alignment for luma to ensure we meet the requirement. This change will not impact the decoding case since we use 64 stride alignment by default. Bug: 201012738 Test: run vts -m VtsHalMediaC2V1_0TargetVideoEncTest Change-Id: I7086366bfaf4f589e878c732b30b615034ccfa20
2021-09-17Fix YV12 stride alignment issue am: 313da845bewenchangliu
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/google/gchips/+/15836688 Change-Id: I969df1a67826e84717b9ee24e81358a9532aeb69
2021-09-16Fix YV12 stride alignment issuewenchangliu
For some applications (TikTok, AliExpress, Shopee), the YUV layout is not requested from GraphicBufferMapper API, causing a misalignment if the resolution can't satisfy both 64 and 128 alignments. To prevent luma stride misalignment with GPU stride alignment. The luma plane will maintain the same `stride` size, and the chroma plane will align to `stride/2`. Bug: 199836131 Test: AliExpress/Shopee live streaming Change-Id: Id8dd547ff60dec7be49d777f2a63081923d5a9cf
2021-08-05Merge "Remove getppid call from gralloc mapper" into sc-devTreeHugger Robot
2021-08-05Remove getppid call from gralloc mapperAnkit Goyal
Some of the codec components run in minijail which blocks getppid calls. We should update the rules in codec as well to actually allow this syscall. For now this should work as a WA. Bug: 195608566 Test: Video playback in photos app Change-Id: I63cb1a74ebbef8e1fbc17a05a253f94c9f571402
2021-08-04Merge changes Ib1f3cfda,I3d0f30b0,Ic93aa915 into sc-devTreeHugger Robot
* changes: Commit all gralloc logs to warning on high memory allocation Add delayed logger to allow logging verbose/info logs as warnings Log the calling process's PID
2021-08-04Commit all gralloc logs to warning on high memory allocationAnkit Goyal
Bug: 192821955 Test: Manually verified Change-Id: Ib1f3cfdae6bf5280c5ee85fbbfa11f1e2da7cbdc
2021-08-04Add delayed logger to allow logging verbose/info logs as warningsAnkit Goyal
Bug: 192821955 Test: Manually verified Change-Id: I3d0f30b0dad3a5784659c47ce70e239aff834a7d
2021-08-02Log the calling process's PIDAnkit Goyal
Bug: 192821955 Test: Logcat Change-Id: Ic93aa915d76f10dac0a9084240df8e403497090e
2021-07-27Merge "Replace refcounting functions with buffer free" into sc-devSean Callanan
2021-07-27Replace refcounting functions with buffer freeSean Callanan
libGralloc4Wrapper currently exposes reference retain and free functions which call into Gralloc's internal reference-counting mechanisms. These actually aren't necessary: the only thing that clients need is a function that undoes the effect of importBuffer() on a locally-created buffer. Removed ::retain and ::release, and instead added freeImportedHandle(), which calls freeBuffer(), unregistering the buffer, and then also manually unmaps the buffer's handles (which is necessary because freeBuffer() doesn't normally do that). Bug: 193573573 Test: many photos with rear and front camera Change-Id: Iba339d35279512d75da01388c294e6c2191ede6a
2021-07-27Merge "VendorGraphicBuffer: Add import buffer and free buffer functions" ↵Charlie Chen
into sc-dev
2021-07-27VendorGraphicBuffer: Add import buffer and free buffer functionsCharlie Chen
Bug: b/187279591 Test: video playback(YouTube, Exoplayer), video recording \ 3P Apps recording Change-Id: I72f422f7500cf3a0896f4d491719f2f24da91949 Signed-off-by: Charlie Chen <yuchungchen@google.com>
2021-07-26include: update VendorVideoAPI for CROP info supportTaehwan Kim
Bug: 188737888 Test: atest CtsMediaTranscodingTestCases Signed-off-by: Taehwan Kim <t_h.kim@samsung.com> Change-Id: I5e4819a87ab9cbe2d57e022b103343f8a4204e79
2021-07-22Merge "videoapi: fix bugs at Exynos_dynamic_meta_to_itu_t_t35" into sc-devTreeHugger Robot
2021-07-19Merge "Allow realigning YV12 to satisfy C2's stride assumptions" into sc-devTreeHugger Robot
2021-07-16videoapi: fix bugs at Exynos_dynamic_meta_to_itu_t_t35Byung-Gwan Kang
Bug: 193510942 Test: android.media.cts.DecoderTest#testH265Hdr10PlusMetadata Change-Id: I43d7493325c0e1fbe6f968348cda22ace2a29084 Signed-off-by: Byung-Gwan Kang <bk0917.kang@samsung.com>
2021-07-02Remove build support for gralloc3.Krzysztof Kosiński
All relevant devices use gralloc4 now, so this is dead code. Bug: 174998182 Test: build for affected devices, camera preview Change-Id: I95320a0c787128692728433443ffd5892ee08b65
2021-07-01Decouple metadata operations from implementationAnkit Goyal
Bug: 191912915 Test: Full-range video playback with known calls to set_dataspace Change-Id: I9ee1419922a316f3ce0e303ab46c2e46d1b72fec
2021-07-01Clone validate function to remove dependence upon implementationAnkit Goyal
Bug: 191912915 Test: Smoke test, boot to home Change-Id: Ib3a23b068ae099cc6aa21b615e414bfac38a90bb
2021-06-28Map CPU accessible buffers during importAnkit Goyal
This is a workaround as codec is not locking the buffer before accessing it. Bug: 187145254 Test: CtsMediaV2TestCases Change-Id: Iee8e688d40a404e78447f6f90b001f34566b56a1
2021-06-28Remove deprecated ION calls from referenceAnkit Goyal
Bug: 190688388 Test: Removed a no-op Change-Id: Id3ff97cefda191699a824a8fce4dd2f74c124624
2021-06-21Merge "Lazy map the buffers on lock" into sc-devAnkit Goyal
2021-06-21Lazy map the buffers on lockAnkit Goyal
This potentially should improve the importBuffer calls as not all clients need CPU mapped buffers. This patch needs to be thoroughly tested as there are chances it might break metadata reporting. I did the smoke test and it seems fine. Fix: 190688388 Test: Yet to be tested Change-Id: I2f98b1f9646a1336ded3747d2a24c6851a883d73
2021-06-18Define SBWC sizing macros if UAPI isn't availableSean Callanan
Some older kernels don't have this UAPI. Fall back to a local version if and only if absolutely necessary. Fixes: 191494136 Test: build Change-Id: I76879c009903cf2886cee6cc6d339c9c85d72080
2021-06-19Allow realigning YV12 to satisfy C2's stride assumptionsAnkit Goyal
Fix: 191275214 Test: Video playback using SW decoder Change-Id: Ieec84b51ba2cbf689555262e9ccd180f22df55ad
2021-06-18Merge "vendorgraphicbuffer: add validation on metadata before operating" ↵TreeHugger Robot
into sc-dev
2021-06-15Merge "Revert "gralloc4: limit 64-byte alignment to GPU+camera"" into sc-devWen Chang Liu
2021-06-15vendorgraphicbuffer: add validation on metadata before operatingYichi Chen
The process crashed when it operated metadata on an unimported buffer. To enhance the robustness of the system, the patch creates the check on mali reference to avoid crashing. Bug: 186739698 Test: android.mediav2.cts.EncoderColorAspectsTes Change-Id: Ia9c074dcee0d0f3a8ef18170ea6bce153fa734a5
2021-06-11Merge "Allow GPU to read RAW10 buffers" into sc-devSean Callanan
2021-06-10Allow GPU to read RAW10 buffersAnkit Goyal
Fix: 190074890 Test: Lens viewfinder Change-Id: Ia03cb5a961a7402c0c129d8f1ca10332cc7c19e5
2021-06-09Disable AFBC for RGB_565Sean Callanan
Work around the fact that external hardware buffers with AFBC are color-swapped in Vulkan. Bug: 189467474 Test: Lens mode in Camera app Change-Id: I0d7b225d6de24012000b989d923af72a44c3c929
2021-06-08Merge "gralloc: map camera output yuv to NV21" into sc-devTreeHugger Robot
2021-06-05gralloc: map camera output yuv to NV21Zhijun He
Map camera YUV420_888 to NV21 when the consumer is GPU. It was previously mapped to NV12. Test: Build Bug: 190204149 Change-Id: I174bebb5b8012a11737c0396f031b73917f3cb23
2021-06-03Revert "gralloc4: limit 64-byte alignment to GPU+camera"Sean Callanan
This reverts commit e3a678186d514650cca2e0464c26cb10912e4e72. Reason for revert: All IPs now allow 64-byte alignment. Bug: 188600370 Bug: 184793812 Bug: 185836979 Bug: 188226310 Change-Id: I2b9b20d2f3de7794590a613f40e173e263b487aa
2021-06-03Merge "libvendorgraphicbuffer: add the support of buffer id" into sc-devTreeHugger Robot
2021-05-27Gralloc: allow INTERNAL_Y8 and INTERNAL_YV12 access by CameraYichi Chen
The INTERNAL_Y8 and INTERNAL_YV12 are used by Camera in recording use cases. The patch enables the linear support in camera. Bug: 185281551 Test: Recording with INTERNAL_Y8 buffer allocation Change-Id: Ida5b15736454ee8bc842e0ad8a3ec9eafb93f49a
2021-05-25libvendorgraphicbuffer: add the support of buffer idYichi Chen
Buffer ID is very helpful to track the life cycle of a buffer. The patch extends vendorgraphicbuffer to allow an easy access. Bug: 185958099 Test: Stress test on livewallpaper Change-Id: Ieb1007dded9585afccd5b94c919cc0f50563a037
2021-05-19gralloc4: limit 64-byte alignment to GPU+cameraSean Callanan
Currently, only Camera has been verified to handle 64-byte strides properly when writing buffers for the GPU. Narrow this down and emit an error in the case of problematic usage combinations. Bug: 188226310 Test: play a 480p h.264 video, camera viewfinder, record/play video Change-Id: I7e82394ea40a49018705009da8b7d8aafa4aea26
2021-05-14Add .hash for an aidl_interfaceJeongik Cha
Bug: 187841663 Test: m nothing Change-Id: Ifc2c062f75a2af3bc4b97c89eb446ff80718c074
2021-05-11gralloc4: align buffers for the GPU to 64 bytesSean Callanan
The camera requires 64-byte stride alignment for a variety of formats. Set this alignment if GPU usage is detected. Test: Boot, use viewfinder Bug: 185836979 Bug: 185065640 Bug: 184793812 Change-Id: I96a5abf5465fb583d5f3393dece431d3b60a2cdb