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

Commit 4d712352 authored by ramindani's avatar ramindani Committed by Ram Indani
Browse files

Return if HWCDisplay is not yet created

Test: device boots with VRR flag enabled, atest HWComposerTest
BUG: 311300327
Change-Id: I29ddd536c9718b97f90d7400d3ea12f35f182054
parent cbf36174
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -944,6 +944,10 @@ status_t HWComposer::notifyExpectedPresentIfRequired(PhysicalDisplayId displayId
                                                     std::optional<Period> timeoutOpt) {
    RETURN_IF_INVALID_DISPLAY(displayId, BAD_INDEX);
    auto& displayData = mDisplayData[displayId];
    if (!displayData.hwcDisplay) {
        // Display setup has not completed yet
        return BAD_INDEX;
    }
    {
        std::scoped_lock lock{displayData.expectedPresentLock};
        const auto lastExpectedPresentTimestamp = displayData.lastExpectedPresentTimestamp;