Mir

Merge lp:~alan-griffiths/mir/fix-1723235 into lp:mir

Proposed by Alan Griffiths on 2017-10-13
Status: Merged
Approved by: Brandon Schaefer on 2017-10-14
Approved revision: 4288
Merged at revision: 4289
Proposed branch: lp:~alan-griffiths/mir/fix-1723235
Merge into: lp:mir
Diff against target: 32 lines (+3/-5)
1 file modified
src/platforms/mesa/server/kms/display_buffer.cpp (+3/-5)
To merge this branch: bzr merge lp:~alan-griffiths/mir/fix-1723235
Reviewer Review Type Date Requested Status
Brandon Schaefer (community) 2017-10-13 Approve on 2017-10-14
Mir CI Bot continuous-integration Approve on 2017-10-13
Review via email: mp+332241@code.launchpad.net

Commit message

Don't treat failing to bypass buffers as a fatal error. (LP: #1723235)

To post a comment you must log in.
Mir CI Bot (mir-ci-bot) wrote :

PASSED: Continuous integration, rev:4288
https://mir-jenkins.ubuntu.com/job/mir-ci/3726/
Executed test runs:
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-mir/5117
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-0-fetch/5355
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=artful/5342
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial/5342
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=zesty/5342
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=artful/5161
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=artful/5161/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=zesty/5161
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=zesty/5161/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=artful/5161
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=artful/5161/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial/5161
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial/5161/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=zesty/5161
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=zesty/5161/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=mesa,release=artful/5161
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=mesa,release=artful/5161/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=mesa,release=zesty/5161
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=mesa,release=zesty/5161/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial/5161
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial/5161/artifact/output/*zip*/output.zip

Click here to trigger a rebuild:
https://mir-jenkins.ubuntu.com/job/mir-ci/3726/rebuild

review: Approve (continuous-integration)
Brandon Schaefer (brandontschaefer) wrote :

Well, this does indeed fix my bypass bug I was hitting on the raspi3. I am still getting the other error. From testing around though it really looks like something specific in the mir backend of SDL2. Since SDL2 clients with wayland on miral work just fine. Something ill have to look into but this change LGTM

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/platforms/mesa/server/kms/display_buffer.cpp'
2--- src/platforms/mesa/server/kms/display_buffer.cpp 2017-07-28 17:00:43 +0000
3+++ src/platforms/mesa/server/kms/display_buffer.cpp 2017-10-13 14:07:57 +0000
4@@ -504,7 +504,7 @@
5 make_current();
6
7 listener->report_successful_egl_make_current_on_construction();
8-
9+
10 glClear(GL_COLOR_BUFFER_BIT);
11
12 surface.swap_buffers();
13@@ -591,9 +591,7 @@
14 {
15 auto bypass_buffer = (*bypass_it)->buffer();
16 auto native = std::dynamic_pointer_cast<mgm::NativeBuffer>(bypass_buffer->native_buffer_handle());
17- if (!native)
18- BOOST_THROW_EXCEPTION(std::invalid_argument("could not convert NativeBuffer"));
19- if (native->flags & mir_buffer_flag_can_scanout &&
20+ if (native && native->flags & mir_buffer_flag_can_scanout &&
21 bypass_buffer->size() == surface.size() &&
22 !needs_bounce_buffer(*outputs.front(), native->bo))
23 {
24@@ -776,7 +774,7 @@
25
26 visible_bypass_frame = scheduled_bypass_frame;
27 scheduled_bypass_frame = nullptr;
28-
29+
30 visible_composite_frame = std::move(scheduled_composite_frame);
31 scheduled_composite_frame = nullptr;
32 }

Subscribers

People subscribed via source and target branches