D14910: Pass a dedicated fd to each keyboard for the xkb keymap

Martin Flöser noreply at phabricator.kde.org
Fri Aug 17 20:20:37 BST 2018


graesslin created this revision.
graesslin added reviewers: KWin, Frameworks, davidedmundson.
Herald added a project: Frameworks.
Herald added a subscriber: kde-frameworks-devel.
graesslin requested review of this revision.

REVISION SUMMARY
  To better isolate the clients from each other eachh KeyboardInterface
  creates it's own dedicated temporary file and sends the fd for this
  temporary file to the client. This means the memory for the keymap is no
  longer shared between all clients, every client has an own copy.
  
  To support this the existing API to set the keymap is deprecated and
  replaced by a new method setKeymapData which takes the content of the
  keymap as a byte array. The now deprecated method which takes a file
  descriptor is changed to use the new setKeymapData method. For that it
  reads the content of the file.
  
  The implementation in KeyboardInterface to create the file descriptor is
  based on the implementation of KWin. As I implemented the change in KWin
  (see 3b4c508ee36ac74c37e77fcaa14d106397ad2994 <https://phabricator.kde.org/R108:3b4c508ee36ac74c37e77fcaa14d106397ad2994>) it is not a problem from
  GPL vs LGPL perspective.
  
  The change includes test cases to verify that the content of the keymap
  is properly passed to the client and that the memory is no longer shared.
  
  BUG: 381674

REPOSITORY
  R127 KWayland

REVISION DETAIL
  https://phabricator.kde.org/D14910

AFFECTED FILES
  autotests/client/test_wayland_seat.cpp
  src/server/keyboard_interface.cpp
  src/server/keyboard_interface.h
  src/server/keyboard_interface_p.h
  src/server/seat_interface.cpp
  src/server/seat_interface.h
  src/server/seat_interface_p.h

To: graesslin, #kwin, #frameworks, davidedmundson
Cc: kde-frameworks-devel, michaelh, ngraham, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20180817/4989dacc/attachment.html>


More information about the Kde-frameworks-devel mailing list