LWN.net Logo

Ubuntu unveils its next-generation shell and display server

Ubuntu unveils its next-generation shell and display server

Posted Mar 7, 2013 2:23 UTC (Thu) by hoegsberg (guest, #57768)
In reply to: Ubuntu unveils its next-generation shell and display server by neilbrown
Parent article: Ubuntu unveils its next-generation shell and display server

We have a "wl_shell" interface in the wayland protocol, which provides the means by which applications set window titles, icons, go fullscreen, pop up menus. This interface is not privileged, it's available to all clients.

We have another interface called "desktop_shell". This is a weston specific, private interface, only available to a special helper client that weston launches. This client provides the background and panel surface back to weston through this interface. Similarly, our input method helper is launched by weston and injects input events back into weston using a privileged interface only available to that client.

The way we've split weston into different processes is not a requirement of wayland. The wayland protocol and core libraries doesn't dictate that a compositor should split all UI into external processes. Weston works that way because we don't have a toolkit inside weston. On the other hand, GNOME Shell, for example, uses clutter inside the compositor and can do much UI in the compositor process as a wayland compositor.

The Unity/Mir developers want to build the Unity UI into the compositor (as explained in the UDS Mir video), similar to how GNOME Shell would work. Their concern about the privileged shell interface and external helper clients seems to be that they think it's the only way to structure a wayland compositor.


(Log in to post comments)

Ubuntu unveils its next-generation shell and display server

Posted Mar 7, 2013 2:44 UTC (Thu) by neilbrown (subscriber, #359) [Link]

Thanks. That's very helpful.

If I might summarize:
- All *wayland* APIs are non-privileged. However they do not allow you to implement (e.g.) a panel or screen saver.
- Weston has a private and privileged API which can be used to implement a panel etc.

The (current) MirSpec says two things about "privilege".
Firstly "We want to avoid exposing any sort of privileged protocol to client applications." Neither Wayland or Weston do this anyway. Weston only exposes a privileged API to processes that it executes directly.

Secondly "As another example, we consider the shell integration parts of the protocol as privileged and we'd rather avoid having any sort of shell behavior defined in the client facing protocol."
I'm not really sure what this means. It could be taken to say "Stuff like wl_shell should be privileged", but that contradicts the earlier point, so is unlikely to be the intention. So it probably means "desktop_shell" shouldn't be part of the client-facing protocol, and that is exactly the case - it isn't.
So I agree that they seem to be confused. I wonder if anyone from Mir is reading and cares to comment.

"wl_shell" is and should be unprivileged.
"desktop_shell" is an implementation detail of weston, and is not client-facing so questions of privilege are irrelevant.

Thanks.

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds