Re: Lightweight desktop environments for Wayland?

2017-09-26 Thread Carsten Haitzler
On Tue, 5 Sep 2017 22:04:38 +0800 lan lan said: > Hi, > > weston doesn't seem to have any kind of "settings manager", regular > desktop controls, > or task-bar. Is there a lightweight desktop environments for Wayland? Probably the lightest weight might be enlightenment

Re: XDC 2017 feedback

2017-09-26 Thread Manasi Navare
Hi, XDC was a really great conference and loved the fact that it was in just one room which kept all the hallway conversations in that room resulting into more networking. But I agree with Andres that for the videos, it would be great to split the huge youtube video stream per presentation and

Re: [PATCH weston v12 26/40] compositor-drm: Extract drm_fb_addfb into a helper

2017-09-26 Thread Prabhu S
Any plan to support for drmModeAddFB2WithModifiers and query preferred FB modifier? On Tue, Sep 26, 2017 at 12:15 PM, Daniel Stone wrote: > We currently do the same thing in two places, and will soon have a > third. > > Signed-off-by: Daniel Stone

[PATCH weston v12 39/40] compositor-drm: Support plane IN_FORMATS

2017-09-26 Thread Daniel Stone
From: Sergi Granell The per-plane IN_FORMATS property adds information about format modifiers; we can use these to both feed GBM with the set of modifiers we want to use for rendering, and also as an early-out test when we're trying to see if a FB will go on a particular

[PATCH weston v12 26/40] compositor-drm: Extract drm_fb_addfb into a helper

2017-09-26 Thread Daniel Stone
We currently do the same thing in two places, and will soon have a third. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 93 -- 1 file changed, 48 insertions(+), 45 deletions(-) diff --git

[PATCH weston v12 20/40] [XXX] compositor-drm: Only disallow scaling for overlay planes

2017-09-26 Thread Daniel Stone
Now we have a more comprehensive overview of the transform we're going to apply, use this to explicitly disallow scaling and rotation. XXX: This does not actually disallow rotation for square surfaces. We would have to build up a full buffer->view->output transform matrix, and then

[PATCH weston v12 00/40] Atomic modesetting

2017-09-26 Thread Daniel Stone
Hi, Here's a cleaned-up and fully-tested version of the atomic series. I'm fairly happy with it now. There are a few things I'd want to change, but figured I'd send it all out now rather than waiting another however long: * I'd rather track unused_{crtcs,connectors} by putting them all in

[PATCH weston v12 29/40] compositor-drm: Don't need safe view-list traversal

2017-09-26 Thread Daniel Stone
Nothing in this loop reorders views within the compositor's view_list. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libweston/compositor-drm.c b/libweston/compositor-drm.c index

[PATCH weston v12 14/40] compositor-drm: Add to_drm_mode helper

2017-09-26 Thread Daniel Stone
Much like we already have to_drm_output and to_drm_backend. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/libweston/compositor-drm.c b/libweston/compositor-drm.c index

[PATCH weston v12 09/40] compositor-drm: Move repaint state application to flush

2017-09-26 Thread Daniel Stone
Split repaint into two stages, as implied by the grouped-repaint interface: drm_output_repaint generates the repaint state only, and drm_repaint_flush applies it. This also moves DPMS into output state. Previously, the usual way to DPMS off was that repaint would be called and apply its state,

[PATCH weston v12 15/40] compositor-drm: Atomic modesetting support

2017-09-26 Thread Daniel Stone
Add support for using the atomic-modesetting API to apply output state. Unlike previous series, this commit does not unflip sprites_are_broken, until further work has been done with assign_planes to make it reliable. Signed-off-by: Daniel Stone Co-authored-by: Pekka

[PATCH weston v12 31/40] compositor-drm: Split drm_assign_planes in two

2017-09-26 Thread Daniel Stone
Move drm_assign_planes into two functions: one which proposes a plane configuration, and another which applies that state to the Weston internal structures. This will be used to try multiple configurations and see which is supported. Signed-off-by: Daniel Stone ---

[PATCH weston v12 24/40] compositor-drm: Use plane FB-import helper for scanout

2017-09-26 Thread Daniel Stone
Use the same codepath, which has the added advantage of being able to import dmabufs. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 62 +- 1 file changed, 12 insertions(+), 50 deletions(-) diff --git

[PATCH weston v12 21/40] compositor-drm: Use plane_state_coords_for_view for scanout

2017-09-26 Thread Daniel Stone
Use the shiny new helper we have for working through scanout as well. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 66 -- 1 file changed, 23 insertions(+), 43 deletions(-) diff --git a/libweston/compositor-drm.c

[PATCH weston v12 35/40] compositor-drm: Return plane state from plane preparation

2017-09-26 Thread Daniel Stone
Return a pointer to the plane state, rather than indirecting via a weston_plane. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 73 ++ 1 file changed, 42 insertions(+), 31 deletions(-) diff --git

[PATCH weston v12 22/40] compositor-drm: Use plane_coords_for_view for cursor

2017-09-26 Thread Daniel Stone
Use the new helper to populate the cursor state as well, with some special-case handling to account for how we always upload a full-size BO. Signed-off-by: Daniel Stone Reported-by: Derek Foreman --- libweston/compositor-drm.c | 48

[PATCH weston v12 16/40] compositor-drm: Allow disabling atomic

2017-09-26 Thread Daniel Stone
Add a test environment variable to allow disabling atomic modesetting. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/libweston/compositor-drm.c b/libweston/compositor-drm.c index

[PATCH weston v12 38/40] compositor-drm: Enable planes for atomic

2017-09-26 Thread Daniel Stone
Now that we can sensibly test proposed plane configurations with atomic, sprites are not broken. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 22 +++--- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git

[PATCH weston v12 34/40] compositor-drm: Add modes to drm_output_propose_state

2017-09-26 Thread Daniel Stone
Add support for multiple modes: toggling whether or not the renderer and/or planes are acceptable. This will be used to implement a smarter plane-placement heuristic when we have support for testing output states. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c

[PATCH weston v12 32/40] compositor-drm: Ignore views on other outputs

2017-09-26 Thread Daniel Stone
When we come to assign_planes, try very hard to ignore views which are only visible on other outputs, rather than forcibly moving them to the primary plane, which causes damage all round and unnecessary repaints. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c

[PATCH weston v12 40/40] compositor-drm: Support modifiers with GBM

2017-09-26 Thread Daniel Stone
Use the extended GBM allocator interface to support modifiers and multi-planar BOs. Depends on bwidawsk's 'modifiers' tree. Signed-off-by: Daniel Stone --- configure.ac | 3 +++ libweston/compositor-drm.c | 57 ++

[PATCH weston v12 27/40] compositor-drm: Add modifiers to GBM dmabuf import

2017-09-26 Thread Daniel Stone
Add support for the GBM_BO_IMPORT_FD_MODIFIER path, which allows us to import multi-plane dmabufs, as well as format modifiers. Signed-off-by: Daniel Stone --- configure.ac | 3 - libweston/compositor-drm.c | 181

[PATCH weston v12 25/40] compositor-drm: Remove no_addfb2 handling

2017-09-26 Thread Daniel Stone
If AddFB2 ever fails for any reason, we fall back to legacy AddFB, which doesn't support the same swathe of formats, or multi-planar formats, or modifiers. This can happen with arbitrary client buffers, condemning us to the fallback forever more. Remove this, at the cost of an unnecessary ioctl

[PATCH weston v12 19/40] compositor-drm: Fully account for buffer transformation

2017-09-26 Thread Daniel Stone
In our new and improved helper to determine the src/dest values for a buffer on a given plane, make sure we account for all buffer transformations, including viewport clipping. Rather than badly open-coding it ourselves, just use the helper which does exactly this. Signed-off-by: Daniel Stone

[PATCH weston v12 17/40] compositor-drm: Make alpha-to-opaque handling common

2017-09-26 Thread Daniel Stone
Rather than a hardcoded ARGB -> XRGB translation inside a GBM-specific helper, just determine whether or not the view is opaque, and use the generic helpers to implement the format translation. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 111

[PATCH weston v12 28/40] compositor-drm: Support modifiers for drm_fb

2017-09-26 Thread Daniel Stone
Use the new drmModeAddFB2WithModifiers interface to import buffers with modifiers. Signed-off-by: Daniel Stone --- configure.ac | 3 +++ libweston/compositor-drm.c | 28 ++-- 2 files changed, 29 insertions(+), 2 deletions(-) diff

[PATCH weston v12 37/40] compositor-drm: Relax plane restrictions for atomic

2017-09-26 Thread Daniel Stone
Since we now incrementally test atomic state as we build it, we can loosen restrictions on what we can do with planes, and let the kernel tell us whether or not it's OK. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 22 ++ 1 file

[PATCH weston v12 36/40] compositor-drm: Add test-only mode to state application

2017-09-26 Thread Daniel Stone
The atomic API can allow us to test state before we apply it, to see if it will be valid. Add support for this, which we will later use in assign_planes to ensure our plane configuration is valid. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 180

[PATCH weston v12 30/40] compositor-drm: Rename region variable

2017-09-26 Thread Daniel Stone
Make it a bit more clear what the purpose of the variable is. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/libweston/compositor-drm.c b/libweston/compositor-drm.c index

[PATCH weston v12 13/40] compositor-drm: Add blob_id member to drm_mode

2017-09-26 Thread Daniel Stone
For atomic modesetting support, the mode is identified by a blob property ID, rather than being passed inline. Add a blob_id member to drm_mode to handle this, including refactoring mode destruction into a helper function. Signed-off-by: Daniel Stone ---

[PATCH weston v12 12/40] compositor-drm: Discover atomic properties

2017-09-26 Thread Daniel Stone
From: Pekka Paalanen Set the atomic client cap, where it exists, and use this to discover the plane/CRTC/connector properties we require for atomic modesetting. Signed-off-by: Daniel Stone Co-authored-by: Pekka Paalanen

[PATCH weston v12 05/40] compositor-drm: Use drm_plane for scanout plane

2017-09-26 Thread Daniel Stone
Use a real drm_plane to back the scanout plane, displacing output->fb_{last,cur,pending} to their plane-tracked equivalents. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 167 +++-- 1 file changed, 101 insertions(+),

[PATCH weston v12 33/40] compositor-drm: Ignore occluded views

2017-09-26 Thread Daniel Stone
When trying to assign planes, keep track of the areas which are already occluded, and ignore views which are completely occluded. This allows us to build a state using planes only, when there are occluded views which cannot go into a plane behind views which can. Signed-off-by: Daniel Stone

[PATCH weston v12 18/40] compositor-drm: Extract buffer->plane co-ord translation

2017-09-26 Thread Daniel Stone
Pull this into a helper function, so we can use it everywhere. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 157 + 1 file changed, 88 insertions(+), 69 deletions(-) diff --git a/libweston/compositor-drm.c

[PATCH weston v12 11/40] compositor-drm: Don't restore original CRTC mode

2017-09-26 Thread Daniel Stone
When leaving Weston, don't attempt to restore the previous CRTC settings. The framebuffer may well have disappeared, and in every likelihood, whoever gets the KMS device afterwards will be repainting anyway. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 26

[PATCH weston v12 07/40] compositor-drm: Track unused connectors and CRTCs

2017-09-26 Thread Daniel Stone
Rather than a more piecemeal approach at backend creation, explicitly track connectors and CRTCs we do not intend to use, so we can ensure they are disabled where appropriate. Signed-off-by: Daniel Stone Reviewed-by: Pekka Paalanen ---

[PATCH weston v12 08/40] compositor-drm: Disable unused CRTCs/connectors

