Commit Graph

89 Commits

Author SHA1 Message Date
Courtney Goeltzenleuchter d1c08b13d3 Fix Buffer Overflow in Vendor Service display.qservice
Bug: 63145942
Test: adb shell vndservice call display.qservice 36 s16 sdlkfjsadlfkjasdf
Change-Id: I3fdf5ccd2bf4ed0fa980883fefdb57eb5fbfeee7
(cherry picked from commit 4050091844)
2018-07-27 18:43:41 +00:00
Arun Kumar K.R 06b0836470 sdm: Protect unbalanced ROI in dump
Validate right roi before using them in when dumping
the frame information.

Bug: 73253473
Change-Id: Ifa75c83d33f3d76914b47c9c8168eb4061ac5f88
Acked-by: Gousemoodhin Nadaf <gnadaf@codeaurora.org>
2018-04-27 16:04:03 -07:00
Jeff Tinker 3a26d0f124 Merge "hwc2: Handle Gamma2.8" into pi-dev 2018-04-20 21:05:30 +00:00
Jeff Tinker 9eaa38013d Merge "gralloc: Add missing BT601_6_625 handing" into pi-dev 2018-04-20 21:05:27 +00:00
Arun Kumar K.R cefe2e70a0 hwc2: Handle Gamma2.8
Layers with gamma 2.8 were being marked as not supported
and falling back to GPU, report them as supported and
handle them for HW composition

bug:77471420

Test: Reproduce bug scenario. With the CLs, verified both video and audio
work as expected using all the video modes.

Merge from https://partner-android-review.googlesource.com/#/c/1063539

Bug: 77471420
Change-Id: I5a94cbfc1ac9be22a6165803a79f6dca5711db34
Crs-fixed: 2220717
2018-04-19 19:02:22 +00:00
Arun Kumar K.R 253d50c32a gralloc: Add missing BT601_6_625 handing
Add missing BT601_6_625 handing

bug:77471420

Test: Reproduce bug scenario. With the CLs, verified both video and audio
work as expected using all the video modes.

Merge from: https://partner-android-review.googlesource.com/#/c/1063538

Change-Id: I10034f38c8ab2283f13556ddf37bea51e7356a79
CRs-fixed: 2129768
Acked-by: Saurabh Shah <saurshah@codeaurora.org>
2018-04-19 19:01:13 +00:00
Naseer Ahmed 1ff191fed3 hwc2: Skip validation fixes
* Disable skip validation for solid fill during calibration.
* Require validation when the client changes the composition type

Bug: 77925367
CRs-Fixed: 2122072
Change-Id: I9ded200e5c15701f653c73d67c18c41de8278d52
2018-04-18 12:45:46 -07:00
Gousemoodhin Nadaf 530894e77a hwc2: Layer buffer fence fd leak
Close acquire_fence_fd to avoid
fence fd leak.

Bug: 77140352
Change-Id: I32eacdf658f59c21f45955d34dd3de5751badbe4
2018-04-12 09:52:36 -07:00
Chong Zhang c348e7790e Fix logic to use uncached for READ/WRITE_RARELY
bug: 72940776

Change-Id: I76a9abfa6295095fb1f1e8aa15066c79ab1c143b
2018-02-16 10:55:23 -08:00
Naseer Ahmed ef09bce3c4 sdm: Fallback on scRGB layers
We don't know how to handle blending when scRGB layers show up.
Fallback entirely to GPU.

Bug: 72125973
Change-Id: Ib01ac0c920bd34f011f0a4d3e76e71d4c7b036e2
2018-01-29 12:28:14 -08:00
Naseer Ahmed c9bb61606f hwc: Fix request flag reset and Present() bailout
The ClearRequestFlags() method iterates over layer_stack_ instead of
layer_set_. This causes a use-after-free since DestroyLayer() removes
layer from layer_set_ only. Besides that, the method need not be
virtual and has a redundant loop. This change removes the
ClearRequestFlags() method and clears flags in an existing loop.

