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

Commit 2391e8c1 authored by Ady Abraham's avatar Ady Abraham
Browse files

composer: register only vsync_2_4 callback

Composer 2.4 extends vsync callback by exposing a new vsync_2_4
callback. Both should not be registered at the same time.

Test: rev up composer to 2.4 and test refresh rate switching
Bug: 141329414
Change-Id: If41f45cab21ed16a7b2f36b3b95fb3591b04c900
parent 4f0b0f21
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -58,9 +58,6 @@ class HwcHalImpl : public V2_3::passthrough::detail::HwcHalImpl<Hal> {
        BaseType2_1::mDispatch.registerCallback(
                mDevice, HWC2_CALLBACK_REFRESH, this,
                reinterpret_cast<hwc2_function_pointer_t>(refreshHook));
        BaseType2_1::mDispatch.registerCallback(
                mDevice, HWC2_CALLBACK_VSYNC, this,
                reinterpret_cast<hwc2_function_pointer_t>(vsyncHook));
        BaseType2_1::mDispatch.registerCallback(
                mDevice, HWC2_CALLBACK_VSYNC_2_4, this,
                reinterpret_cast<hwc2_function_pointer_t>(vsync_2_4_Hook));
@@ -80,7 +77,6 @@ class HwcHalImpl : public V2_3::passthrough::detail::HwcHalImpl<Hal> {
        // which is likely incorrect
        BaseType2_1::mDispatch.registerCallback(mDevice, HWC2_CALLBACK_HOTPLUG, this, nullptr);
        BaseType2_1::mDispatch.registerCallback(mDevice, HWC2_CALLBACK_REFRESH, this, nullptr);
        BaseType2_1::mDispatch.registerCallback(mDevice, HWC2_CALLBACK_VSYNC, this, nullptr);
        BaseType2_1::mDispatch.registerCallback(mDevice, HWC2_CALLBACK_VSYNC_2_4, this, nullptr);
        BaseType2_1::mDispatch.registerCallback(mDevice, HWC2_CALLBACK_VSYNC_PERIOD_TIMING_CHANGED,
                                                this, nullptr);