External only feature is completely handled in surfaceflinger, remove
unwanted code churn related to external only feature from display HAL.
Change-Id: If4f4f3fa8e91a5b8387e426b9e190abd2b06d793
* This reverts commit 52b4fdbdbd.
* Since DisplayDevices are not created for non-wfd virtual
displays(CTS/SR/SSD) anymore, we can remove these checks.
Change-Id: I9249a70c6d6f6b42f268e6ec8a28c0a86b954c4e
1. Add hook to dump the layers going to VDS based virtual display.
2. Furthermore, add utility function to dump the frame buffer and
WB output buffer. This will be enabled via a system property
debug.hwc.enable_vds_dump
Once dumping is enabled, the dumps can be extracted from
/data/vds.fb.FORMAT.XRESxYRES.raw
/data/vds.wb.FORMAT.XRESxYRES.raw
e.g. vds.fb.MDP_RGBA_8888.1152x1920.raw
Change-Id: I2435c5507961a52929411206892c005492d5c193
* On Low-end targets, no secure video is displayed on primary
during WFD session due to lack of VG pipes.
* Once the secure video is paused, and WFD session is paused
from sink, paused secure video should be seen on the primary
due to the availability of VG pipes(which are no longer used
by external)
* Call invalidate at the end of VDS pause to make this happen.
Change-Id: Ia735be10e798b6a241a82239e3a136efb54e72f3
* Revert commit 7a495b3caa
"hwc: Call blank IOCTL on virtual as well if it is connected."
* On issuing suspend when WFD is connected, display-hal
receives both pause and blank calls. Calling StopTerminate
ioctls on WB(WB is not active on VDS pause) once blank
is issued on Primay(i.e when iommu is detached) doesn't free
up the buffer nodes resulting in orphaned memory blocks.
* To avoid this, allow WB to be active even during
VDS pause state so that when StopTerminate calls are made as
part of VDS teardown, display will be in unblanked state and
iommu would have been reattached, thus freeing up the buffer
nodes.
* Doing this doesn't clear all references to WB fb node during
VDS pause. Call display commit to unset the pipes rather than
relying on the refcount
Change-Id: I6f89c2ca56ea8a0133e66f3928f6e35ca94d9b52
Clear overlay and layer-rot map from the top level caller of
composition, rather than from the place of actual intermediate
failure. This makes sure, even in cases of GPU comp failure,
overlay and layer-rot maps are cleared and eventually pipes unset.
Change-Id: Ibf1152a0e8ca66d87bcc6b87009c4b09e451099d
* Provide a binder interface call for wfd module
to inform display about the start/stop/pause/resume
of wfd session.
* This is needed for wfd-hdmi synchronization in
case of v4l2 wfd solution. If hdmi is plugged
in during v4l2 wfd session, display-hal waits in
uevent thread for wfd teardown notification from
wfd module, before going ahead with configuring
external display.
* For VDS WFD solution, display-hal waits in uevent
thread for wfd-teardown to be signalled from
the composition thread.
Change-Id: I9514cb5bc7ff81de0b5dd4cdf66d8286a64ba094
* Rely on list->outbuf rather on mVirtualonExtActive
to determine a virtual display device
* This helps in cases where SSD/SR is started after
a non-Hybrid WFD session becomes active. We need
to update retireFenceFd of SSD/SR which used to not
happen since mVirtualonExtActive is set becomes of
an active non-Hybrid WFD session
Change-Id: Ib42af62e723b5f62f62a1a8d280f0c9af49683d7
1. Hard code the vsync for VDS during the first prepare call
with valid VDS display. We align the vsync period to that
of the primary display. Effectively, we produce at the at
the primary refresh rate and do not worry about the consumer.
2. Do not bail out on the first frame as it leads to showing empty
buffer. This leads to failures for some test cases such as those
run in CTS.
3. We need an FB layer handle check to cater for this usecase:
i. Video is playing in landscape on Primary
ii. Launch ScreenRecord app
In this scenario, the first VDS draw call will have HWC
composition and VDS does not involve GPU to get eglSwapBuffer
to get valid fb handle.
Change-Id: Idc7d989e244a83ad28ce730ecb12955bc249dc25
When we receive a buffer handle that is secure, we configure WB as
secure; otherwise we continue as normal.
Change-Id: I497e257352c103c5da7ac2dc3fd4d7fe0e0b3953
* When a non-WFD virtual display device (SSD/
screenrecord) is active along with
non-hybrid WFD solution(WFD faked on
external), give preference to non-hybrid WFD
device over non-WFD virtual display device.
* This is needed only in cases when WFD is
enabled via v4l2 rather than using VDS api's.
Change-Id: I63e53baa214bdcdac19430ca30b939cdd7416cbb
Use outbuf handle width to configure display xres, since that would
have the necessary alignment. The outbuf is guaranteed to be valid
by the framework during hwc_prepare.
We use the framebuffer layer's display frame to obtain the actual
width. For example, the actual width could be 720 but the aligned
width would be 736.
Change-Id: I5afe38001be8116e1ad6a9f46c7ecaa50b5f25a2
In the current composition strategy we bail out if there are no app
layers present. However, this leads to undesirable behaviour if the
FB contains valid data that is expected as output. In this patch we
copy the FB to the output buffer to satisfy this use case.
Change-Id: If905d8b0652faf73b9aecad1abc760f21967807f
1. Define classes for VDS and V4L2 based WFD solutions.
2. Overload the functionalities for VDS and V4L2 WFD solutions.
3. Instantiate VDS object or V4L2 object during hwc init based on the
property persist.hwc.enable_vds set by the user.
4. VDS solution is not verified as it requires some dependent changes.
Change-Id: I74bf944d532da138c850d4ec0c20b4a881489efa