Mir

Merge lp://qastaging/~kdub/mir/fix-1577967 into lp://qastaging/mir

Proposed by Kevin DuBois
Status: Merged
Approved by: Kevin DuBois
Approved revision: no longer in the source branch.
Merged at revision: 3533
Proposed branch: lp://qastaging/~kdub/mir/fix-1577967
Merge into: lp://qastaging/mir
Diff against target: 349 lines (+137/-48)
7 files modified
include/client/mir_toolkit/mir_surface.h (+17/-5)
playground/mir_demo_client_prerendered_frames.c (+6/-0)
src/client/mir_connection.cpp (+21/-25)
src/client/mir_surface.cpp (+17/-16)
src/client/mir_surface.h (+7/-2)
tests/acceptance-tests/test_buffer_stream_arrangement.cpp (+45/-0)
tests/unit-tests/client/test_client_mir_surface.cpp (+24/-0)
To merge this branch: bzr merge lp://qastaging/~kdub/mir/fix-1577967
Reviewer Review Type Date Requested Status
Mir CI Bot continuous-integration Approve
Daniel van Vugt Abstain
Cemil Azizoglu (community) Approve
Alan Griffiths Approve
Chris Halse Rogers Approve
Review via email: mp+294283@code.qastaging.launchpad.net

Commit message

fix lp: #1577967 by clarifying what mir_surface_get_buffer_stream() should do in a multistream world, and by making mir_surface_is_valid() respond properly when non-default streams are used.

Description of the change

fix lp: #1577967 by clarifying what mir_surface_get_buffer_stream() should do in a multistream world, and by making mir_surface_is_valid() respond properly when non-default streams are used.

note: the original thought was designate the 1st MirBufferStream as 'the default stream', however, soon it will be possible to have multiple MirPresentationChains, in which case there are no MirBufferStream*'s to be the default.

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

FAILED: Continuous integration, rev:3505
https://mir-jenkins.ubuntu.com/job/mir-ci/967/
Executed test runs:
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-mir/1041/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-0-fetch/1088
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/1079
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial/1079
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=vivid+overlay/1051/console
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial/1051/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1051
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1051/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1051
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1051/artifact/output/*zip*/output.zip
    ABORTED: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial/1051/console

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

review: Needs Fixing (continuous-integration)
Revision history for this message
Chris Halse Rogers (raof) wrote :

LGTM. Should we be marking all the mir_surface_* functions which implicitly deal with a default BufferStream as deprecated?

Certainly we should be marking mir_surface_{get,set}_swap_interval as deprecated. I lean towards marking mir_surface_get_buffer_stream as deprecated, also, although there's not a direct replacement.

review: Approve
Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

Triggered rebuild as a quick looks suggested extremely slow test hardware leading to timeouts.

~~~~

+ uint32_t output_id;
+
};

Unnecessary whitespace

review: Approve
Revision history for this message
Mir CI Bot (mir-ci-bot) wrote :

FAILED: Continuous integration, rev:3505
https://mir-jenkins.ubuntu.com/job/mir-ci/971/
Executed test runs:
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-mir/1047/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-0-fetch/1094
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/1085
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial/1085
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=vivid+overlay/1057/console
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial/1057/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1057
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1057/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1057
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1057/artifact/output/*zip*/output.zip
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial/1057/console

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

review: Needs Fixing (continuous-integration)
Revision history for this message
Kevin DuBois (kdub) wrote :

> Certainly we should be marking mir_surface_{get,set}_swap_interval as
> deprecated. I lean towards marking mir_surface_get_buffer_stream as
> deprecated, also, although there's not a direct replacement.

There is a way in the current API to work without mir_surface_get_buffer_stream()

MirSurfaceSpec* spec = ...;
MirBufferStream* stream = mir_connection_buffer_stream_create_sync(..);
mir_surface_spec_set_streams(spec, {stream, 0, 0}, 1);
MirSurface* surface = mir_surface_create_sync(spec);

now the client knows which stream is in the surface, and could change/swap as it wants to.

Revision history for this message
Cemil Azizoglu (cemil-azizoglu) wrote :