Present() bails out if layer_set_ is empty or a shutdown is pending.
Since layers could have been destroyed before Present(), ideally
bailing out on re-validation has a higher priority over the rest.

Bug: 71538967
Change-Id: Ic7b31bbd07a22b8df47fccb2024b3415ab3a559b
CRs-fixed: 2165926
Acked-by:  Saurabh Shah <saurshah@codeaurora.org>
2018-01-24 16:37:49 -08:00
Chih-Hung Hsieh 6fd2d4bb57 Add -Wno-error to compile with global -Werror.
Bug: 66996870
Test: normal builds.
Change-Id: Iee4ac5f95a2013c5eeac1c061889a593caf0ec36
2018-01-04 12:09:30 -08:00
Mark Salyzyn 96a73c98ee msm8998: deprecate cutils/log.h
Replace cutils/log.h with log/log.h.  Fix up header ordering.

Test: compile
Bug: 34250038
Change-Id: Ib9d9f9919e6a220205014c2f720f7b9633e1bc87
2017-12-19 10:00:55 -08:00
Dan Albert 3d33750fa9 Include what we use.
Test: mma
Bug: None
Change-Id: I0611088b5fe0d7b3c3a7468575abb2756d590091
Exempt-From-Owner-Approval: trivial cleanup
2017-12-12 16:38:59 -08:00
Yi Kong eb53b91b46 Merge "Remove unused variable"
am: 02880f6383

Change-Id: I45affa7c1da94e926788e5af99d88a1253531733
2017-12-05 00:38:45 +00:00
Yi Kong 3a1e361a56 Remove unused variable
Discovered by the upcoming compiler update.

Test: build
Change-Id: Ibe04228dfa03b82f7d0f86cf2c4a3bb90dd68792
2017-12-04 14:24:50 -08:00
Xin Li 43e07f20da Merge commit 'e458e16debbc9068c839ce918b2e039d7efefaed' into HEAD
Change-Id: If5aaf83103dc48a2efa6c242e55e78da18bec6d2
2017-11-13 14:35:40 -08:00
Chih-Hung Hsieh 1cdcad27c9 Use -Werror in hardware/qcom/display
* Add missing include $(LOCAL_PATH)/../common.mk and -Werror.

Bug: 66996870
Test: build with WITH_TIDY=1
Change-Id: I8cd29680bb623343a0dcac9e541b86a339b5a7c7
2017-11-06 16:03:31 -08:00
Naseer Ahmed 7f458d41ff libqdutils: Fix invalid handle access
Bug: 67016926
Change-Id: Ib632bbd6901da3bf24b5bbbe1eebbffde47a4220
2017-10-17 10:15:27 -07:00
Thierry Strudel ef38dc2312 msm8998: Update to C1.07.00.00.375.020
msm8998:  from hardware/qcom/display
  b28746c3d libgrallocutils: Support defaults in AdrenoMemInfo

Test: build, boot, sanity checks
Bug: 65735819
Change-Id: I65db9818f6f5b88d7f3d7b899979ddb6abe9638f
Signed-off-by: Thierry Strudel <tstrudel@google.com>
2017-09-19 15:35:13 +00:00
Jiyong Park fc5a84eb61 Add GLESv3 as a dependency.
The module is using glTexImage3D which is a GLESv3 API. But it didn't
have GLESv3 in its dependency list. In fact, it implicitly relied on the
fact that the symbol exist in GLESv2 as a platform private one.

Test: BOARD_VNDK_VERSION=current m -j libgpu_tonemapper
Change-Id: Ib9ce0e5a54ec5b554d89a090e0224f5c9225966e
2017-08-10 22:12:23 +09:00
Yifan Hong 773b888bdb Fix libcutils private headers
Use cutils/android_filesystem_config.h instead.

Bug: 63135587

