diff --git a/src/backends/drm/egl_gbm_layer.cpp b/src/backends/drm/egl_gbm_layer.cpp index aeee43f1ed..2325139067 100644 --- a/src/backends/drm/egl_gbm_layer.cpp +++ b/src/backends/drm/egl_gbm_layer.cpp @@ -140,7 +140,14 @@ bool EglGbmLayer::endRendering(const QRegion &damagedRegion) m_shadowBuffer->render(m_pipeline->pending.sourceTransformation); } GLRenderTarget::popRenderTarget(); - const auto buffer = m_gbmSurface->swapBuffersForDrm(damagedRegion); + QSharedPointer buffer; + if (m_pipeline->gpu() == m_eglBackend->gpu()) { + buffer = m_gbmSurface->swapBuffersForDrm(damagedRegion); + } else { + if (m_gbmSurface->swapBuffers(damagedRegion)) { + buffer = importBuffer(); + } + } if (buffer) { m_currentBuffer = buffer; m_currentDamage = damagedRegion;