summaryrefslogtreecommitdiff
path: root/sdm/libs/hwc2/hwc_display.cpp
AgeCommit message (Collapse)Author
2019-04-16Merge "sdm: Update the DRM properties only when required"qctecmdr
2019-04-11display: add logs for systrace debuggingGurpreet Singh Dhami
Change-Id: I94013a446b4a39b874df4dfab1ecfb1ae832fce8
2019-04-10sdm: Update the DRM properties only when requiredSushil Chauhan
Define updates mask in HW layers, to avoid updating configuration related DRM properties, when it is not required. This reduces CPU instructions in the COMMIT Phase of all Skip Validate draw cycles. CRs-Fixed: 2395259 Change-Id: If4953b8d542a0b19cac6cb46dd75a26d3223d222
2019-04-04sdm: Couple doze mode transition to commit.Rajavenu Kyatham
Repeating previous commit on doze state transition can result in fetching content from stale buffers. Cache the power state and trigger a refresh for transition to take effect. CRs-Fixed: 2335745 Change-Id: I8508d64a55c3b30239c6ed2886df391407d22f25
2019-04-04sdm: On Doze suspend wait for previous commit release fence.Rajavenu Kyatham
On Powermode transitions driver stages same set of buffers and updates release fence. HWC caches those to its internal queue but doesn't get a chance to propagate back as subsequent commits would fail. In those cases wait for previous transfer to finish before releasing the buffers. CRs-Fixed: 2305135 Change-Id: I6187a60a3921bc153ca1be8c364a2fd69d71d70a
2019-03-22display: Remove default mode application after end of boot animationQing Huang
Android now applies the managed color mode (srgb or p3) or native mode at bootup. Combine mode will move in initalize before SurfaceFlinger applies the mode Change-Id: Ib60740e4a89937ffd214c2cf9cffea23dead3f9d
2019-03-19hwc2: Perform bandwidth-checked hotplugMathew Joseph Karimpanal
* Create and hotplug pluggable (e.g., DisplayPort) displays after a commit has succeeded on previous pluggable displays. This allows the driver to recalculate and return updated modes on remaining displays based on available link bandwidth. * Perform deferred hotplug handling in a new thread invoked at PresentDisplay(). Skip deferred hotplug handling from PresentDisplay() if a handling thread is in progress. CRs-Fixed: 2363982 Change-Id: I463fcbaa198d96a2f42283c8e6f0aa1f8b9e1b48
2019-03-01sdm: Change layer ops DLOGW back to DLOGEVarun Arora
Revert: I12481c591e0b03c8e5bb9fb59cc29ba8b34b0b1d Revert: Idccc882443400c312068ce85261f7f0032d9c2b7 These logs are indicative of a possible AOSP or AOSP modification issue and should be flagged as CRs and investigated. Change-Id: I3f657cbc390117346f52b903c63e2e473689c7e9 CRs-Fixed: 2408183
2019-02-07sdm: Implement getDisplayIdentificationDataVarun Arora
* Implement call flow from client to display interface. * Use display interface to query EDID blob from Connector information and return to client alongside pre-established port information from sde-drm during display creation. * Create EDID blob for Null Display (QMAA) to represent a 1920x1080 60fps display with panel name "Null Display" and port corresponding to either builtin or external, depending on DisplayNull class instantiated. * Introduce kErrorDriverData as a display interface error to represent situations in which expected data from the driver is missing. Currently this applied to EDID blob for all physical panels. * Update UnregisterDisplay API to allow cleanup of token via sde-drm. Change-Id: I5661f7bc0a5a68cdffa0cad3fe2351baa647012c CRs-Fixed: 2380873
2019-02-07Merge remote-tracking branch 'quic/display.lnx.5.0' into tipVarun Arora
2/7/2019 FF Change-Id: I78cdd49ab0f4da7ec24e9009ee5dd2cf0cb94ada CRs-Fixed: 2395201
2019-02-01hwc2: Update secure display layer on active built in displayRamkumar Radhakrishnan
1. Add support to handle secure display layer on secondary display 2. Update secure display layer on active builtin display. 3. Add display config API to get the display attributes of the active builtin display. Change-Id: Ia70dff316265c9364b060fe4fae591a9599e16e9 CRs-Fixed: 2375587
2019-01-30sdm: Add support for Fast Path CompositionSushil Chauhan
During Fast Path optimization, the driver validation happens in the COMMIT IOCTL only. In Validate phase, SDM doesn't set the DRM properties and it doesn't call the VALIDATE IOCTL, which avoids redundant CPU cycles. To disable this feature, set the value of vendor prop "vendor.display.disable_fast_path" as 1. CRs-Fixed: 2354405 Change-Id: I06380108ddc1d78543981a99cb90acb4be45997f
2019-01-24hwc2: Fix handling of no metadata case for externalMahesh Aia
In the case where video does not set refresh rate metadata, default to lower of all currently active (powered on) displays aka "throttling refresh rate" Change-Id: I696140d6b72199c113065ed032d2bb87bff90974 CRs-Fixed: 2365041
2019-01-22hwc2: Fix handling of no metadata case for externalMahesh Aia
In the case where video does not set refresh rate metadata, default to lower of all currently active (powered on) displays aka "throttling refresh rate" Change-Id: I696140d6b72199c113065ed032d2bb87bff90974 CRs-Fixed: 2365041
2019-01-17hwc2: Change SetLayerZOrder Error to WarningWenjun Zhang
Since an invalid operation is requested on a layer, SDM needs no flag an error when updateLayerZ. Appropriate error code should be returned and client is responsible to handle Change-Id: I12481c591e0b03c8e5bb9fb59cc29ba8b34b0b1d Signed-off-by: Wenjun Zhang <wjzhan@codeaurora.org>
2019-01-16Merge "hwc2: Derive dataspace on ClientTarget from ColorMode"qctecmdr Service
2019-01-08ColorMode: multi-mode support through QDCM API with WCGXu Yang
1. Select P3 HDR mode when HDR playback. Fall back to P3 SDR mode if there is no P3 HDR mode. And after HDR video ends, go back to P3 SDR mode or SRGB mode according to the current blend space. 2. When user switches mode by QDCM API, check the mode attributes to see whether they match the current blend space and dynamic range. Apply the mode only when the blend space and dynamic range match. Otherwise cache the mode until the current blend space and dynamic range become the same with that in the mode. 3. Print out the current active color mode name in dumpsys. Change-Id: I46a4d25536c7e2b408e11e956f152f7a80528a43 Signed-off-by: Xu Yang <yangxu@codeaurora.org>
2019-01-02hwc2: Derive dataspace on ClientTarget from ColorModeArun Kumar K.R
- The dataspace of the client target depends on the current color mode. Clients calls SetClientTarget after prepare, SDM needs dataspace information in the Validate phase to set up its pipeline. Hence derive the client target dataspace based on the current color mode. - Return error if dataspace doesn't match in SetClientTarget Change-Id: I6edccf44e73c57a16e97b3c7e6d121dbc8775627 Crs-fixed: 2364498
2018-12-28sdm: Add support to get/set DSI clk.Pullakavi Srinivas
CRs-Fixed: 2314107 Change-Id: I213edcaa61b33731b920b500a170e5a265909e47
2018-12-23sdm: mark all layers as skip, when client target handle is NULLRajavenu Kyatham
- real pipe is assigned for a client layer which has a NULL buffer handle and respective virtual pipe is assigned to another layer. - during atomic commit, real pipe is not programmed due to NULL handle but virtual pipe is programmed, which is leading to atomic ioctl failure. - hence, mark all layers as skip, when client target handle is NULL. Change-Id: I4a6e2d0ce58063564b12863b599dabc6d810c477 CRs-Fixed: 2358631
2018-12-05Merge "hwc2: Improve multi-display creation and hotplugging"qctecmdr Service
2018-12-05Merge "hwc2: Fix input layer dump"qctecmdr Service
2018-11-30Merge "hwc2: Allow suspend call during secure UI"qctecmdr Service
2018-11-28Merge "hwc2: Fix compile errors in switch statement."qctecmdr Service
2018-11-27hwc2: Lock by display client idMathew Joseph Karimpanal
Lock by display client id when doing per-display validation state reset. CRs-Fixed: 2356418 Change-Id: I2f145f2a0525176c8d9d4300e410b42b14026b79
2018-11-25hwc2: Allow suspend call during secure UIRamakant Singh
Kernel can handle the non secure call as well during secure ui session. Change-Id: I6a40cfbce737822956ce3f08b4adc5a694f591b2
2018-11-24hwc2: Fix input layer dumpRamakant Singh
Change-Id: I0277d5928b7307ec145e2059bc64adbfa4b671e6
2018-11-23sdm: Continue hotplug handling on failureMathew Joseph Karimpanal
- Continue hotplug handling and attempt display creation on remaining displays even if creating one of the displays failed. - Treat zero modes on displays as a non-critical error. CRs-Fixed: 2332093 Change-Id: I1c5e83666281b00aeb0014a46e9647dc7789809d
2018-11-20hwc2: Fix compile errors in switch statement.Anjaneya Prasad Musunuri
Fix compile errors because of fall through switch statements. CRs-Fixed: 2352498 Change-Id: I5ec641a2eeee1cfc4bf6750903c6287c5a137d9e
2018-11-19hwc2: Remove NATIVE mode check for setting hdr flagsArun Kumar K.R
Flags for HDR in the Layer and LayerStack must be set irrespective of the color mode, so that HDR can be handled appropriately in SDM. Change-Id: Ia6a998276c48c0bb32f8d529a7881a26254cfe9f Crs-fixed: 2351590
2018-11-18Merge "hwc2: Reset validate on surface damage region update."qctecmdr Service
2018-11-15sdm: Merge panel dead with HW Recovery reset handlingVarun Arora
* ESD event will power reset all displays, like hw recovery * Hw recovery will set current color mode on all displays, like ESD event did for builtin * LUT reset is handled on PowerOff * Rename GetLastPowerMode to GetCurrentPowerMode to match it's actual functionality * Rename last_power_mode_ to current_power_mode_ to match it's actual functionality * Remove GetLastPowerMode / last_power_mode_ from DisplayBase, it is the same as GetDisplayState / state_ Change-Id: Ifa259eda1875ff04c6d3c48b8231370a5f3a678f CRs-Fixed: 2348547
2018-11-13hwc2: Reset validate on surface damage region update.Pullakavi Srinivas
Video mode panels make use of dirty regions to recompute aggregated fb roi that needs to be cropped from cached buffer. Reset validate to update appropriate rect. CRs-fixed: 2326636 Change-Id: I9e6519ca833f84c36d9fa6fb8270ccf3d1fcf83d
2018-11-04sdm: Expose all possible configs to clients.Pullakavi Srinivas
DispSync queries activeConfig to get accurate fps before resyncing. Hardcoding to one config can lead to delayed resync, thereby janks when dynamic fps kicks in. Updating right vsync period will accelerate resync. For usecases like destination scaler, override display resolution exposed to SurfaceFlinger. CRs-Fixed: 2333798 Change-Id: I551fe76fb355f2f1c6374d17b805a3cc860d8c75
2018-10-29Merge "hwc2: Dump frames by display-type bitmask"qctecmdr Service
2018-10-25hwc2: Dump frames by display-type bitmaskMathew Joseph Karimpanal
Each set bit position in <DISPLAY_TYPE> of frame dump command corresponds to a qdutils::DISPLAY_XYZ display. Dump frames of displays based on <DISPLAY_TYPE> bitmask. Frame dump command for quick reference: adb shell "vndservice call display.qservice 21 i32 <FRAME_COUNT> i32 <DISPLAY_TYPE> i32 <LAYER_TYPE>" CRs-Fixed: 2324149 Change-Id: I72ca7c89cb6fbf2ff5f146ca5d860a52031e87c3
2018-10-15sdm: Clear VDS output buffer on flush.Pullakavi Srinivas
CRs-Fixed: 2200594 Change-Id: I99d1ea06cf9ded7755752c7b5fe7e5857e833755
2018-10-10Merge "hwc: Log acquire fence zero as warning"qctecmdr Service
2018-10-04hwc: Log acquire fence zero as warningSushil Chauhan
For zero acquire fence fd case, convert the log from Error to Warning. CRs-Fixed: 2324117 Change-Id: I475cc24c99bc8db8469dc92abc36c240cd8b8b51
2018-10-01sdm: Cache command mode status during initializationTharaga Balachandran
This function reduces time spent in HWCDisplay::IsDisplayCommandMode() by caching the is_cmd_mode_ flag after querying fixed info once during initialization and after dynamic mode switching through SetDisplayMode(). CRs-Fixed: 2309620 Change-Id: Ib33f41030e8828f7a977893b33ba3819f4622286
2018-09-28Merge "hwc2: Check color_mode_ before calling GetCurrentColorMode"qctecmdr Service
2018-09-28Merge "hwc2: Do not honor cursor position when cursor layer is not present"qctecmdr Service
2018-09-27Merge "sdm: Replace strncpy with strlcpy"qctecmdr Service
2018-09-20sdm: unset ACTIVE crtc prop for HWTVDRMVarun Arora
PowerOff API should be unsetting crtc ACTIVE for proper bridge teardown. Unlike HWDeviceDRM, LP property does not apply to External and need not be set Change-Id: Id4a6d9cb057a26f3e19a0e8d29452dee4e586fd4 CRs-Fixed: 2277100
2018-09-17sdm: Replace strncpy with strlcpyRavikanth Tuniki
CRs-Fixed: 2295592 Change-Id: Id23562aec2a8976b94759f79b9a929726193d65b
2018-09-16hwc2: Do not mark single buffered or color fill layers as skipPullakavi Srinivas
CRs-Fixed: 2225117 Change-Id: I9d924a5b16c7755ca9fb7f4cf799328456fe11c6
2018-09-15Merge "hwc2: Change Get and Destroy Layer Error to Warning"qctecmdr Service
2018-09-15Merge "hwc2: Allow commit to go through if flush_ flag is set"qctecmdr Service
2018-09-11Merge "hwc2: Cache color mode and render intent for Primary display"qctecmdr Service
2018-09-11hwc2: Check color_mode_ before calling GetCurrentColorModeYuan Zhao
Replace color_mode_->GetCurrentColorMode() call with HWCDisplay::GetCurrentColorMode function to avoid null pointer de-reference, since color_mode_ will not be created for virtual display. CRs-Fixed: 2310086 Change-Id: I4fe0ac81cddae3373a7aaa0d7dc02a911a0735fc