Test: m -j
Test: BOARD_VNDK_VERSION=current m -j
Test: mma -j
Test: BOARD_VNDK_VERSION=current mma -j

Change-Id: I4070a4c693509c569dc30c452db68c15e1386f42
2017-08-01 18:50:42 -07:00
Naseer Ahmed efa414aa12 hwc2: Fix color mode lock
am: 9bb6568f16

Change-Id: I7ff0578a59e9701902f08c676fe66484a0db7335
2017-07-26 23:25:24 +00:00
Naseer Ahmed 9bb6568f16 hwc2: Fix color mode lock
Bug: 64020849
Change-Id: I2e9386e953ed764eb7f5924ed599a79fb5b3d911
2017-07-26 13:16:38 -07:00
Naseer Ahmed d1d621051f hwc2: Add more tracing
am: c22578f608

Change-Id: I1a38b857b4ded6bad4132970455c3f210bbfdf47
2017-07-25 23:34:58 +00:00
Naseer Ahmed c22578f608 hwc2: Add more tracing
Bug: 63626797
Change-Id: I702e886904ed8823f1b73eeed494fba76f7f469b
2017-07-24 15:29:33 -07:00
Thierry Strudel 1e855334c8 Merge commit '272267430caca35ed8f93afa4fe52f091f3a83b5' into HEAD
Change-Id: I4ff3c0080b7856baabeab3954af4504a3d7c012d
2017-07-24 12:59:53 -07:00
Naseer Ahmed 272267430c msm8998: display: Update to LA.UM.6.4.9
986f06e953 hwc2: Extend GetClientTargetSupport API
68326e2eb3 hwc2: validate display id in SetColorModeById
4436e52a74 gralloc1: Additional checks in release
4d52eb143c hwc2: cursor fixes
5023c503ad hwc2: Partial revert of 82c9033a8b
1933da3aeb sdm: Cleanup unused code, round 2
e85c316234 hwc2: Allow non-atomic execution of validate and present apis
a124ea3639 sdm: Synchronized write of xlogs
c6d27ee1ff sdm: Fixes for Skip Validate feature
768a791ebd hwc2: Check and set CSC only for device layers
4775fc505e gpu_tm: Use vendor module for header includes
a296c8f493 sdm: Change error log to conditional verbose
3f82fca6a9 cec: Calculate buffer length to protect from overflow
82c9033a8b hwc2: Handle corner and error conditions properly.
e2ac3bb4ba gralloc1: Do not do early validation on Release
eaa0a4d697 gralloc1: Do not map metadata in gralloc
b6569c6679 display: Cleanup unused code
3ab38f43fa hwc2: Use CSC information from android dataspace

Bug: 63146977
Bug: 63691933
Bug: 62992393
Bug: 37480806
Change-Id: I1ba2c33e04f637e424355854f32f3c6cdf789a8d
2017-07-21 19:54:59 -07:00
Chia-I Wu bd8cdbdcaa sdm: hwc2: validate display id in SetColorModeById am: cba1cee475
am: 017c58a2ad

Change-Id: I504b64b503635f17a5a66e801b293877a63cb120
2017-07-19 23:09:18 +00:00
Chia-I Wu cba1cee475 sdm: hwc2: validate display id in SetColorModeById
Bug: 63144992
Test: manual vndservice call
Change-Id: I239670334560b9db4ef781aac2612a86ea4363a9
2017-07-19 14:02:05 -07:00
Naseer Ahmed 89c3eb0568 sdm: Synchronized write of xlogs am: e0f39648ed
am: c6942b3c1e

Change-Id: I2860555994214aa49fe03868a7d6e453ef3315a8
2017-07-17 20:52:37 +00:00
Naseer Ahmed e0f39648ed sdm: Synchronized write of xlogs
Make sure xlogs are flushed to the data partition before the dump
function returns.