2017-09-26 Thread Daniel Stone
If we have an unused CRTC or connector, explicitly disable it during the end of the repaint cycle, or when we get VT-switched back in. Signed-off-by: Daniel Stone Reviewed-by: Pekka Paalanen --- libweston/compositor-drm.c | 60

[PATCH weston v12 02/40] compositor-drm: Introduce drm_plane_state structure

2017-09-26 Thread Daniel Stone
Track dynamic plane state (CRTC, FB, position) in separate structures, rather than as part of the plane. This will make it easier to handle state management later, and much more closely tracks what the kernel does with atomic modesets. The fb_last pointer previously used in drm_plane now becomes

[PATCH weston v12 06/40] compositor-drm: Don't repaint if no damage

2017-09-26 Thread Daniel Stone
If we don't have any damage for the primary plane, then don't force a repaint; simply reuse the old buffer we already have. Signed-off-by: Daniel Stone Reviewed-by: Pekka Paalanen --- libweston/compositor-drm.c | 15 +-- 1 file

[PATCH weston v12 03/40] [TEST] compositor-drm: Allow disabling universal planes

2017-09-26 Thread Daniel Stone
Add a test environment variable to allow disabling universal planes. Signed-off-by: Daniel Stone --- libweston/compositor-drm.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libweston/compositor-drm.c b/libweston/compositor-drm.c index

[PATCH weston v12 01/40] compositor-drm: Introduce drm_output_state structure

2017-09-26 Thread Daniel Stone
Currently this doesn't actually really do anything, but will be used in the future to track the state for both modeset and repaint requests. Completion of the request gives us a single request-completion path for both pageflip and vblank events. This merges the timing paths for scanout and

[PATCH weston v12 04/40] compositor-drm: Use drm_plane for cursor plane

2017-09-26 Thread Daniel Stone
Change the type of cursor_plane from a weston_plane (base tracking structure) to a drm_plane (wrapper containing additional DRM-specific details), and make it a dynamically-allocated pointer. Using the standard drm_plane allows us to reuse code which already deals with drm_planes, e.g. a common

XDC 2017 feedback

