[RFC PATCH spice-server v5 00/22] Allows guests to send display data as video streams

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This patcheset add a device to allow guest machines with assigned
hardware devices to send encoded video and other informations that
will be handled as a normal display by Spice.

New GPU devices are capable to capture and encode video in an
efficient way. As the GPU in this case is assigned to the guest
and not the host is easier if the guest do the hard job.

This patchset add a new "com.redhat.stream.0" device visible to
the guests. This device will be used by the guest to send streaming
data. The host will forward the data to the client.

To do so a new StreamChannel class, implementing the protocol
DisplayChannel is implemented.

Changes since git publish v4:
- improve commit messages;
- fixed some typos;
- do not send new channel list if channel list was
  never requested;
- allocate channel_info to pass channel list in the
  stack;
- pass a more accurate message to the guest in case of
  protocol problems;
- use always "dev" variable for consistency ("device"
  was also used);
- introduce a new reset_channels function;
- always use "id" parameter directly in cursor_channel_new;
- return true from stream device message handlers if
  message was completely readed;
- hope I handled all or at least most of the comments,
  was quite a huge list. Surely missing the change due
  to the red_channel_pipes_add proposal.

Changes since git publish v3:
- dynamically allocate channels. This solve the fixed ID
  problem and make easier in the future to implement
  multiple monitors. This required 2 additional patches,
  one to find next free ID and another that send new
  channel information to the client;
- fixed some typos;
- renamed "channel" field to "stream_channel" to avoid
  confusing them;
- updated commit messages.

Changes since git publish v2:
- define PRIMARY_SURFACE_ID mnemonic to make code more readable;
- renamed ask_new_stream to request_new_stream;
- miscellaneous comment updates;
- use NUM_STREAMS instead of fixed 40 value;
- pass time to StreamChannel sending data;
- add finalize method to free memory;
- add support for cursor move.

Frediano Ziglio (22):
  Avoid using global variable for channel IDs
  Notify client of the creation of new channels dynamically
  stream-device: Add device to handle streaming
  stream-device: Start parsing new protocol from guest
  stream-channel: Write a base channel to implement the streaming
  stream-channel: Start implementing DisplayChannel properly
  stream-device: Create channel for stream device
  stream-channel: Initialize blank display on client connection
  stream-device: Handle streaming data from device to channel
  stream-channel: Allows not fixed size
  stream-channel: Allows to register callback to get new stream request
  stream-channel: Support client connection/disconnection
  stream-channel: Do not show an empty blank screen on start
  char-device: Do not stop and clear interface on reset
  stream-device: Start supporting resetting device when close/open on
    guest
  stream-device: Create channel when needed
  stream-device: Limit sending queue from guest to server
  stream-channel: Activate streaming report from client
  cursor-channel: Allow to not handle a QXL device
  WIP stream-device: handle cursor from device
  WIP: Try to reduce delay
  stream-device: Implement mouse movement

 server/Makefile.am           |   3 +
 server/char-device.c         |   2 -
 server/char-device.h         |   1 +
 server/cursor-channel.c      |   8 +-
 server/cursor-channel.h      |   4 +-
 server/main-channel-client.c |  48 ++++
 server/main-channel-client.h |   3 +
 server/main-channel.c        |   6 +
 server/main-channel.h        |   3 +
 server/red-worker.c          |   2 +-
 server/reds.c                |  42 +++-
 server/reds.h                |   1 +
 server/spicevmc.c            |  10 +-
 server/stream-channel.c      | 575 +++++++++++++++++++++++++++++++++++++++++++
 server/stream-channel.h      |  82 ++++++
 server/stream-device.c       | 541 ++++++++++++++++++++++++++++++++++++++++
 16 files changed, 1320 insertions(+), 11 deletions(-)
 create mode 100644 server/stream-channel.c
 create mode 100644 server/stream-channel.h
 create mode 100644 server/stream-device.c

-- 
2.13.5

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]