Bug: 63539182
Change-Id: Ifd18146e3d93efdb140633e36bcc8321bdf4a238
2017-07-17 11:21:14 -07:00
Jiyong Park 165d17febd Build libqdMetaData with BOARD_VNDK_VERSION
The header lib 'display_headers' exports headers under libgralloc1.
However, headers at libgralloc1 is internally using libhardware_headers.
Export this to the clients of display_headers.

Bug: 37342627
Test: BOARD_VNDK_VERSION=current m -j libqdMetaData

Change-Id: I2cdf699468aca3f9142e1ef5e756ec9f040e7a6e
2017-07-14 14:44:03 +09:00
Tri Vo 2ad4b087e0 Build gpu_tonemapper with VNDK.
(partial revert of f1fe88efc1)

Bug: 37342627
Test: cd hardware/qcom/display/msm8998/gpu_tonemapper &&
BOARD_VNDK_VERSION=current mma -j64 -k
Change-Id: I07900345b395c3322ac2ca42b9d907e1f6868760
2017-07-13 18:23:02 +00:00
Naseer Ahmed 634e7b4dac display: Update to AU 269 am: f1fe88efc1
am: 3533a776b5

Change-Id: Icc4c6d0e1aa37bf4b37c1ff4a94bee0613f2de0a
2017-07-13 05:43:21 +00:00
Jayant Chowdhary e54e422cee Build lights.msm8998 with the VNDK.
When the vndk is enabled (BOARD_VNDK_VERSION=current),
vendor libraries must only link against vendor variants
in the build system. This also means that they receive
restricted sets of headers and that automatic global
headers are restricted.

Test: BOARD_VNDK_VERSION=current m -j k lights.msm8998

Bug: 37342627

Change-Id: I300654fbe4774c43a61104b9be0833fd06fa1548
2017-07-10 15:53:15 -07:00
Naseer Ahmed f1fe88efc1 display: Update to AU 269
af20b3030 qdutils: Add dependency on libhardware headers
07a82a250 display: Mark header modules as vendor
596d6789d hwc2: Do not reapply mode if it is the same as before
02f73fd2c sdm: hwc2: Support Skip Validate feature
2174cfe4b sdm: Use sync task utility for hdr tonemapping.
d002e1e90 sdm: Add sync task utility.
ea6921875 sdm: Add factory template for compile time exclusion.
77555e0a1 sdm: Use color metadata if Android framework metadata is not set
13f038dd6 gpu_tonemapper: Tonemap unaligned width and height of source
4a6a02514 hwc2: Add support to disable HDR handling
a58b93ebf hwc: gpu_tonemapper: Create Secure EGL Context
d7aed8703 hwc2: Pass secure flag to GPU tonemapper
3aff84da4 hwc2: Add support for HDR and HWC tonemapping
177e21f29 display: Store and restore the current eglContext
c659af50a gpu_tonemapper: Adjust sample points to maintain linearity
6e37120ce hwc2: Set client target dataspace
dc34aca12 gralloc1: Align buffer size for each layer
8cf3382bc gralloc1: Update client allocated handle behaviour
2d151167f hwc2: Fix compilation issue
40c96cd19 sdm: handle debug data in hw_device
4e520db60 sdm: hwc2: Check for HDR support by Display interface
9a534715b hwc2: Check composition type in SetLayerBuffer
3507a146a sdm: Update xlogs dump
ba5bbd5a9 hwc2: Disable detail enhancer
3a1f7b12a sdm: Save debug logs on pingpong timeout

Bug: 63111041
Bug: 63335893
Change-Id: I645b5d82c73100821879bf03fd5b836dca2d2c63
2017-07-07 11:38:11 -07:00
Jiyong Park 814103ec44 Use header lib instead of using global include path
Header lib is preferred since a set of headers can have internal
dependency to other headers which are in different directories.