2017-09-26 Thread Daniel Vetter
Hi all, First again big thanks to Stéphane and Jennifer for organizing a great XDC. Like last year we'd like to hear feedback on how this year's XDC went, both the good (and what you'd like to see more of) and the not so good. Talk selection, organization, location, scheduling of talks, anything

Re: [PATCH v2] compositor: fix starvation of wl_buffer::release

2017-09-26 Thread Derek Foreman
On 2017-09-26 09:23 AM, Pekka Paalanen wrote: On Tue, 26 Sep 2017 14:26:36 +0100 Daniel Stone wrote: On 26 September 2017 at 14:09, Matt Hoosier wrote: This change replaces a queued emission of buffer-release events (which is prone to

Re: [PATCH] xdg-foreign-v2: Fix various documentation issues from the API change

2017-09-26 Thread Marco Martin
Changes look fine to me, in the end my patches would be pushed as is and then this one pushed on top, right? -- Marco Martin On Tue, Sep 26, 2017 at 3:53 PM, Jonas Ådahl wrote: > It stilled referred to the removed requests, so change those places to > refer to the renamed

Re: connection: add sanity check to avoid buffer overflow

2017-09-26 Thread Sergi Granell
On Thu, 2017-09-14 at 09:21 +0900, Boram Park wrote: > Before putting data into a buffer, we have to make sure that the data > size is > smaller than not only the buffer's full size but also the buffer's empty > size. > > https://bugs.freedesktop.org/show_bug.cgi?id=102690 > > Signed-off-by:

Re: [PATCH v2] compositor: fix starvation of wl_buffer::release

2017-09-26 Thread Pekka Paalanen
On Tue, 26 Sep 2017 14:26:36 +0100 Daniel Stone wrote: > On 26 September 2017 at 14:09, Matt Hoosier wrote: > > This change replaces a queued emission of buffer-release events (which > > is prone to starvation) with a regular event emission. This

Re: [PATCH 5/6] libweston: fbdev: Attempt to detect the first framebuffer device in the seat. instead of defaulting to /dev/fb0

2017-09-26 Thread Pekka Paalanen
On Wed, 6 Sep 2017 08:17:22 -0400 nerdopolis wrote: > --- > libweston/compositor-fbdev.c | 35 +-- > 1 file changed, 33 insertions(+), 2 deletions(-) > > diff --git a/libweston/compositor-fbdev.c b/libweston/compositor-fbdev.c >

[PATCH] xdg-foreign-v2: Fix various documentation issues from the API change

2017-09-26 Thread Jonas Ådahl
It stilled referred to the removed requests, so change those places to refer to the renamed ones. While at it, also change documentation to refer directly to xdg_toplevel, as that has now been introduced. Signed-off-by: Jonas Ådahl --- Hi, On Tue, Sep 26, 2017 at 03:06:05PM

Re: [PATCH 4/6] libweston: fbdev: set fb device info upon the first run.

2017-09-26 Thread Pekka Paalanen
On Thu, 14 Sep 2017 23:08:51 -0400 nerdopolis wrote: > On Wednesday, September 6, 2017 8:17:21 AM EDT nerdopolis wrote: > > This attempts to wake up secondary framebuffer devices > > (/dev/fb1 and up) as usually these devices start powered off, and > > the

Re: [PATCH 3/6] launcher-logind: only get a VT on seat0, as only seat0 supports VTs

2017-09-26 Thread Pekka Paalanen
On Wed, 6 Sep 2017 08:17:20 -0400 nerdopolis wrote: > --- > libweston/launcher-logind.c | 22 -- > 1 file changed, 12 insertions(+), 10 deletions(-) > Hi, I think this patch is good. Logind does everything around VT management, right? So

Re: [PATCH v2] compositor: fix starvation of wl_buffer::release

2017-09-26 Thread Daniel Stone
On 26 September 2017 at 14:09, Matt Hoosier wrote: > This change replaces a queued emission of buffer-release events (which > is prone to starvation) with a regular event emission. This means that > client programs no longer need to secretly install surface frame >

Re: [PATCH] compositor: fix starvation of wl_buffer::release

2017-09-26 Thread Matt Hoosier
Done: https://lists.freedesktop.org/archives/wayland-devel/2017-September/035191.html On Tue, Sep 26, 2017 at 2:28 AM, Pekka Paalanen wrote: > On Mon, 25 Sep 2017 10:31:35 -0500 > Matt Hoosier wrote: > >> This change replaces a queued emission of

Re: [PATCH 2/6] libweston: fbdev: support the --seat option, (and XDG_SEAT variable)

2017-09-26 Thread Pekka Paalanen
On Wed, 6 Sep 2017 08:17:19 -0400 nerdopolis wrote: > --- Hi, the commit message is missing a rationale and Signed-off-by. > compositor/main.c| 2 ++ > libweston/compositor-fbdev.c | 5 - > libweston/compositor-fbdev.h | 1 + > 3 files

Re: [PATCH 1/6] libweston: set the seat automatically based on the XDG_SEAT environment variable

2017-09-26 Thread Pekka Paalanen
On Wed, 6 Sep 2017 08:17:18 -0400 nerdopolis wrote: > --- Hi, the commit message should contain at least briefly why we want this. I have a feeling this is the right thing to do, but I can't quite put the reason into words myself. We would also prefer a

[PATCH v2] compositor: fix starvation of wl_buffer::release

2017-09-26 Thread Matt Hoosier
This change replaces a queued emission of buffer-release events (which is prone to starvation) with a regular event emission. This means that client programs no longer need to secretly install surface frame listeners just to guarantee that they get correctly notified of buffer lifecycle events.

Re: [PATCH 2/2] foreignv2: rename export and import calls

2017-09-26 Thread Marco Martin
ping? On Mon, Sep 18, 2017 at 2:09 PM, Marco Martin wrote: > as export is a reserved keyword in C++, in order for the > output generated by wayland_scanner to compile correctly > rename export to export_toplevel and import to import_toplevel > this needs a new protocol version

Re: [PATCH weston v2 3/4] libweston: Add check and fallback for linux/sync_file.h

2017-09-26 Thread Pekka Paalanen
On Tue, 19 Sep 2017 14:59:10 +0300 Alexandros Frantzis wrote: > The sync file functionality is required by the upcoming GPU render > timeline work, but it's only available in relatively new linux kernel > versions (4.7 and above). > > This commit provides an

Re: [PATCH weston 05/21] libweston: weston_output_init(..., +name)

2017-09-26 Thread Hardening
Le 22/09/2017 à 16:31, Pekka Paalanen a écrit : > From: Pekka Paalanen > > Add 'name' argument to weston_output_init(). This is much more obvious > than the assert inside weston_output_init() to ensure the caller has set > a field in weston_output first. > > Now

Re: [PATCH] compositor: fix starvation of wl_buffer::release

2017-09-26 Thread Pekka Paalanen
On Mon, 25 Sep 2017 10:31:35 -0500 Matt Hoosier wrote: > This change replaces a queued emission of buffer-release events (which > is prone to starvation) with a regular event emission. This means that > client programs no longer need to secretly install surface frame >

Re: [PATCH weston 01/21] libweston: move weston_output::mode_list init to core

2017-09-26 Thread Ray, Ian (GE Healthcare)
On 22/09/2017, 17.32, "wayland-devel on behalf of Pekka Paalanen" wrote: > > From: Pekka Paalanen > > Initialize the list in weston_output_init() instead of doing it > separately in

Re: [PATCH weston 16/21] compositor-fbdev: always destroy renderer-output on disable

2017-09-26 Thread Ray, Ian (GE Healthcare)
On 22/09/2017, 17.33, "wayland-devel on behalf of Pekka Paalanen" wrote: > > From: Pekka Paalanen > > If we pass the base->enabled test, then the renderer output is > guaranteed to

Re: [PATCH weston 15/21] compositor-fbdev: simplify FB destroy/unmap/disable

2017-09-26 Thread Ray, Ian (GE Healthcare)
On 22/09/2017, 17.33, "wayland-devel on behalf of Pekka Paalanen" wrote: > > From: Pekka Paalanen > > Rename fbdev_frame_buffer_destroy() to fbdev_frame_buffer_unmap() > because that

Re: [PATCH weston 12/21] libweston: set backend pointer earlier

2017-09-26 Thread Ray, Ian (GE Healthcare)
On 22/09/2017, 17.33, "wayland-devel on behalf of Pekka Paalanen" wrote: > > From: Pekka Paalanen > > Change all backends to set the core backend pointer early. > > This is

Re: [PATCH weston 11/21] libweston: ensure backend is not loaded twice

2017-09-26 Thread Ray, Ian (GE Healthcare)
On 22/09/2017, 17.33, "wayland-devel on behalf of Pekka Paalanen" wrote: > > From: Pekka Paalanen > > Check and ensure that a compositor can only load one backend > successfully. If

Re: [PATCH weston 10/21] libweston: rename weston_output_destroy() to weston_output_release()

2017-09-26 Thread Ray, Ian (GE Healthcare)
On 22/09/2017, 17.33, "wayland-devel on behalf of Pekka Paalanen" wrote: > > From: Pekka Paalanen > > 'release' is a more appropriate name because the function does not free > the

Re: [PATCH weston 09/21] libweston: send more wl_surface.enter/leave events

2017-09-26 Thread Ray, Ian (GE Healthcare)
On 22/09/2017, 17.33, "wayland-devel on behalf of Pekka Paalanen" wrote: > > From: Pekka Paalanen > > A client may have bound the same wl_output multiple times, for who knows > what