From de74a22cc82dd40d63af399b81e40f56c8a9c535 Mon Sep 17 00:00:00 2001 From: Gerd Hoffmann Date: Wed, 19 May 2021 07:39:35 +0200 Subject: ui/vdagent: core infrastructure MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The vdagent protocol allows the guest agent (spice-vdagent) and the spice client exchange messages to implement features which require guest cooperation, for example clipboard support. This is a qemu implementation of the spice client side. This allows the spice guest agent talk to qemu directly when not using the spice protocol. usage: qemu \ -chardev qemu-vdagent,id=vdagent \ -device virtserialport,chardev=vdagent,name=com.redhat.spice.0 This patch adds just the protocol basics: initial handshake and capability negotiation. The following patches will add actual functionality and also add fields to the initially empty ChardevVDAgent qapi struct. Signed-off-by: Gerd Hoffmann Acked-by: Markus Armbruster Reviewed-by: Marc-André Lureau Message-id: 20210519053940.1888907-1-kraxel@redhat.com Message-Id: <20210519053940.1888907-5-kraxel@redhat.com> --- qapi/char.json | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'qapi') diff --git a/qapi/char.json b/qapi/char.json index 6413970fa7..990801e642 100644 --- a/qapi/char.json +++ b/qapi/char.json @@ -390,12 +390,25 @@ 'data': { '*size': 'int' }, 'base': 'ChardevCommon' } +## +# @ChardevQemuVDAgent: +# +# Configuration info for qemu vdagent implementation. +# +# Since: 6.1 +# +## +{ 'struct': 'ChardevQemuVDAgent', + 'data': { }, + 'base': 'ChardevCommon', + 'if': 'defined(CONFIG_SPICE_PROTOCOL)' } + ## # @ChardevBackend: # # Configuration info for the new chardev backend. # -# Since: 1.4 (testdev since 2.2, wctablet since 2.9) +# Since: 1.4 (testdev since 2.2, wctablet since 2.9, vdagent since 6.1) ## { 'union': 'ChardevBackend', 'data': { 'file': 'ChardevFile', @@ -417,6 +430,8 @@ 'if': 'defined(CONFIG_SPICE)' }, 'spiceport': { 'type': 'ChardevSpicePort', 'if': 'defined(CONFIG_SPICE)' }, + 'qemu-vdagent': { 'type': 'ChardevQemuVDAgent', + 'if': 'defined(CONFIG_SPICE_PROTOCOL)' }, 'vc': 'ChardevVC', 'ringbuf': 'ChardevRingbuf', # next one is just for compatibility -- cgit v1.2.3