Bug: 37342627
Test: BOARD_VNDK_VERSION=current m -j memtrack.msm8998
Change-Id: I19b05ea960ba553eb9bbcd674eb9c50216169cef
2017-06-26 13:49:05 +09:00
Yifan Hong 80f9ff55f7 Mark msm8998 modules LOCAL_VENDOR_MODULE
Test: m -j -k BOARD_VNDK_VERSION=true

Bug: 37342627

Change-Id: Ia32500a8ab329a4cf30b64ae5a7738b1aecec80d
2017-06-20 15:39:32 -07:00
Naseer Ahmed 54b5013036 sdm: hwc2: Check for HDR support by Display interface
Set Output parameters, only if HDR is supported by Display interface.

Bug: 62035971
CRs-Fixed: 2048854
Change-Id: I26ab07bdc8a797ccd16f5c3ac7a68cddb0b97db1
Acked-by: Sushil Chauhan <sushilchauhan@codeaurora.org>
2017-06-13 23:02:17 +00:00
Naseer Ahmed ae4cfb055e gralloc1: Update client allocated handle behaviour
Client allocated handles give us a dup'd fd so we can
retain/release normally.

Change-Id: I0ec7cb6b86cbf23c160a81750144b5ca751c4104
Bug: 62470929
2017-06-12 22:22:00 -07:00
Naseer Ahmed 97d6df6081 msm8998: Update to AU194
Bug: 62470929
Change-Id: I7affe5d42a3acf00f4631600ef56c90be0782792
2017-06-12 22:21:55 -07:00
Vijay Venkatraman 5e937f155e Add libhardware_headers to msm8998 libqdutils
Bug: 33241851
Test: build target and pass CTS
Test: With BOARD_VNDK_VERSION, mma works
Change-Id: I9bccdd9e9c8f35186f0e2aee35ddb75edf3f45b5
2017-06-12 22:19:49 -07:00
Pat Tjin f2977d7036 Revert "msm8998: Update to 07.00.00.279.194"
This reverts commit 7526c3c419.

Change-Id: I1f5f3aa688169c3a663c138660c9500d42d0947a
2017-06-08 19:09:10 +00:00
Thierry Strudel 7526c3c419 msm8998: Update to 07.00.00.279.194
msm8998:  from hardware/qcom/display
  f98f19f6f gralloc1: Support GRALLOC1_CAPABILITY_RELEASE_IMPLY_DELETE
  3a8cf9cec sdm: Handle de-interlacing adjustments in sdm.
  00d3ef111 hwc2: Initialize transform matrix correctly
  2303051fd Revert "gralloc1: Support GRALLOC1_CAPABILITY_RELEASE_IMPLY_DELETE"

Test: build, boot, sanity checks
Bug: 62319031
Change-Id: I7b84cd980f8741d0d02cccac05a52318475b88ed
Signed-off-by: Thierry Strudel <tstrudel@google.com>
2017-06-07 21:14:31 -07:00
Naseer Ahmed a831bfa4d8 sdm: Save debug logs on pingpong timeout.
CRs-Fixed: 2054079
Change-Id: I3a573813b1b69680f51eeaa1e2c88b59543288e6
2017-06-07 14:08:33 -07:00
Naseer Ahmed a62d21ba11 hwc2: Disable detail enhancer
Bug: 37956331
Change-Id: I0e9fc3693b15c1a3c7aaae956281364e3b5cfa88
2017-05-30 14:48:51 -07:00
Naseer Ahmed 41a9743ceb Revert "gralloc1: Support GRALLOC1_CAPABILITY_RELEASE_IMPLY_DELETE"
This reverts commit 043ed03b67688a5807180b00651eea407d6a8b05.
Some EIS clients that use private_handle out of band don't work
correctly with this change. Revert until resolved.

