target/mips: Use OPC_MUL instead of OPC__MXU_MUL
[qemu/ar7.git] / docs / interop / vhost-user.json
blobb6ade9e49315dd138680e4208533e6e97a2f2a97
1 # -*- Mode: Python -*-
2 # vim: filetype=python
4 # Copyright (C) 2018 Red Hat, Inc.
6 # Authors:
7 #  Marc-AndrĂ© Lureau <marcandre.lureau@redhat.com>
9 # This work is licensed under the terms of the GNU GPL, version 2 or
10 # later. See the COPYING file in the top-level directory.
13 # = vhost user backend discovery & capabilities
17 # @VHostUserBackendType:
19 # List the various vhost user backend types.
21 # @9p: 9p virtio console
22 # @balloon: virtio balloon
23 # @block: virtio block
24 # @caif: virtio caif
25 # @console: virtio console
26 # @crypto: virtio crypto
27 # @gpu: virtio gpu
28 # @input: virtio input
29 # @net: virtio net
30 # @rng: virtio rng
31 # @rpmsg: virtio remote processor messaging
32 # @rproc-serial: virtio remoteproc serial link
33 # @scsi: virtio scsi
34 # @vsock: virtio vsock transport
35 # @fs: virtio fs (since 4.2)
37 # Since: 4.0
40   'enum': 'VHostUserBackendType',
41   'data': [
42       '9p',
43       'balloon',
44       'block',
45       'caif',
46       'console',
47       'crypto',
48       'gpu',
49       'input',
50       'net',
51       'rng',
52       'rpmsg',
53       'rproc-serial',
54       'scsi',
55       'vsock',
56       'fs'
57   ]
61 # @VHostUserBackendBlockFeature:
63 # List of vhost user "block" features.
65 # @read-only: The --read-only command line option is supported.
66 # @blk-file: The --blk-file command line option is supported.
68 # Since: 5.0
71   'enum': 'VHostUserBackendBlockFeature',
72   'data': [ 'read-only', 'blk-file' ]
76 # @VHostUserBackendCapabilitiesBlock:
78 # Capabilities reported by vhost user "block" backends
80 # @features: list of supported features.
82 # Since: 5.0
85   'struct': 'VHostUserBackendCapabilitiesBlock',
86   'data': {
87     'features': [ 'VHostUserBackendBlockFeature' ]
88   }
92 # @VHostUserBackendInputFeature:
94 # List of vhost user "input" features.
96 # @evdev-path: The --evdev-path command line option is supported.
97 # @no-grab: The --no-grab command line option is supported.
99 # Since: 4.0
102   'enum': 'VHostUserBackendInputFeature',
103   'data': [ 'evdev-path', 'no-grab' ]
107 # @VHostUserBackendCapabilitiesInput:
109 # Capabilities reported by vhost user "input" backends
111 # @features: list of supported features.
113 # Since: 4.0
116   'struct': 'VHostUserBackendCapabilitiesInput',
117   'data': {
118     'features': [ 'VHostUserBackendInputFeature' ]
119   }
123 # @VHostUserBackendGPUFeature:
125 # List of vhost user "gpu" features.
127 # @render-node: The --render-node command line option is supported.
128 # @virgl: The --virgl command line option is supported.
130 # Since: 4.0
133   'enum': 'VHostUserBackendGPUFeature',
134   'data': [ 'render-node', 'virgl' ]
138 # @VHostUserBackendCapabilitiesGPU:
140 # Capabilities reported by vhost user "gpu" backends.
142 # @features: list of supported features.
144 # Since: 4.0
147   'struct': 'VHostUserBackendCapabilitiesGPU',
148   'data': {
149     'features': [ 'VHostUserBackendGPUFeature' ]
150   }
154 # @VHostUserBackendCapabilities:
156 # Capabilities reported by vhost user backends.
158 # @type: The vhost user backend type.
160 # Since: 4.0
163   'union': 'VHostUserBackendCapabilities',
164   'base': { 'type': 'VHostUserBackendType' },
165   'discriminator': 'type',
166   'data': {
167     'input': 'VHostUserBackendCapabilitiesInput',
168     'gpu': 'VHostUserBackendCapabilitiesGPU'
169   }
173 # @VhostUserBackend:
175 # Describes a vhost user backend to management software.
177 # It is possible for multiple @VhostUserBackend elements to match the
178 # search criteria of management software. Applications thus need rules
179 # to pick one of the many matches, and users need the ability to
180 # override distro defaults.
182 # It is recommended to create vhost user backend JSON files (each
183 # containing a single @VhostUserBackend root element) with a
184 # double-digit prefix, for example "50-qemu-gpu.json",
185 # "50-crosvm-gpu.json", etc, so they can be sorted in predictable
186 # order. The backend JSON files should be searched for in three
187 # directories:
189 #   - /usr/share/qemu/vhost-user -- populated by distro-provided
190 #                                   packages (XDG_DATA_DIRS covers
191 #                                   /usr/share by default),
193 #   - /etc/qemu/vhost-user -- exclusively for sysadmins' local additions,
195 #   - $XDG_CONFIG_HOME/qemu/vhost-user -- exclusively for per-user local
196 #                                         additions (XDG_CONFIG_HOME
197 #                                         defaults to $HOME/.config).
199 # Top-down, the list of directories goes from general to specific.
201 # Management software should build a list of files from all three
202 # locations, then sort the list by filename (i.e., basename
203 # component). Management software should choose the first JSON file on
204 # the sorted list that matches the search criteria. If a more specific
205 # directory has a file with same name as a less specific directory,
206 # then the file in the more specific directory takes effect. If the
207 # more specific file is zero length, it hides the less specific one.
209 # For example, if a distro ships
211 #   - /usr/share/qemu/vhost-user/50-qemu-gpu.json
213 #   - /usr/share/qemu/vhost-user/50-crosvm-gpu.json
215 # then the sysadmin can prevent the default QEMU GPU being used at all with
217 #   $ touch /etc/qemu/vhost-user/50-qemu-gpu.json
219 # The sysadmin can replace/alter the distro default QEMU GPU with
221 #   $ vim /etc/qemu/vhost-user/50-qemu-gpu.json
223 # or they can provide a parallel QEMU GPU with higher priority
225 #   $ vim /etc/qemu/vhost-user/10-qemu-gpu.json
227 # or they can provide a parallel QEMU GPU with lower priority
229 #   $ vim /etc/qemu/vhost-user/99-qemu-gpu.json
231 # @type: The vhost user backend type.
233 # @description: Provides a human-readable description of the backend.
234 #               Management software may or may not display @description.
236 # @binary: Absolute path to the backend binary.
238 # @tags: An optional list of auxiliary strings associated with the
239 #        backend for which @description is not appropriate, due to the
240 #        latter's possible exposure to the end-user. @tags serves
241 #        development and debugging purposes only, and management
242 #        software shall explicitly ignore it.
244 # Since: 4.0
246 # Example:
248 # {
249 #   "description": "QEMU vhost-user-gpu",
250 #   "type": "gpu",
251 #   "binary": "/usr/libexec/qemu/vhost-user-gpu",
252 #   "tags": [
253 #     "CONFIG_OPENGL=y",
254 #     "CONFIG_GBM=y"
255 #   ]
256 # }
260   'struct' : 'VhostUserBackend',
261   'data'   : {
262     'description': 'str',
263     'type': 'VHostUserBackendType',
264     'binary': 'str',
265     '*tags': [ 'str' ]
266   }