1. For PTOR layers, MDP needs to be configured with width, height
and format of the Copybit render buffer, otherwise it will lead to
artifacts due to incorrect render buffer reads, when PTOR layer
handles have un-equal strides.
2. Remove render buffer offset for a PTOR layer and configure MDP
with modified source crop, based on its position on render buffer.
3. A layer cannot qualify for PTOR feature, if none of below layers
intersect with it.
Change-Id: Idba65789b9ed3b699a5c70107881868c0385322d
Read the maximum width mixer can output from drivers
and consider this in identifying if dual pipes are required
to support a layer. So far above 2K dimensions we are using dual
pipes, but 8x39 mixer output can be upto 2560. So there is no
need of dual pipes as long as pipe data is less than this limit.
Compare layer/panel resolutions against this limit to deduce
if there is a need for dual pipes or split.
Change-Id: I52e1d28e381327d4f0b00f5ea8547c1e6157313c
On configuring for secure display, MDP switches to secured
memory bank. Invoking any more DCS panel commands which
follows non-secure path will cause XPU violation. So its
necessary for HWC to turn off partial update to avoid DCS
commands due to ROI change.
Change-Id: Ibcc24d34d3cb825b027c116ac6a4d841d9cb9b70
Provides a way to enable/disable logs at runtime via binder.
The logs need to be enabled from a priviliged shell.
For example,
$ adb shell service call display.qservice 15 i32 0 i32 1
Here 15 is the integer code for DYNAMIC_DEBUG in IQService.h
The first parameter 0 is for DEBUG_ALL
The second parameter 1 is to enable.
Hence, this command enables all debug logs.
Another example - this command enables vsync logging
$ adb shell service call display.qservice 15 i32 2 i32 1
Change-Id: I13d5f397d9d03f0ac6a14d3a3c9098ed59fc62fd
Currently for Mdss rotator we manipulate the layer buffer dimensions
to be equal to what rotator's destination dimensions would be, so that
these could be fed to MDP. Instead, this patch introduces APIs in
rotator so that hwc can directly query destination crop, width, height,
format from rotator.
This also simplifies the updateSource() and configRotator() helpers.
Change-Id: I501d998f2e0574683c764af9422742b2426ba0c7
- Consider two smallest layers for PTOR feature which uses MDP comp.
- These two layers are rendered on a buffer and are queued to MDP
to acheive full MDP Composition
- This helps to acheive performance enhancement
Change-Id: I43d9306ff19cd2d7a410c885316523965a44cbd4
1) While setting BWC check for 90 transform and swap crop
2) Calculate decimation in the getDecimationFactor API itself.
Currently, a residual downscale is calculated and the clients have
to take logs and apply forcible decimation like in MdpCtrl
3) Fix bug where transform gets typecasted to bool
b/14225977
Change-Id: I3c99c571e02e2cf7822342516b6a87d97be553d1
1. Use MDP rotator to rotate RGB layers which are rendered by software
2. Restrict total number of rotator sessions to 4 for all displays
3. Disable RGB layer rotation for all MDP versions < MDP5
Change-Id: Ie93111082dff9a16b614e9768df5d8ce83ff9e25
While checking for valid dimensions, take 90 transform into
account while calculating downscales.
b/14225977
Change-Id: Ie8b527c8263a5eb366ae2a4adaa2ffbbf270ba50
Split video with width > 2048 only if source split is absent, and
the relevant system property is set.
In source split the video is split evenly anyway.
Change-Id: Iab0af427756d32120a160787ecfb7c974dbbeea1
Source Split layers always if the driver indicates so by setting
the src_split_always in the capabilities sysfs node.
This is applicable to layers whose width > mixer's width, since
MDP clk rate is dependent on max(mixer_width, layer_width).
This feature can be enabled if the panel height is more than a
certain empirically derived value. Splitting always in those
cases can help with a lower voltage.
Change-Id: If9b33f11ca4132eb77416c26819f7473c65d3b08
Map dirtyRect generated for sourceCrop to layer destination
before using it for calculating ROI for single DSI
panels.
Change-Id: Ie65284e9c58270c66276f9d43c4eb3e7db29b623
MDP bandwidth limitations can be avoided, if the overlapping region
covered by the smallest layer at a higher z-order, can be composed
on a render buffer using Copybit, and then it can be queued to MDP
along with other layers. It helps to improve performace by avoiding
GPU Composition in use cases like Home Screen pan. To enable this
feature, set system prop "persist.hwc.ptor.enable" to "true" or '1'
and enable Copybit HAL compilation.
Change-Id: Ib719d3dd42477837519518cc427f1b95356c28f7
Provide support to simulate composition strategy tree to execute
and test multiple strategy combinations across test cases.
Change-Id: I5011fad32f8f45ecef47b6df513f9d72343697d2
Enable BWC for videos with crop and position widths <= mixer width.
Source split was earlier used on split panels only, and BWC was
never enabled (It should at least have been for eligible content).
When source split was enabled for all panels, automatically BWC got
disabled for rotated videos. This change fixes that.
Change-Id: I349e782fb6de515ff42fcb137f02cf27c425da56
DirtyRect for a layer is generated w.r.t to its buffer
coordinates. It needs to be mapped for layer destination
(display) coordinates before using it to calculate the frame's
ROI.
Change-Id: Id86f495b2016da2cfd5aed4d86bff6d3035abf10
For panels that cannot accept commands in both the interfaces, we cannot
send two ROI's (for each half). We merge them into single ROI and split
them across lSplit for MDP mixer use. The ROI's will be merged again
finally before updating the panel in the driver.
- Reads panel property of dual control path.
- If dual control path not supported, merge ROI's before
analysing for composition strategies.
Change-Id: I67e361a299dc5d1adb28b180900e24633eefc4a8
Extends partial frame update support for split displays by calculating
changing region(ROI) independently for each half of the screen. In case of
only one half updating, display driver shuts down the DSI/MDP mixer control
of the non updating half.
Maintains two ROI's for each display. In case of Non-split
displays, only left ROI is updated.
Change-Id: I8a67fe40aac665a48b6f8a46beffb9f8027851b2
When validateAndSet fails we must reset the mDoable flag to false and
close the fb device. This will prevent making a draw call using
invalid resource references and prevent any fd leaks.
Additionally, we should only turn AD on if there are no configuration
errors during prepare call. This will prevent toggling AD between
on/off state in the face of continuous failures.
Change-Id: I15502dbf64c6203092aa13e001bab5d27b0e17ec
Since both has same number of pipes with similar
features like scaling capabilities, for now rely on 8x16.
Change-Id: Ief51bb5c70d8aef7dca3d791f8b4d62a4c5392ff
Enable source split for targets with single dsi. This has the
benefit of using 2 pipes for layers whose width (crop) is higher
than line width.
Change-Id: I147136a3eb786e1af7b63508d65c010e88e358ed
* Mdss driver supports DMA-Multiplexing on wb interface
for certain targets. Add overlay get function to query
this info during pipe allocation for wb.
* UI Scaling on external is not supported on certain
targets due to the lack of availability of pipes with
scalars. Add overlay get function to query this info
to disable action-safe calcs, DRC and others which
require downscaling.
Change-Id: I1726caa4634f72d781561e797078648524ea2eef
For 8x26, if external display is connected, DMA pipe should never
be occupied by primary display. Otherwise, external display would
lack DMA pipe if switch to GPU composition.
This patch refines former commit: 9c1eb2be21
CRs-Fixed: 640934
Change-Id: Idc64b724cfacf9e8e22ca73e4e443e8d989e1212
Rely on panel info shared by driver and enable
partial update if it says as supported. Use the
existing property to disable partial update if
required for debugging.
Change-Id: I75d5dcbbfea08515d17150054ca91367319b929c
No need to draw dropped layers while doing video only composition
since they are lying outside updating ROI.
Change-Id: I7bef731538e39a5b16f17314ad31f0c4e7f2b618