Test: Open cameracorder @60fps, then switch to camera
Change-Id: Ie2d428f64131da9c089bc82578a3c928f078dcae
CRs-Fixed: 2049286
2017-05-21 19:34:38 -07:00
Naseer Ahmed 86f0be319b msm8998: Update display HAL to AU_LINUX_ANDROID_LA.UM.6.4.9.07.00.00.279.156
d0e57317 libmemtrack: Fix fd leak in kgsl function
f4c795824 hwc2: Fixes to find the right display mode
7736da3d6 hwc2: Add dataspace to dump
10c55d8f7 hwc2: Featurize dataspace support
46448c761 hwc2: Fix color mode setting
3bd5933a7 gralloc1: Add additional tracing
85bd493cd sdm: Reduce log severity for modes without attributes
ee517cd4e hwc2: Additional dataspace checks
df807f7a9 hwc2: Fix Hwc2Test.SET_VSYNC_ENABLED_no_callback_no_power
c993df564 hwc2: Fix cursor tests
16489f7fc hwc2: Do not return error if socket is not available
2a41010ef display: Add support to set color mode by ID
b58fcd56f hwc: Do not snprintf in trace unless needed
151591a70 hwc2: Remove power manager dependency
cf2f3d66b Revert "liblight: Add brightness level extension support"
232c50094 libdrmutils: Fix kernel dependency
043ed03b6 gralloc1: Support GRALLOC1_CAPABILITY_RELEASE_IMPLY_DELETE

Change-Id: I6765c7899433a0cb865e7aae092cb0a06adca59a
2017-05-18 12:41:22 -07:00
Thierry Strudel d6edb8b0dc msm8998: Update to 07.00.00.279.143
msm8998:  from hardware/qcom/display
  43af4aee6 Merge "sdm: Fix style errors"
  17ea52ecf Merge "hwc2: Fix side effects of legacy dataspace conversion"
  7cad9a057 sdm: Fix style errors
  f4f5e3cc1 hwc2: Fix side effects of legacy dataspace conversion
  585f2f38d sdm: Fix default panel alignment information
  0310f2783 Merge "sdm: Add attribute support to HWC2"
  c6ec9654b sdm: Add attribute support to HWC2
  857df7dbe sdm: Add support for switch between with SDR and HDR mode
  56e438b46 Merge "gralloc1: Allocate sensor data from ADSP heap"
  195d3cd58 gralloc1: Allocate sensor data from ADSP heap
  1aa4f7cc4 Merge "sdm: color-manager: Clear feature list when add new feature"
  2af43cb9a gralloc1: Do not map buffer in retain
  9ce434daf sdm: color-manager: Clear feature list when add new feature
  034914390 Merge "gralloc1: Remove fb_id"
  56cc86e7b Merge "hwc2: Fix dataspace comparison"
  1644c2bfd gralloc1: Remove fb_id
  f24a6e045 hwc2: Fix dataspace comparison
  b4cbc5ea8 gralloc1: Locking fixes
  05344d848 Merge "hwc2: Default handling for dataspaces"
  7ae6b5c14 Merge "hwc2: Add dump in HWCColorMode"
  dcae83a07 Merge "gralloc1: Support GPU_DATA_BUFFER and SENSOR_DIRECT_DATA"
  dfaae80ed Merge "sdm: Reduce scope of lock in deinit"
  12151c43b gralloc1: Support GPU_DATA_BUFFER and SENSOR_DIRECT_DATA
  e5bccaba4 hwc2: Default handling for dataspaces
  56da254c8 hwc2: Add dump in HWCColorMode
  063bd941f hwc2: Make HWC dump less verbose
  750f665e3 hwc2: Check if we're under max rlimit
  7ad4a5bd4 sdm: Reduce scope of lock in deinit
  95a95294a hwc2: hwc2test fixes
  72ff64287 gralloc1: Fix metadata usage in GetYUVPlaneInfo

Test: build, boot, sanity checks
Bug: 38282057
Change-Id: I36d237cf9ce707b15eb1bc5dc1999aa4205c29c3
Signed-off-by: Thierry Strudel <tstrudel@google.com>
2017-05-18 12:41:18 -07:00