target/sparc: Check for transaction failures in MMU passthrough ASIs
[qemu/ar7.git] / docs / interop / vhost-user.json
blobda6aaf51c889a966bdcad12d8a59143addce0f13
1 # -*- Mode: Python -*-
3 # Copyright (C) 2018 Red Hat, Inc.
5 # Authors:
6 #  Marc-AndrĂ© Lureau <marcandre.lureau@redhat.com>
8 # This work is licensed under the terms of the GNU GPL, version 2 or
9 # later. See the COPYING file in the top-level directory.
12 # = vhost user backend discovery & capabilities
16 # @VHostUserBackendType:
18 # List the various vhost user backend types.
20 # @9p: 9p virtio console
21 # @balloon: virtio balloon
22 # @block: virtio block
23 # @caif: virtio caif
24 # @console: virtio console
25 # @crypto: virtio crypto
26 # @gpu: virtio gpu
27 # @input: virtio input
28 # @net: virtio net
29 # @rng: virtio rng
30 # @rpmsg: virtio remote processor messaging
31 # @rproc-serial: virtio remoteproc serial link
32 # @scsi: virtio scsi
33 # @vsock: virtio vsock transport
35 # Since: 4.0
38   'enum': 'VHostUserBackendType',
39   'data': [
40       '9p',
41       'balloon',
42       'block',
43       'caif',
44       'console',
45       'crypto',
46       'gpu',
47       'input',
48       'net',
49       'rng',
50       'rpmsg',
51       'rproc-serial',
52       'scsi',
53       'vsock'
54   ]
58 # @VHostUserBackendInputFeature:
60 # List of vhost user "input" features.
62 # @evdev-path: The --evdev-path command line option is supported.
63 # @no-grab: The --no-grab command line option is supported.
65 # Since: 4.0
68   'enum': 'VHostUserBackendInputFeature',
69   'data': [ 'evdev-path', 'no-grab' ]
73 # @VHostUserBackendCapabilitiesInput:
75 # Capabilities reported by vhost user "input" backends
77 # @features: list of supported features.
79 # Since: 4.0
82   'struct': 'VHostUserBackendCapabilitiesInput',
83   'data': {
84     'features': [ 'VHostUserBackendInputFeature' ]
85   }
89 # @VHostUserBackendGPUFeature:
91 # List of vhost user "gpu" features.
93 # @render-node: The --render-node command line option is supported.
94 # @virgl: The --virgl command line option is supported.
96 # Since: 4.0
99   'enum': 'VHostUserBackendGPUFeature',
100   'data': [ 'render-node', 'virgl' ]
104 # @VHostUserBackendCapabilitiesGPU:
106 # Capabilities reported by vhost user "gpu" backends.
108 # @features: list of supported features.
110 # Since: 4.0
113   'struct': 'VHostUserBackendCapabilitiesGPU',
114   'data': {
115     'features': [ 'VHostUserBackendGPUFeature' ]
116   }
120 # @VHostUserBackendCapabilities:
122 # Capabilities reported by vhost user backends.
124 # @type: The vhost user backend type.
126 # Since: 4.0
129   'union': 'VHostUserBackendCapabilities',
130   'base': { 'type': 'VHostUserBackendType' },
131   'discriminator': 'type',
132   'data': {
133     'input': 'VHostUserBackendCapabilitiesInput',
134     'gpu': 'VHostUserBackendCapabilitiesGPU'
135   }
139 # @VhostUserBackend:
141 # Describes a vhost user backend to management software.
143 # It is possible for multiple @VhostUserBackend elements to match the
144 # search criteria of management software. Applications thus need rules
145 # to pick one of the many matches, and users need the ability to
146 # override distro defaults.
148 # It is recommended to create vhost user backend JSON files (each
149 # containing a single @VhostUserBackend root element) with a
150 # double-digit prefix, for example "50-qemu-gpu.json",
151 # "50-crosvm-gpu.json", etc, so they can be sorted in predictable
152 # order. The backend JSON files should be searched for in three
153 # directories:
155 #   - /usr/share/qemu/vhost-user -- populated by distro-provided
156 #                                   packages (XDG_DATA_DIRS covers
157 #                                   /usr/share by default),
159 #   - /etc/qemu/vhost-user -- exclusively for sysadmins' local additions,
161 #   - $XDG_CONFIG_HOME/qemu/vhost-user -- exclusively for per-user local
162 #                                         additions (XDG_CONFIG_HOME
163 #                                         defaults to $HOME/.config).
165 # Top-down, the list of directories goes from general to specific.
167 # Management software should build a list of files from all three
168 # locations, then sort the list by filename (i.e., basename
169 # component). Management software should choose the first JSON file on
170 # the sorted list that matches the search criteria. If a more specific
171 # directory has a file with same name as a less specific directory,
172 # then the file in the more specific directory takes effect. If the
173 # more specific file is zero length, it hides the less specific one.
175 # For example, if a distro ships
177 #   - /usr/share/qemu/vhost-user/50-qemu-gpu.json
179 #   - /usr/share/qemu/vhost-user/50-crosvm-gpu.json
181 # then the sysadmin can prevent the default QEMU GPU being used at all with
183 #   $ touch /etc/qemu/vhost-user/50-qemu-gpu.json
185 # The sysadmin can replace/alter the distro default QEMU GPU with
187 #   $ vim /etc/qemu/vhost-user/50-qemu-gpu.json
189 # or they can provide a parallel QEMU GPU with higher priority
191 #   $ vim /etc/qemu/vhost-user/10-qemu-gpu.json
193 # or they can provide a parallel QEMU GPU with lower priority
195 #   $ vim /etc/qemu/vhost-user/99-qemu-gpu.json
197 # @type: The vhost user backend type.
199 # @description: Provides a human-readable description of the backend.
200 #               Management software may or may not display @description.
202 # @binary: Absolute path to the backend binary.
204 # @tags: An optional list of auxiliary strings associated with the
205 #        backend for which @description is not appropriate, due to the
206 #        latter's possible exposure to the end-user. @tags serves
207 #        development and debugging purposes only, and management
208 #        software shall explicitly ignore it.
210 # Since: 4.0
212 # Example:
214 # {
215 #   "description": "QEMU vhost-user-gpu",
216 #   "type": "gpu",
217 #   "binary": "/usr/libexec/qemu/vhost-user-gpu",
218 #   "tags": [
219 #     "CONFIG_OPENGL_DMABUF=y"
220 #   ]
221 # }
225   'struct' : 'VhostUserBackend',
226   'data'   : {
227     'description': 'str',
228     'type': 'VHostUserBackendType',
229     'binary': 'str',
230     '*tags': [ 'str' ]
231   }