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

Commit 34165d81 authored by Lucas Berthou's avatar Lucas Berthou Committed by Android (Google) Code Review
Browse files

Merge "SF: passing link training failure up to DM" into main

parents 5cafdd7f 0d18823b
Loading
Loading
Loading
Loading
+13 −0
Original line number Diff line number Diff line
@@ -2268,6 +2268,19 @@ void SurfaceFlinger::onComposerHalHotplugEvent(hal::HWDisplayId hwcDisplayId,
        return;
    }

    if (event < DisplayHotplugEvent::ERROR_LINK_UNSTABLE) {
        // This needs to be kept in sync with DisplayHotplugEvent to prevent passing new errors.
        const auto errorCode = static_cast<int32_t>(event);
        ALOGW("%s: Unknown hotplug error %d for hwcDisplayId %" PRIu64, __func__, errorCode,
              hwcDisplayId);
        return;
    }

    if (event == DisplayHotplugEvent::ERROR_LINK_UNSTABLE &&
        !FlagManager::getInstance().display_config_error_hal()) {
        return;
    }

    // TODO(b/311403559): use enum type instead of int
    const auto errorCode = static_cast<int32_t>(event);
    ALOGD("%s: Hotplug error %d for hwcDisplayId %" PRIu64, __func__, errorCode, hwcDisplayId);