Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4e001df7 authored by Ady Abraham's avatar Ady Abraham
Browse files

composer: add SKIP_VALIDATE to AIDL

HWC2_CAPABILITY_SKIP_VALIDATE was never defined for HIDL,
and instead there was a hack to just pass the value to the client
(see commit 6a05e911).

Test: build
Bug: 198690211
Change-Id: I2b06ad792237eb99e4dfe6b5c1ef808d5de45bd7
parent 832258e9
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -38,4 +38,5 @@ enum Capability {
  SIDEBAND_STREAM = 1,
  SKIP_CLIENT_COLOR_TRANSFORM = 2,
  PRESENT_FENCE_IS_NOT_RELIABLE = 3,
  SKIP_VALIDATE = 4,
}
+11 −0
Original line number Diff line number Diff line
@@ -46,4 +46,15 @@ enum Capability {
     * representation of the actual present time of a frame.
     */
    PRESENT_FENCE_IS_NOT_RELIABLE = 3,
    /**
     * Specifies that a device is able to skip the validateDisplay call before
     * receiving a call to presentDisplay. The client will always skip
     * validateDisplay and try to call presentDisplay regardless of the changes
     * in the properties of the layers. If the device returns anything else than
     * no error, it will call validateDisplay then presentDisplay again.
     * For this capability to be worthwhile the device implementation of
     * presentDisplay should fail as fast as possible in the case a
     * validateDisplay step is needed.
     */
    SKIP_VALIDATE = 4,
}
+3 −0
Original line number Diff line number Diff line
@@ -70,6 +70,9 @@ static_assert(
        static_cast<aidl::android::hardware::graphics::composer3::Capability>(
                ::android::hardware::graphics::composer::V2_1::IComposer::Capability::
                        PRESENT_FENCE_IS_NOT_RELIABLE));
// HWC2_CAPABILITY_SKIP_VALIDATE was never defined for HIDL, so we just hardcode its value
static_assert(aidl::android::hardware::graphics::composer3::Capability::SKIP_VALIDATE ==
              static_cast<aidl::android::hardware::graphics::composer3::Capability>(4));

static_assert(aidl::android::hardware::graphics::composer3::LayerRequest::CLEAR_CLIENT_TARGET ==
              static_cast<aidl::android::hardware::graphics::composer3::LayerRequest>(