>LGTM. Should we be marking all the mir_surface_* functions which implicitly deal with a default >BufferStream as deprecated?

+1 as the names are really confusing.

Needs fixings :

153 + legacy_default_stream(buffer_stream),

Since the notion of "default stream" is not going away, we should just call it "default_stream".
-------------------------------------------

209 + auto resize_event = mir_event_get_resize_event(&e);
210 + size = { mir_resize_event_get_width(resize_event), mir_resize_event_get_height(resize_event) };
211 + if (legacy_default_stream)
212 + legacy_default_stream->set_size(size);

The if statement should enclose the whole thing as it only makes sense when there is a default stream.

review: Needs Fixing
Revision history for this message
Kevin DuBois (kdub) wrote :

can add some deprecated tags to discourage use in the headers.

re legacy_default_stream, I think tagging legacy_ on front indicates that this bit of functionality is really only around for legacy purposes. Its not going away yet, but it is still around for legacy reasons. OTOH, its an internal member variable, so will change name and add comment to this effect.

The size member variable is used in get_parameters, and should be changed when the resize event occurs.

Revision history for this message
Cemil Azizoglu (cemil-azizoglu) wrote :

LGTM

review: Approve
Revision history for this message
Mir CI Bot (mir-ci-bot) wrote :

FAILED: Autolanding.
More details in the following jenkins job:
https://mir-jenkins.ubuntu.com/job/mir-autolanding/269/
Executed test runs:
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-mir/1081/console
    None: https://mir-jenkins.ubuntu.com/job/generic-land-mp/291/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-0-fetch/1129
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/1120
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial/1120
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=vivid+overlay/1091/console
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial/1091/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1091
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1091/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1091
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1091/artifact/output/*zip*/output.zip
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial/1091/console

review: Needs Fixing (continuous-integration)
Revision history for this message
Mir CI Bot (mir-ci-bot) wrote :

FAILED: Continuous integration, rev:3506
https://mir-jenkins.ubuntu.com/job/mir-ci/998/
Executed test runs:
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-mir/1084/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-0-fetch/1132
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/1123
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial/1123
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=vivid+overlay/1094/console
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial/1094/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1094
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1094/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1094
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1094/artifact/output/*zip*/output.zip
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial/1094/console

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

review: Needs Fixing (continuous-integration)
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

A few failures:

16:48:22 9: [ FAILED ] 3 tests, listed below:
16:48:22 9: [ FAILED ] ServerStartup.creates_endpoint_on_filesystem
16:48:22 9: [ FAILED ] ServerStartup.after_server_sigkilled_can_start_new_instance
16:48:22 9: [ FAILED ] UnresponsiveClient.does_not_hang_server

They are not pre-existing bugs or known failures...

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Just a reminder - the CI failures appear to be consistent and unique to this branch. So I guess the branch is faulty.

review: Needs Fixing
Revision history for this message
Mir CI Bot (mir-ci-bot) wrote :

FAILED: Continuous integration, rev:3508
https://mir-jenkins.ubuntu.com/job/mir-ci/1110/
Executed test runs:
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-mir/1229/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-0-fetch/1279
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/1270
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial/1270
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=vivid+overlay/1239/console
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial/1239/console
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1239
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1239/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1239
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1239/artifact/output/*zip*/output.zip
    FAILURE: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial/1239/console

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

review: Needs Fixing (continuous-integration)
Revision history for this message
Daniel van Vugt (vanvugt) :
review: Abstain
Revision history for this message
Kevin DuBois (kdub) wrote :

CI was ran against rev3508... rev3509 has fix for valgrind+ci.

Revision history for this message
Mir CI Bot (mir-ci-bot) wrote :

PASSED: Continuous integration, rev:3509
https://mir-jenkins.ubuntu.com/job/mir-ci/1112/
Executed test runs:
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-mir/1231
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-0-fetch/1281
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/1272
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial/1272
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=vivid+overlay/1241
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=vivid+overlay/1241/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial/1241
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial/1241/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1241
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/1241/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1241
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/1241/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial/1241
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial/1241/artifact/output/*zip*/output.zip

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

review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches