Statistics
| Branch: | Revision:

root / hmp-commands.hx @ 5a37532d

History | View | Annotate | Download (44.5 kB)

1 2313086a Blue Swirl
HXCOMM Use DEFHEADING() to define headings in both help text and texi
2 2313086a Blue Swirl
HXCOMM Text between STEXI and ETEXI are copied to texi version and
3 2313086a Blue Swirl
HXCOMM discarded from C version
4 2313086a Blue Swirl
HXCOMM DEF(command, args, callback, arg_string, help) is used to construct
5 2313086a Blue Swirl
HXCOMM monitor commands
6 2313086a Blue Swirl
HXCOMM HXCOMM can be used for comments, discarded from both texi and C
7 2313086a Blue Swirl
8 2313086a Blue Swirl
STEXI
9 2313086a Blue Swirl
@table @option
10 2313086a Blue Swirl
ETEXI
11 2313086a Blue Swirl
12 d7f9b689 Luiz Capitulino
    {
13 d7f9b689 Luiz Capitulino
        .name       = "help|?",
14 d7f9b689 Luiz Capitulino
        .args_type  = "name:s?",
15 d7f9b689 Luiz Capitulino
        .params     = "[cmd]",
16 d7f9b689 Luiz Capitulino
        .help       = "show the help",
17 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_help_cmd,
18 d7f9b689 Luiz Capitulino
    },
19 d7f9b689 Luiz Capitulino
20 2313086a Blue Swirl
STEXI
21 2313086a Blue Swirl
@item help or ? [@var{cmd}]
22 70fcbbe7 Stefan Weil
@findex help
23 2313086a Blue Swirl
Show the help for all commands or just for command @var{cmd}.
24 2313086a Blue Swirl
ETEXI
25 2313086a Blue Swirl
26 d7f9b689 Luiz Capitulino
    {
27 d7f9b689 Luiz Capitulino
        .name       = "commit",
28 d7f9b689 Luiz Capitulino
        .args_type  = "device:B",
29 d7f9b689 Luiz Capitulino
        .params     = "device|all",
30 d7f9b689 Luiz Capitulino
        .help       = "commit changes to the disk images (if -snapshot is used) or backing files",
31 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_commit,
32 d7f9b689 Luiz Capitulino
    },
33 d7f9b689 Luiz Capitulino
34 2313086a Blue Swirl
STEXI
35 2313086a Blue Swirl
@item commit
36 70fcbbe7 Stefan Weil
@findex commit
37 2313086a Blue Swirl
Commit changes to the disk images (if -snapshot is used) or backing files.
38 2313086a Blue Swirl
ETEXI
39 2313086a Blue Swirl
40 d7f9b689 Luiz Capitulino
    {
41 d7f9b689 Luiz Capitulino
        .name       = "q|quit",
42 d7f9b689 Luiz Capitulino
        .args_type  = "",
43 d7f9b689 Luiz Capitulino
        .params     = "",
44 d7f9b689 Luiz Capitulino
        .help       = "quit the emulator",
45 b223f35f Luiz Capitulino
        .user_print = monitor_user_noop,
46 7a7f325e Luiz Capitulino
        .mhandler.cmd = hmp_quit,
47 d7f9b689 Luiz Capitulino
    },
48 d7f9b689 Luiz Capitulino
49 2313086a Blue Swirl
STEXI
50 2313086a Blue Swirl
@item q or quit
51 70fcbbe7 Stefan Weil
@findex quit
52 2313086a Blue Swirl
Quit the emulator.
53 2313086a Blue Swirl
ETEXI
54 2313086a Blue Swirl
55 d7f9b689 Luiz Capitulino
    {
56 6d4a2b3a Christoph Hellwig
        .name       = "block_resize",
57 6d4a2b3a Christoph Hellwig
        .args_type  = "device:B,size:o",
58 6d4a2b3a Christoph Hellwig
        .params     = "device size",
59 6d4a2b3a Christoph Hellwig
        .help       = "resize a block image",
60 5e7caacb Luiz Capitulino
        .mhandler.cmd = hmp_block_resize,
61 6d4a2b3a Christoph Hellwig
    },
62 6d4a2b3a Christoph Hellwig
63 6d4a2b3a Christoph Hellwig
STEXI
64 6d4a2b3a Christoph Hellwig
@item block_resize
65 6d4a2b3a Christoph Hellwig
@findex block_resize
66 6d4a2b3a Christoph Hellwig
Resize a block image while a guest is running.  Usually requires guest
67 6d4a2b3a Christoph Hellwig
action to see the updated size.  Resize to a lower size is supported,
68 6d4a2b3a Christoph Hellwig
but should be used with extreme caution.  Note that this command only
69 6d4a2b3a Christoph Hellwig
resizes image files, it can not resize block devices like LVM volumes.
70 6d4a2b3a Christoph Hellwig
ETEXI
71 6d4a2b3a Christoph Hellwig
72 12bd451f Stefan Hajnoczi
    {
73 12bd451f Stefan Hajnoczi
        .name       = "block_stream",
74 c83c66c3 Stefan Hajnoczi
        .args_type  = "device:B,speed:o?,base:s?",
75 c83c66c3 Stefan Hajnoczi
        .params     = "device [speed [base]]",
76 12bd451f Stefan Hajnoczi
        .help       = "copy data from a backing file into a block device",
77 12bd451f Stefan Hajnoczi
        .mhandler.cmd = hmp_block_stream,
78 12bd451f Stefan Hajnoczi
    },
79 12bd451f Stefan Hajnoczi
80 12bd451f Stefan Hajnoczi
STEXI
81 12bd451f Stefan Hajnoczi
@item block_stream
82 12bd451f Stefan Hajnoczi
@findex block_stream
83 12bd451f Stefan Hajnoczi
Copy data from a backing file into a block device.
84 12bd451f Stefan Hajnoczi
ETEXI
85 6d4a2b3a Christoph Hellwig
86 6d4a2b3a Christoph Hellwig
    {
87 2d47c6e9 Stefan Hajnoczi
        .name       = "block_job_set_speed",
88 882ec7ce Stefan Hajnoczi
        .args_type  = "device:B,speed:o",
89 882ec7ce Stefan Hajnoczi
        .params     = "device speed",
90 2d47c6e9 Stefan Hajnoczi
        .help       = "set maximum speed for a background block operation",
91 2d47c6e9 Stefan Hajnoczi
        .mhandler.cmd = hmp_block_job_set_speed,
92 2d47c6e9 Stefan Hajnoczi
    },
93 2d47c6e9 Stefan Hajnoczi
94 2d47c6e9 Stefan Hajnoczi
STEXI
95 4451b799 Paolo Bonzini
@item block_job_set_speed
96 4451b799 Paolo Bonzini
@findex block_job_set_speed
97 2d47c6e9 Stefan Hajnoczi
Set maximum speed for a background block operation.
98 2d47c6e9 Stefan Hajnoczi
ETEXI
99 2d47c6e9 Stefan Hajnoczi
100 2d47c6e9 Stefan Hajnoczi
    {
101 370521a1 Stefan Hajnoczi
        .name       = "block_job_cancel",
102 6e37fb81 Paolo Bonzini
        .args_type  = "force:-f,device:B",
103 6e37fb81 Paolo Bonzini
        .params     = "[-f] device",
104 6e37fb81 Paolo Bonzini
        .help       = "stop an active background block operation (use -f"
105 6e37fb81 Paolo Bonzini
                      "\n\t\t\t if the operation is currently paused)",
106 370521a1 Stefan Hajnoczi
        .mhandler.cmd = hmp_block_job_cancel,
107 370521a1 Stefan Hajnoczi
    },
108 370521a1 Stefan Hajnoczi
109 370521a1 Stefan Hajnoczi
STEXI
110 370521a1 Stefan Hajnoczi
@item block_job_cancel
111 370521a1 Stefan Hajnoczi
@findex block_job_cancel
112 aeae883b Paolo Bonzini
Stop an active background block operation (streaming, mirroring).
113 aeae883b Paolo Bonzini
ETEXI
114 aeae883b Paolo Bonzini
115 aeae883b Paolo Bonzini
    {
116 aeae883b Paolo Bonzini
        .name       = "block_job_complete",
117 aeae883b Paolo Bonzini
        .args_type  = "device:B",
118 aeae883b Paolo Bonzini
        .params     = "device",
119 aeae883b Paolo Bonzini
        .help       = "stop an active background block operation",
120 aeae883b Paolo Bonzini
        .mhandler.cmd = hmp_block_job_complete,
121 aeae883b Paolo Bonzini
    },
122 aeae883b Paolo Bonzini
123 aeae883b Paolo Bonzini
STEXI
124 aeae883b Paolo Bonzini
@item block_job_complete
125 aeae883b Paolo Bonzini
@findex block_job_complete
126 aeae883b Paolo Bonzini
Manually trigger completion of an active background block operation.
127 aeae883b Paolo Bonzini
For mirroring, this will switch the device to the destination path.
128 370521a1 Stefan Hajnoczi
ETEXI
129 370521a1 Stefan Hajnoczi
130 370521a1 Stefan Hajnoczi
    {
131 6e37fb81 Paolo Bonzini
        .name       = "block_job_pause",
132 6e37fb81 Paolo Bonzini
        .args_type  = "device:B",
133 6e37fb81 Paolo Bonzini
        .params     = "device",
134 6e37fb81 Paolo Bonzini
        .help       = "pause an active background block operation",
135 6e37fb81 Paolo Bonzini
        .mhandler.cmd = hmp_block_job_pause,
136 6e37fb81 Paolo Bonzini
    },
137 6e37fb81 Paolo Bonzini
138 6e37fb81 Paolo Bonzini
STEXI
139 6e37fb81 Paolo Bonzini
@item block_job_pause
140 6e37fb81 Paolo Bonzini
@findex block_job_pause
141 6e37fb81 Paolo Bonzini
Pause an active block streaming operation.
142 6e37fb81 Paolo Bonzini
ETEXI
143 6e37fb81 Paolo Bonzini
144 6e37fb81 Paolo Bonzini
    {
145 6e37fb81 Paolo Bonzini
        .name       = "block_job_resume",
146 6e37fb81 Paolo Bonzini
        .args_type  = "device:B",
147 6e37fb81 Paolo Bonzini
        .params     = "device",
148 6e37fb81 Paolo Bonzini
        .help       = "resume a paused background block operation",
149 6e37fb81 Paolo Bonzini
        .mhandler.cmd = hmp_block_job_resume,
150 6e37fb81 Paolo Bonzini
    },
151 6e37fb81 Paolo Bonzini
152 6e37fb81 Paolo Bonzini
STEXI
153 6e37fb81 Paolo Bonzini
@item block_job_resume
154 6e37fb81 Paolo Bonzini
@findex block_job_resume
155 6e37fb81 Paolo Bonzini
Resume a paused block streaming operation.
156 6e37fb81 Paolo Bonzini
ETEXI
157 6e37fb81 Paolo Bonzini
158 6e37fb81 Paolo Bonzini
    {
159 d7f9b689 Luiz Capitulino
        .name       = "eject",
160 78d714e0 Luiz Capitulino
        .args_type  = "force:-f,device:B",
161 d7f9b689 Luiz Capitulino
        .params     = "[-f] device",
162 d7f9b689 Luiz Capitulino
        .help       = "eject a removable medium (use -f to force it)",
163 c245b6a3 Luiz Capitulino
        .mhandler.cmd = hmp_eject,
164 d7f9b689 Luiz Capitulino
    },
165 d7f9b689 Luiz Capitulino
166 2313086a Blue Swirl
STEXI
167 2313086a Blue Swirl
@item eject [-f] @var{device}
168 70fcbbe7 Stefan Weil
@findex eject
169 2313086a Blue Swirl
Eject a removable medium (use -f to force it).
170 2313086a Blue Swirl
ETEXI
171 2313086a Blue Swirl
172 d7f9b689 Luiz Capitulino
    {
173 9063f814 Ryan Harper
        .name       = "drive_del",
174 9063f814 Ryan Harper
        .args_type  = "id:s",
175 9063f814 Ryan Harper
        .params     = "device",
176 9063f814 Ryan Harper
        .help       = "remove host block device",
177 9063f814 Ryan Harper
        .user_print = monitor_user_noop,
178 9063f814 Ryan Harper
        .mhandler.cmd_new = do_drive_del,
179 9063f814 Ryan Harper
    },
180 9063f814 Ryan Harper
181 9063f814 Ryan Harper
STEXI
182 9063f814 Ryan Harper
@item drive_del @var{device}
183 9063f814 Ryan Harper
@findex drive_del
184 9063f814 Ryan Harper
Remove host block device.  The result is that guest generated IO is no longer
185 9063f814 Ryan Harper
submitted against the host device underlying the disk.  Once a drive has
186 9063f814 Ryan Harper
been deleted, the QEMU Block layer returns -EIO which results in IO
187 9063f814 Ryan Harper
errors in the guest for applications that are reading/writing to the device.
188 9063f814 Ryan Harper
ETEXI
189 9063f814 Ryan Harper
190 9063f814 Ryan Harper
    {
191 d7f9b689 Luiz Capitulino
        .name       = "change",
192 d7f9b689 Luiz Capitulino
        .args_type  = "device:B,target:F,arg:s?",
193 d7f9b689 Luiz Capitulino
        .params     = "device filename [format]",
194 d7f9b689 Luiz Capitulino
        .help       = "change a removable medium, optional format",
195 333a96ec Luiz Capitulino
        .mhandler.cmd = hmp_change,
196 d7f9b689 Luiz Capitulino
    },
197 d7f9b689 Luiz Capitulino
198 2313086a Blue Swirl
STEXI
199 2313086a Blue Swirl
@item change @var{device} @var{setting}
200 70fcbbe7 Stefan Weil
@findex change
201 2313086a Blue Swirl
202 2313086a Blue Swirl
Change the configuration of a device.
203 2313086a Blue Swirl
204 2313086a Blue Swirl
@table @option
205 2313086a Blue Swirl
@item change @var{diskdevice} @var{filename} [@var{format}]
206 2313086a Blue Swirl
Change the medium for a removable disk device to point to @var{filename}. eg
207 2313086a Blue Swirl
208 2313086a Blue Swirl
@example
209 2313086a Blue Swirl
(qemu) change ide1-cd0 /path/to/some.iso
210 2313086a Blue Swirl
@end example
211 2313086a Blue Swirl
212 2313086a Blue Swirl
@var{format} is optional.
213 2313086a Blue Swirl
214 2313086a Blue Swirl
@item change vnc @var{display},@var{options}
215 2313086a Blue Swirl
Change the configuration of the VNC server. The valid syntax for @var{display}
216 2313086a Blue Swirl
and @var{options} are described at @ref{sec_invocation}. eg
217 2313086a Blue Swirl
218 2313086a Blue Swirl
@example
219 2313086a Blue Swirl
(qemu) change vnc localhost:1
220 2313086a Blue Swirl
@end example
221 2313086a Blue Swirl
222 2313086a Blue Swirl
@item change vnc password [@var{password}]
223 2313086a Blue Swirl
224 2313086a Blue Swirl
Change the password associated with the VNC server. If the new password is not
225 2313086a Blue Swirl
supplied, the monitor will prompt for it to be entered. VNC passwords are only
226 2313086a Blue Swirl
significant up to 8 letters. eg
227 2313086a Blue Swirl
228 2313086a Blue Swirl
@example
229 2313086a Blue Swirl
(qemu) change vnc password
230 2313086a Blue Swirl
Password: ********
231 2313086a Blue Swirl
@end example
232 2313086a Blue Swirl
233 2313086a Blue Swirl
@end table
234 2313086a Blue Swirl
ETEXI
235 2313086a Blue Swirl
236 d7f9b689 Luiz Capitulino
    {
237 d7f9b689 Luiz Capitulino
        .name       = "screendump",
238 d7f9b689 Luiz Capitulino
        .args_type  = "filename:F",
239 d7f9b689 Luiz Capitulino
        .params     = "filename",
240 d7f9b689 Luiz Capitulino
        .help       = "save screen into PPM image 'filename'",
241 ad39cf6d Luiz Capitulino
        .mhandler.cmd = hmp_screen_dump,
242 d7f9b689 Luiz Capitulino
    },
243 d7f9b689 Luiz Capitulino
244 2313086a Blue Swirl
STEXI
245 2313086a Blue Swirl
@item screendump @var{filename}
246 70fcbbe7 Stefan Weil
@findex screendump
247 2313086a Blue Swirl
Save screen into PPM image @var{filename}.
248 2313086a Blue Swirl
ETEXI
249 2313086a Blue Swirl
250 d7f9b689 Luiz Capitulino
    {
251 d7f9b689 Luiz Capitulino
        .name       = "logfile",
252 d7f9b689 Luiz Capitulino
        .args_type  = "filename:F",
253 d7f9b689 Luiz Capitulino
        .params     = "filename",
254 d7f9b689 Luiz Capitulino
        .help       = "output logs to 'filename'",
255 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_logfile,
256 d7f9b689 Luiz Capitulino
    },
257 d7f9b689 Luiz Capitulino
258 2313086a Blue Swirl
STEXI
259 2313086a Blue Swirl
@item logfile @var{filename}
260 70fcbbe7 Stefan Weil
@findex logfile
261 2313086a Blue Swirl
Output logs to @var{filename}.
262 2313086a Blue Swirl
ETEXI
263 2313086a Blue Swirl
264 22890ab5 Prerna Saxena
    {
265 22890ab5 Prerna Saxena
        .name       = "trace-event",
266 22890ab5 Prerna Saxena
        .args_type  = "name:s,option:b",
267 22890ab5 Prerna Saxena
        .params     = "name on|off",
268 22890ab5 Prerna Saxena
        .help       = "changes status of a specific trace event",
269 fc764105 Lluís
        .mhandler.cmd = do_trace_event_set_state,
270 22890ab5 Prerna Saxena
    },
271 22890ab5 Prerna Saxena
272 22890ab5 Prerna Saxena
STEXI
273 22890ab5 Prerna Saxena
@item trace-event
274 22890ab5 Prerna Saxena
@findex trace-event
275 22890ab5 Prerna Saxena
changes status of a trace event
276 22890ab5 Prerna Saxena
ETEXI
277 c5ceb523 Stefan Hajnoczi
278 c45a8168 Michael Roth
#if defined(CONFIG_TRACE_SIMPLE)
279 c5ceb523 Stefan Hajnoczi
    {
280 c5ceb523 Stefan Hajnoczi
        .name       = "trace-file",
281 c5ceb523 Stefan Hajnoczi
        .args_type  = "op:s?,arg:F?",
282 c5ceb523 Stefan Hajnoczi
        .params     = "on|off|flush|set [arg]",
283 c5ceb523 Stefan Hajnoczi
        .help       = "open, close, or flush trace file, or set a new file name",
284 c5ceb523 Stefan Hajnoczi
        .mhandler.cmd = do_trace_file,
285 c5ceb523 Stefan Hajnoczi
    },
286 c5ceb523 Stefan Hajnoczi
287 c5ceb523 Stefan Hajnoczi
STEXI
288 c5ceb523 Stefan Hajnoczi
@item trace-file on|off|flush
289 c5ceb523 Stefan Hajnoczi
@findex trace-file
290 c5ceb523 Stefan Hajnoczi
Open, close, or flush the trace file.  If no argument is given, the status of the trace file is displayed.
291 c5ceb523 Stefan Hajnoczi
ETEXI
292 22890ab5 Prerna Saxena
#endif
293 22890ab5 Prerna Saxena
294 d7f9b689 Luiz Capitulino
    {
295 d7f9b689 Luiz Capitulino
        .name       = "log",
296 d7f9b689 Luiz Capitulino
        .args_type  = "items:s",
297 d7f9b689 Luiz Capitulino
        .params     = "item1[,...]",
298 989b697d Peter Maydell
        .help       = "activate logging of the specified items",
299 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_log,
300 d7f9b689 Luiz Capitulino
    },
301 d7f9b689 Luiz Capitulino
302 2313086a Blue Swirl
STEXI
303 2313086a Blue Swirl
@item log @var{item1}[,...]
304 70fcbbe7 Stefan Weil
@findex log
305 989b697d Peter Maydell
Activate logging of the specified items.
306 2313086a Blue Swirl
ETEXI
307 2313086a Blue Swirl
308 d7f9b689 Luiz Capitulino
    {
309 d7f9b689 Luiz Capitulino
        .name       = "savevm",
310 d7f9b689 Luiz Capitulino
        .args_type  = "name:s?",
311 d7f9b689 Luiz Capitulino
        .params     = "[tag|id]",
312 d7f9b689 Luiz Capitulino
        .help       = "save a VM snapshot. If no tag or id are provided, a new snapshot is created",
313 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_savevm,
314 d7f9b689 Luiz Capitulino
    },
315 d7f9b689 Luiz Capitulino
316 2313086a Blue Swirl
STEXI
317 2313086a Blue Swirl
@item savevm [@var{tag}|@var{id}]
318 70fcbbe7 Stefan Weil
@findex savevm
319 2313086a Blue Swirl
Create a snapshot of the whole virtual machine. If @var{tag} is
320 2313086a Blue Swirl
provided, it is used as human readable identifier. If there is already
321 2313086a Blue Swirl
a snapshot with the same tag or ID, it is replaced. More info at
322 2313086a Blue Swirl
@ref{vm_snapshots}.
323 2313086a Blue Swirl
ETEXI
324 2313086a Blue Swirl
325 d7f9b689 Luiz Capitulino
    {
326 d7f9b689 Luiz Capitulino
        .name       = "loadvm",
327 d7f9b689 Luiz Capitulino
        .args_type  = "name:s",
328 d7f9b689 Luiz Capitulino
        .params     = "tag|id",
329 d7f9b689 Luiz Capitulino
        .help       = "restore a VM snapshot from its tag or id",
330 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_loadvm,
331 d7f9b689 Luiz Capitulino
    },
332 d7f9b689 Luiz Capitulino
333 2313086a Blue Swirl
STEXI
334 2313086a Blue Swirl
@item loadvm @var{tag}|@var{id}
335 70fcbbe7 Stefan Weil
@findex loadvm
336 2313086a Blue Swirl
Set the whole virtual machine to the snapshot identified by the tag
337 2313086a Blue Swirl
@var{tag} or the unique snapshot ID @var{id}.
338 2313086a Blue Swirl
ETEXI
339 2313086a Blue Swirl
340 d7f9b689 Luiz Capitulino
    {
341 d7f9b689 Luiz Capitulino
        .name       = "delvm",
342 d7f9b689 Luiz Capitulino
        .args_type  = "name:s",
343 d7f9b689 Luiz Capitulino
        .params     = "tag|id",
344 d7f9b689 Luiz Capitulino
        .help       = "delete a VM snapshot from its tag or id",
345 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_delvm,
346 d7f9b689 Luiz Capitulino
    },
347 d7f9b689 Luiz Capitulino
348 2313086a Blue Swirl
STEXI
349 2313086a Blue Swirl
@item delvm @var{tag}|@var{id}
350 70fcbbe7 Stefan Weil
@findex delvm
351 2313086a Blue Swirl
Delete the snapshot identified by @var{tag} or @var{id}.
352 2313086a Blue Swirl
ETEXI
353 2313086a Blue Swirl
354 d7f9b689 Luiz Capitulino
    {
355 d7f9b689 Luiz Capitulino
        .name       = "singlestep",
356 d7f9b689 Luiz Capitulino
        .args_type  = "option:s?",
357 d7f9b689 Luiz Capitulino
        .params     = "[on|off]",
358 d7f9b689 Luiz Capitulino
        .help       = "run emulation in singlestep mode or switch to normal mode",
359 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_singlestep,
360 d7f9b689 Luiz Capitulino
    },
361 d7f9b689 Luiz Capitulino
362 2313086a Blue Swirl
STEXI
363 2313086a Blue Swirl
@item singlestep [off]
364 70fcbbe7 Stefan Weil
@findex singlestep
365 2313086a Blue Swirl
Run the emulation in single step mode.
366 2313086a Blue Swirl
If called with option off, the emulation returns to normal mode.
367 2313086a Blue Swirl
ETEXI
368 2313086a Blue Swirl
369 d7f9b689 Luiz Capitulino
    {
370 d7f9b689 Luiz Capitulino
        .name       = "stop",
371 d7f9b689 Luiz Capitulino
        .args_type  = "",
372 d7f9b689 Luiz Capitulino
        .params     = "",
373 d7f9b689 Luiz Capitulino
        .help       = "stop emulation",
374 5f158f21 Luiz Capitulino
        .mhandler.cmd = hmp_stop,
375 d7f9b689 Luiz Capitulino
    },
376 d7f9b689 Luiz Capitulino
377 2313086a Blue Swirl
STEXI
378 2313086a Blue Swirl
@item stop
379 70fcbbe7 Stefan Weil
@findex stop
380 2313086a Blue Swirl
Stop emulation.
381 2313086a Blue Swirl
ETEXI
382 2313086a Blue Swirl
383 d7f9b689 Luiz Capitulino
    {
384 d7f9b689 Luiz Capitulino
        .name       = "c|cont",
385 d7f9b689 Luiz Capitulino
        .args_type  = "",
386 d7f9b689 Luiz Capitulino
        .params     = "",
387 d7f9b689 Luiz Capitulino
        .help       = "resume emulation",
388 e42e818b Luiz Capitulino
        .mhandler.cmd = hmp_cont,
389 d7f9b689 Luiz Capitulino
    },
390 d7f9b689 Luiz Capitulino
391 2313086a Blue Swirl
STEXI
392 2313086a Blue Swirl
@item c or cont
393 70fcbbe7 Stefan Weil
@findex cont
394 2313086a Blue Swirl
Resume emulation.
395 2313086a Blue Swirl
ETEXI
396 2313086a Blue Swirl
397 d7f9b689 Luiz Capitulino
    {
398 9b9df25a Gerd Hoffmann
        .name       = "system_wakeup",
399 9b9df25a Gerd Hoffmann
        .args_type  = "",
400 9b9df25a Gerd Hoffmann
        .params     = "",
401 9b9df25a Gerd Hoffmann
        .help       = "wakeup guest from suspend",
402 9b9df25a Gerd Hoffmann
        .mhandler.cmd = hmp_system_wakeup,
403 9b9df25a Gerd Hoffmann
    },
404 9b9df25a Gerd Hoffmann
405 9b9df25a Gerd Hoffmann
STEXI
406 9b9df25a Gerd Hoffmann
@item system_wakeup
407 9b9df25a Gerd Hoffmann
@findex system_wakeup
408 9b9df25a Gerd Hoffmann
Wakeup guest from suspend.
409 9b9df25a Gerd Hoffmann
ETEXI
410 9b9df25a Gerd Hoffmann
411 9b9df25a Gerd Hoffmann
    {
412 d7f9b689 Luiz Capitulino
        .name       = "gdbserver",
413 d7f9b689 Luiz Capitulino
        .args_type  = "device:s?",
414 d7f9b689 Luiz Capitulino
        .params     = "[device]",
415 d7f9b689 Luiz Capitulino
        .help       = "start gdbserver on given device (default 'tcp::1234'), stop with 'none'",
416 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_gdbserver,
417 d7f9b689 Luiz Capitulino
    },
418 d7f9b689 Luiz Capitulino
419 2313086a Blue Swirl
STEXI
420 2313086a Blue Swirl
@item gdbserver [@var{port}]
421 70fcbbe7 Stefan Weil
@findex gdbserver
422 2313086a Blue Swirl
Start gdbserver session (default @var{port}=1234)
423 2313086a Blue Swirl
ETEXI
424 2313086a Blue Swirl
425 d7f9b689 Luiz Capitulino
    {
426 d7f9b689 Luiz Capitulino
        .name       = "x",
427 d7f9b689 Luiz Capitulino
        .args_type  = "fmt:/,addr:l",
428 d7f9b689 Luiz Capitulino
        .params     = "/fmt addr",
429 d7f9b689 Luiz Capitulino
        .help       = "virtual memory dump starting at 'addr'",
430 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_memory_dump,
431 d7f9b689 Luiz Capitulino
    },
432 d7f9b689 Luiz Capitulino
433 2313086a Blue Swirl
STEXI
434 2313086a Blue Swirl
@item x/fmt @var{addr}
435 70fcbbe7 Stefan Weil
@findex x
436 2313086a Blue Swirl
Virtual memory dump starting at @var{addr}.
437 2313086a Blue Swirl
ETEXI
438 2313086a Blue Swirl
439 d7f9b689 Luiz Capitulino
    {
440 d7f9b689 Luiz Capitulino
        .name       = "xp",
441 d7f9b689 Luiz Capitulino
        .args_type  = "fmt:/,addr:l",
442 d7f9b689 Luiz Capitulino
        .params     = "/fmt addr",
443 d7f9b689 Luiz Capitulino
        .help       = "physical memory dump starting at 'addr'",
444 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_physical_memory_dump,
445 d7f9b689 Luiz Capitulino
    },
446 d7f9b689 Luiz Capitulino
447 2313086a Blue Swirl
STEXI
448 2313086a Blue Swirl
@item xp /@var{fmt} @var{addr}
449 70fcbbe7 Stefan Weil
@findex xp
450 2313086a Blue Swirl
Physical memory dump starting at @var{addr}.
451 2313086a Blue Swirl
452 2313086a Blue Swirl
@var{fmt} is a format which tells the command how to format the
453 2313086a Blue Swirl
data. Its syntax is: @option{/@{count@}@{format@}@{size@}}
454 2313086a Blue Swirl
455 2313086a Blue Swirl
@table @var
456 2313086a Blue Swirl
@item count
457 2313086a Blue Swirl
is the number of items to be dumped.
458 2313086a Blue Swirl
459 2313086a Blue Swirl
@item format
460 2313086a Blue Swirl
can be x (hex), d (signed decimal), u (unsigned decimal), o (octal),
461 2313086a Blue Swirl
c (char) or i (asm instruction).
462 2313086a Blue Swirl
463 2313086a Blue Swirl
@item size
464 2313086a Blue Swirl
can be b (8 bits), h (16 bits), w (32 bits) or g (64 bits). On x86,
465 2313086a Blue Swirl
@code{h} or @code{w} can be specified with the @code{i} format to
466 2313086a Blue Swirl
respectively select 16 or 32 bit code instruction size.
467 2313086a Blue Swirl
468 2313086a Blue Swirl
@end table
469 2313086a Blue Swirl
470 2313086a Blue Swirl
Examples:
471 2313086a Blue Swirl
@itemize
472 2313086a Blue Swirl
@item
473 2313086a Blue Swirl
Dump 10 instructions at the current instruction pointer:
474 2313086a Blue Swirl
@example
475 2313086a Blue Swirl
(qemu) x/10i $eip
476 2313086a Blue Swirl
0x90107063:  ret
477 2313086a Blue Swirl
0x90107064:  sti
478 2313086a Blue Swirl
0x90107065:  lea    0x0(%esi,1),%esi
479 2313086a Blue Swirl
0x90107069:  lea    0x0(%edi,1),%edi
480 2313086a Blue Swirl
0x90107070:  ret
481 2313086a Blue Swirl
0x90107071:  jmp    0x90107080
482 2313086a Blue Swirl
0x90107073:  nop
483 2313086a Blue Swirl
0x90107074:  nop
484 2313086a Blue Swirl
0x90107075:  nop
485 2313086a Blue Swirl
0x90107076:  nop
486 2313086a Blue Swirl
@end example
487 2313086a Blue Swirl
488 2313086a Blue Swirl
@item
489 2313086a Blue Swirl
Dump 80 16 bit values at the start of the video memory.
490 2313086a Blue Swirl
@smallexample
491 2313086a Blue Swirl
(qemu) xp/80hx 0xb8000
492 2313086a Blue Swirl
0x000b8000: 0x0b50 0x0b6c 0x0b65 0x0b78 0x0b38 0x0b36 0x0b2f 0x0b42
493 2313086a Blue Swirl
0x000b8010: 0x0b6f 0x0b63 0x0b68 0x0b73 0x0b20 0x0b56 0x0b47 0x0b41
494 2313086a Blue Swirl
0x000b8020: 0x0b42 0x0b69 0x0b6f 0x0b73 0x0b20 0x0b63 0x0b75 0x0b72
495 2313086a Blue Swirl
0x000b8030: 0x0b72 0x0b65 0x0b6e 0x0b74 0x0b2d 0x0b63 0x0b76 0x0b73
496 2313086a Blue Swirl
0x000b8040: 0x0b20 0x0b30 0x0b35 0x0b20 0x0b4e 0x0b6f 0x0b76 0x0b20
497 2313086a Blue Swirl
0x000b8050: 0x0b32 0x0b30 0x0b30 0x0b33 0x0720 0x0720 0x0720 0x0720
498 2313086a Blue Swirl
0x000b8060: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
499 2313086a Blue Swirl
0x000b8070: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
500 2313086a Blue Swirl
0x000b8080: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
501 2313086a Blue Swirl
0x000b8090: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
502 2313086a Blue Swirl
@end smallexample
503 2313086a Blue Swirl
@end itemize
504 2313086a Blue Swirl
ETEXI
505 2313086a Blue Swirl
506 d7f9b689 Luiz Capitulino
    {
507 d7f9b689 Luiz Capitulino
        .name       = "p|print",
508 d7f9b689 Luiz Capitulino
        .args_type  = "fmt:/,val:l",
509 d7f9b689 Luiz Capitulino
        .params     = "/fmt expr",
510 d7f9b689 Luiz Capitulino
        .help       = "print expression value (use $reg for CPU register access)",
511 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_print,
512 d7f9b689 Luiz Capitulino
    },
513 d7f9b689 Luiz Capitulino
514 2313086a Blue Swirl
STEXI
515 2313086a Blue Swirl
@item p or print/@var{fmt} @var{expr}
516 70fcbbe7 Stefan Weil
@findex print
517 2313086a Blue Swirl
518 2313086a Blue Swirl
Print expression value. Only the @var{format} part of @var{fmt} is
519 2313086a Blue Swirl
used.
520 2313086a Blue Swirl
ETEXI
521 2313086a Blue Swirl
522 d7f9b689 Luiz Capitulino
    {
523 d7f9b689 Luiz Capitulino
        .name       = "i",
524 d7f9b689 Luiz Capitulino
        .args_type  = "fmt:/,addr:i,index:i.",
525 d7f9b689 Luiz Capitulino
        .params     = "/fmt addr",
526 d7f9b689 Luiz Capitulino
        .help       = "I/O port read",
527 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_ioport_read,
528 d7f9b689 Luiz Capitulino
    },
529 d7f9b689 Luiz Capitulino
530 2313086a Blue Swirl
STEXI
531 2313086a Blue Swirl
Read I/O port.
532 2313086a Blue Swirl
ETEXI
533 2313086a Blue Swirl
534 d7f9b689 Luiz Capitulino
    {
535 d7f9b689 Luiz Capitulino
        .name       = "o",
536 d7f9b689 Luiz Capitulino
        .args_type  = "fmt:/,addr:i,val:i",
537 d7f9b689 Luiz Capitulino
        .params     = "/fmt addr value",
538 d7f9b689 Luiz Capitulino
        .help       = "I/O port write",
539 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_ioport_write,
540 d7f9b689 Luiz Capitulino
    },
541 d7f9b689 Luiz Capitulino
542 f114784f Jan Kiszka
STEXI
543 f114784f Jan Kiszka
Write to I/O port.
544 f114784f Jan Kiszka
ETEXI
545 2313086a Blue Swirl
546 d7f9b689 Luiz Capitulino
    {
547 d7f9b689 Luiz Capitulino
        .name       = "sendkey",
548 2ef20c15 Amos Kong
        .args_type  = "keys:s,hold-time:i?",
549 d7f9b689 Luiz Capitulino
        .params     = "keys [hold_ms]",
550 d7f9b689 Luiz Capitulino
        .help       = "send keys to the VM (e.g. 'sendkey ctrl-alt-f1', default hold time=100 ms)",
551 e4c8f004 Amos Kong
        .mhandler.cmd = hmp_send_key,
552 d7f9b689 Luiz Capitulino
    },
553 d7f9b689 Luiz Capitulino
554 2313086a Blue Swirl
STEXI
555 2313086a Blue Swirl
@item sendkey @var{keys}
556 70fcbbe7 Stefan Weil
@findex sendkey
557 2313086a Blue Swirl
558 886cc706 Amos Kong
Send @var{keys} to the guest. @var{keys} could be the name of the
559 886cc706 Amos Kong
key or the raw value in hexadecimal format. Use @code{-} to press
560 886cc706 Amos Kong
several keys simultaneously. Example:
561 2313086a Blue Swirl
@example
562 2313086a Blue Swirl
sendkey ctrl-alt-f1
563 2313086a Blue Swirl
@end example
564 2313086a Blue Swirl
565 2313086a Blue Swirl
This command is useful to send keys that your graphical user interface
566 2313086a Blue Swirl
intercepts at low level, such as @code{ctrl-alt-f1} in X Window.
567 2313086a Blue Swirl
ETEXI
568 2313086a Blue Swirl
569 d7f9b689 Luiz Capitulino
    {
570 d7f9b689 Luiz Capitulino
        .name       = "system_reset",
571 d7f9b689 Luiz Capitulino
        .args_type  = "",
572 d7f9b689 Luiz Capitulino
        .params     = "",
573 d7f9b689 Luiz Capitulino
        .help       = "reset the system",
574 38d22653 Luiz Capitulino
        .mhandler.cmd = hmp_system_reset,
575 d7f9b689 Luiz Capitulino
    },
576 d7f9b689 Luiz Capitulino
577 2313086a Blue Swirl
STEXI
578 2313086a Blue Swirl
@item system_reset
579 70fcbbe7 Stefan Weil
@findex system_reset
580 2313086a Blue Swirl
581 2313086a Blue Swirl
Reset the system.
582 2313086a Blue Swirl
ETEXI
583 2313086a Blue Swirl
584 d7f9b689 Luiz Capitulino
    {
585 d7f9b689 Luiz Capitulino
        .name       = "system_powerdown",
586 d7f9b689 Luiz Capitulino
        .args_type  = "",
587 d7f9b689 Luiz Capitulino
        .params     = "",
588 d7f9b689 Luiz Capitulino
        .help       = "send system power down event",
589 5bc465e4 Luiz Capitulino
        .mhandler.cmd = hmp_system_powerdown,
590 d7f9b689 Luiz Capitulino
    },
591 d7f9b689 Luiz Capitulino
592 2313086a Blue Swirl
STEXI
593 2313086a Blue Swirl
@item system_powerdown
594 70fcbbe7 Stefan Weil
@findex system_powerdown
595 2313086a Blue Swirl
596 2313086a Blue Swirl
Power down the system (if supported).
597 2313086a Blue Swirl
ETEXI
598 2313086a Blue Swirl
599 d7f9b689 Luiz Capitulino
    {
600 d7f9b689 Luiz Capitulino
        .name       = "sum",
601 d7f9b689 Luiz Capitulino
        .args_type  = "start:i,size:i",
602 d7f9b689 Luiz Capitulino
        .params     = "addr size",
603 d7f9b689 Luiz Capitulino
        .help       = "compute the checksum of a memory region",
604 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_sum,
605 d7f9b689 Luiz Capitulino
    },
606 d7f9b689 Luiz Capitulino
607 2313086a Blue Swirl
STEXI
608 2313086a Blue Swirl
@item sum @var{addr} @var{size}
609 70fcbbe7 Stefan Weil
@findex sum
610 2313086a Blue Swirl
611 2313086a Blue Swirl
Compute the checksum of a memory region.
612 2313086a Blue Swirl
ETEXI
613 2313086a Blue Swirl
614 d7f9b689 Luiz Capitulino
    {
615 d7f9b689 Luiz Capitulino
        .name       = "usb_add",
616 d7f9b689 Luiz Capitulino
        .args_type  = "devname:s",
617 d7f9b689 Luiz Capitulino
        .params     = "device",
618 d7f9b689 Luiz Capitulino
        .help       = "add USB device (e.g. 'host:bus.addr' or 'host:vendor_id:product_id')",
619 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_usb_add,
620 d7f9b689 Luiz Capitulino
    },
621 d7f9b689 Luiz Capitulino
622 2313086a Blue Swirl
STEXI
623 2313086a Blue Swirl
@item usb_add @var{devname}
624 70fcbbe7 Stefan Weil
@findex usb_add
625 2313086a Blue Swirl
626 2313086a Blue Swirl
Add the USB device @var{devname}.  For details of available devices see
627 2313086a Blue Swirl
@ref{usb_devices}
628 2313086a Blue Swirl
ETEXI
629 2313086a Blue Swirl
630 d7f9b689 Luiz Capitulino
    {
631 d7f9b689 Luiz Capitulino
        .name       = "usb_del",
632 d7f9b689 Luiz Capitulino
        .args_type  = "devname:s",
633 d7f9b689 Luiz Capitulino
        .params     = "device",
634 d7f9b689 Luiz Capitulino
        .help       = "remove USB device 'bus.addr'",
635 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_usb_del,
636 d7f9b689 Luiz Capitulino
    },
637 d7f9b689 Luiz Capitulino
638 2313086a Blue Swirl
STEXI
639 2313086a Blue Swirl
@item usb_del @var{devname}
640 70fcbbe7 Stefan Weil
@findex usb_del
641 2313086a Blue Swirl
642 2313086a Blue Swirl
Remove the USB device @var{devname} from the QEMU virtual USB
643 2313086a Blue Swirl
hub. @var{devname} has the syntax @code{bus.addr}. Use the monitor
644 2313086a Blue Swirl
command @code{info usb} to see the devices you can remove.
645 2313086a Blue Swirl
ETEXI
646 2313086a Blue Swirl
647 d7f9b689 Luiz Capitulino
    {
648 d7f9b689 Luiz Capitulino
        .name       = "device_add",
649 c7e4e8ce Markus Armbruster
        .args_type  = "device:O",
650 c7e4e8ce Markus Armbruster
        .params     = "driver[,prop=value][,...]",
651 d7f9b689 Luiz Capitulino
        .help       = "add device, like -device on the command line",
652 8bc27249 Markus Armbruster
        .user_print = monitor_user_noop,
653 8bc27249 Markus Armbruster
        .mhandler.cmd_new = do_device_add,
654 d7f9b689 Luiz Capitulino
    },
655 d7f9b689 Luiz Capitulino
656 3418bd25 Gerd Hoffmann
STEXI
657 3418bd25 Gerd Hoffmann
@item device_add @var{config}
658 70fcbbe7 Stefan Weil
@findex device_add
659 3418bd25 Gerd Hoffmann
660 3418bd25 Gerd Hoffmann
Add device.
661 3418bd25 Gerd Hoffmann
ETEXI
662 3418bd25 Gerd Hoffmann
663 d7f9b689 Luiz Capitulino
    {
664 d7f9b689 Luiz Capitulino
        .name       = "device_del",
665 d7f9b689 Luiz Capitulino
        .args_type  = "id:s",
666 d7f9b689 Luiz Capitulino
        .params     = "device",
667 d7f9b689 Luiz Capitulino
        .help       = "remove device",
668 a15fef21 Luiz Capitulino
        .mhandler.cmd = hmp_device_del,
669 d7f9b689 Luiz Capitulino
    },
670 d7f9b689 Luiz Capitulino
671 3418bd25 Gerd Hoffmann
STEXI
672 3418bd25 Gerd Hoffmann
@item device_del @var{id}
673 70fcbbe7 Stefan Weil
@findex device_del
674 3418bd25 Gerd Hoffmann
675 3418bd25 Gerd Hoffmann
Remove device @var{id}.
676 3418bd25 Gerd Hoffmann
ETEXI
677 3418bd25 Gerd Hoffmann
678 d7f9b689 Luiz Capitulino
    {
679 d7f9b689 Luiz Capitulino
        .name       = "cpu",
680 d7f9b689 Luiz Capitulino
        .args_type  = "index:i",
681 d7f9b689 Luiz Capitulino
        .params     = "index",
682 d7f9b689 Luiz Capitulino
        .help       = "set the default CPU",
683 755f1968 Luiz Capitulino
        .mhandler.cmd = hmp_cpu,
684 d7f9b689 Luiz Capitulino
    },
685 3418bd25 Gerd Hoffmann
686 2313086a Blue Swirl
STEXI
687 c427ea9c Markus Armbruster
@item cpu @var{index}
688 c427ea9c Markus Armbruster
@findex cpu
689 2313086a Blue Swirl
Set the default CPU.
690 2313086a Blue Swirl
ETEXI
691 2313086a Blue Swirl
692 d7f9b689 Luiz Capitulino
    {
693 d7f9b689 Luiz Capitulino
        .name       = "mouse_move",
694 d7f9b689 Luiz Capitulino
        .args_type  = "dx_str:s,dy_str:s,dz_str:s?",
695 d7f9b689 Luiz Capitulino
        .params     = "dx dy [dz]",
696 d7f9b689 Luiz Capitulino
        .help       = "send mouse move events",
697 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_mouse_move,
698 d7f9b689 Luiz Capitulino
    },
699 d7f9b689 Luiz Capitulino
700 2313086a Blue Swirl
STEXI
701 2313086a Blue Swirl
@item mouse_move @var{dx} @var{dy} [@var{dz}]
702 70fcbbe7 Stefan Weil
@findex mouse_move
703 2313086a Blue Swirl
Move the active mouse to the specified coordinates @var{dx} @var{dy}
704 2313086a Blue Swirl
with optional scroll axis @var{dz}.
705 2313086a Blue Swirl
ETEXI
706 2313086a Blue Swirl
707 d7f9b689 Luiz Capitulino
    {
708 d7f9b689 Luiz Capitulino
        .name       = "mouse_button",
709 d7f9b689 Luiz Capitulino
        .args_type  = "button_state:i",
710 d7f9b689 Luiz Capitulino
        .params     = "state",
711 d7f9b689 Luiz Capitulino
        .help       = "change mouse button state (1=L, 2=M, 4=R)",
712 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_mouse_button,
713 d7f9b689 Luiz Capitulino
    },
714 d7f9b689 Luiz Capitulino
715 2313086a Blue Swirl
STEXI
716 2313086a Blue Swirl
@item mouse_button @var{val}
717 70fcbbe7 Stefan Weil
@findex mouse_button
718 2313086a Blue Swirl
Change the active mouse button state @var{val} (1=L, 2=M, 4=R).
719 2313086a Blue Swirl
ETEXI
720 2313086a Blue Swirl
721 d7f9b689 Luiz Capitulino
    {
722 d7f9b689 Luiz Capitulino
        .name       = "mouse_set",
723 d7f9b689 Luiz Capitulino
        .args_type  = "index:i",
724 d7f9b689 Luiz Capitulino
        .params     = "index",
725 d7f9b689 Luiz Capitulino
        .help       = "set which mouse device receives events",
726 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_mouse_set,
727 d7f9b689 Luiz Capitulino
    },
728 d7f9b689 Luiz Capitulino
729 2313086a Blue Swirl
STEXI
730 2313086a Blue Swirl
@item mouse_set @var{index}
731 70fcbbe7 Stefan Weil
@findex mouse_set
732 2313086a Blue Swirl
Set which mouse device receives events at given @var{index}, index
733 2313086a Blue Swirl
can be obtained with
734 2313086a Blue Swirl
@example
735 2313086a Blue Swirl
info mice
736 2313086a Blue Swirl
@end example
737 2313086a Blue Swirl
ETEXI
738 2313086a Blue Swirl
739 2313086a Blue Swirl
#ifdef HAS_AUDIO
740 d7f9b689 Luiz Capitulino
    {
741 d7f9b689 Luiz Capitulino
        .name       = "wavcapture",
742 d7f9b689 Luiz Capitulino
        .args_type  = "path:F,freq:i?,bits:i?,nchannels:i?",
743 d7f9b689 Luiz Capitulino
        .params     = "path [frequency [bits [channels]]]",
744 d7f9b689 Luiz Capitulino
        .help       = "capture audio to a wave file (default frequency=44100 bits=16 channels=2)",
745 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_wav_capture,
746 d7f9b689 Luiz Capitulino
    },
747 2313086a Blue Swirl
#endif
748 2313086a Blue Swirl
STEXI
749 2313086a Blue Swirl
@item wavcapture @var{filename} [@var{frequency} [@var{bits} [@var{channels}]]]
750 70fcbbe7 Stefan Weil
@findex wavcapture
751 2313086a Blue Swirl
Capture audio into @var{filename}. Using sample rate @var{frequency}
752 2313086a Blue Swirl
bits per sample @var{bits} and number of channels @var{channels}.
753 2313086a Blue Swirl
754 2313086a Blue Swirl
Defaults:
755 2313086a Blue Swirl
@itemize @minus
756 2313086a Blue Swirl
@item Sample rate = 44100 Hz - CD quality
757 2313086a Blue Swirl
@item Bits = 16
758 2313086a Blue Swirl
@item Number of channels = 2 - Stereo
759 2313086a Blue Swirl
@end itemize
760 2313086a Blue Swirl
ETEXI
761 2313086a Blue Swirl
762 2313086a Blue Swirl
#ifdef HAS_AUDIO
763 d7f9b689 Luiz Capitulino
    {
764 d7f9b689 Luiz Capitulino
        .name       = "stopcapture",
765 d7f9b689 Luiz Capitulino
        .args_type  = "n:i",
766 d7f9b689 Luiz Capitulino
        .params     = "capture index",
767 d7f9b689 Luiz Capitulino
        .help       = "stop capture",
768 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_stop_capture,
769 d7f9b689 Luiz Capitulino
    },
770 2313086a Blue Swirl
#endif
771 2313086a Blue Swirl
STEXI
772 2313086a Blue Swirl
@item stopcapture @var{index}
773 70fcbbe7 Stefan Weil
@findex stopcapture
774 2313086a Blue Swirl
Stop capture with a given @var{index}, index can be obtained with
775 2313086a Blue Swirl
@example
776 2313086a Blue Swirl
info capture
777 2313086a Blue Swirl
@end example
778 2313086a Blue Swirl
ETEXI
779 2313086a Blue Swirl
780 d7f9b689 Luiz Capitulino
    {
781 d7f9b689 Luiz Capitulino
        .name       = "memsave",
782 d7f9b689 Luiz Capitulino
        .args_type  = "val:l,size:i,filename:s",
783 d7f9b689 Luiz Capitulino
        .params     = "addr size file",
784 d7f9b689 Luiz Capitulino
        .help       = "save to disk virtual memory dump starting at 'addr' of size 'size'",
785 0cfd6a9a Luiz Capitulino
        .mhandler.cmd = hmp_memsave,
786 d7f9b689 Luiz Capitulino
    },
787 d7f9b689 Luiz Capitulino
788 2313086a Blue Swirl
STEXI
789 2313086a Blue Swirl
@item memsave @var{addr} @var{size} @var{file}
790 70fcbbe7 Stefan Weil
@findex memsave
791 2313086a Blue Swirl
save to disk virtual memory dump starting at @var{addr} of size @var{size}.
792 2313086a Blue Swirl
ETEXI
793 2313086a Blue Swirl
794 d7f9b689 Luiz Capitulino
    {
795 d7f9b689 Luiz Capitulino
        .name       = "pmemsave",
796 d7f9b689 Luiz Capitulino
        .args_type  = "val:l,size:i,filename:s",
797 d7f9b689 Luiz Capitulino
        .params     = "addr size file",
798 d7f9b689 Luiz Capitulino
        .help       = "save to disk physical memory dump starting at 'addr' of size 'size'",
799 6d3962bf Luiz Capitulino
        .mhandler.cmd = hmp_pmemsave,
800 d7f9b689 Luiz Capitulino
    },
801 d7f9b689 Luiz Capitulino
802 2313086a Blue Swirl
STEXI
803 2313086a Blue Swirl
@item pmemsave @var{addr} @var{size} @var{file}
804 70fcbbe7 Stefan Weil
@findex pmemsave
805 2313086a Blue Swirl
save to disk physical memory dump starting at @var{addr} of size @var{size}.
806 2313086a Blue Swirl
ETEXI
807 2313086a Blue Swirl
808 d7f9b689 Luiz Capitulino
    {
809 d7f9b689 Luiz Capitulino
        .name       = "boot_set",
810 d7f9b689 Luiz Capitulino
        .args_type  = "bootdevice:s",
811 d7f9b689 Luiz Capitulino
        .params     = "bootdevice",
812 d7f9b689 Luiz Capitulino
        .help       = "define new values for the boot device list",
813 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_boot_set,
814 d7f9b689 Luiz Capitulino
    },
815 d7f9b689 Luiz Capitulino
816 2313086a Blue Swirl
STEXI
817 2313086a Blue Swirl
@item boot_set @var{bootdevicelist}
818 70fcbbe7 Stefan Weil
@findex boot_set
819 2313086a Blue Swirl
820 2313086a Blue Swirl
Define new values for the boot device list. Those values will override
821 2313086a Blue Swirl
the values specified on the command line through the @code{-boot} option.
822 2313086a Blue Swirl
823 2313086a Blue Swirl
The values that can be specified here depend on the machine type, but are
824 2313086a Blue Swirl
the same that can be specified in the @code{-boot} command line option.
825 2313086a Blue Swirl
ETEXI
826 2313086a Blue Swirl
827 2313086a Blue Swirl
#if defined(TARGET_I386)
828 d7f9b689 Luiz Capitulino
    {
829 d7f9b689 Luiz Capitulino
        .name       = "nmi",
830 e9b4b432 Luiz Capitulino
        .args_type  = "",
831 e9b4b432 Luiz Capitulino
        .params     = "",
832 e9b4b432 Luiz Capitulino
        .help       = "inject an NMI on all guest's CPUs",
833 ab49ab5c Luiz Capitulino
        .mhandler.cmd = hmp_inject_nmi,
834 d7f9b689 Luiz Capitulino
    },
835 2313086a Blue Swirl
#endif
836 2313086a Blue Swirl
STEXI
837 2313086a Blue Swirl
@item nmi @var{cpu}
838 70fcbbe7 Stefan Weil
@findex nmi
839 2313086a Blue Swirl
Inject an NMI on the given CPU (x86 only).
840 1f590cf9 Lei Li
841 1f590cf9 Lei Li
ETEXI
842 1f590cf9 Lei Li
843 1f590cf9 Lei Li
    {
844 3949e594 Markus Armbruster
        .name       = "ringbuf_write",
845 1f590cf9 Lei Li
        .args_type  = "device:s,data:s",
846 1f590cf9 Lei Li
        .params     = "device data",
847 3949e594 Markus Armbruster
        .help       = "Write to a ring buffer character device",
848 3949e594 Markus Armbruster
        .mhandler.cmd = hmp_ringbuf_write,
849 1f590cf9 Lei Li
    },
850 1f590cf9 Lei Li
851 1f590cf9 Lei Li
STEXI
852 3949e594 Markus Armbruster
@item ringbuf_write @var{device} @var{data}
853 3949e594 Markus Armbruster
@findex ringbuf_write
854 3949e594 Markus Armbruster
Write @var{data} to ring buffer character device @var{device}.
855 3949e594 Markus Armbruster
@var{data} must be a UTF-8 string.
856 1f590cf9 Lei Li
857 2313086a Blue Swirl
ETEXI
858 2313086a Blue Swirl
859 d7f9b689 Luiz Capitulino
    {
860 3949e594 Markus Armbruster
        .name       = "ringbuf_read",
861 49b6d722 Lei Li
        .args_type  = "device:s,size:i",
862 49b6d722 Lei Li
        .params     = "device size",
863 3949e594 Markus Armbruster
        .help       = "Read from a ring buffer character device",
864 3949e594 Markus Armbruster
        .mhandler.cmd = hmp_ringbuf_read,
865 49b6d722 Lei Li
    },
866 49b6d722 Lei Li
867 49b6d722 Lei Li
STEXI
868 3949e594 Markus Armbruster
@item ringbuf_read @var{device}
869 3949e594 Markus Armbruster
@findex ringbuf_read
870 3949e594 Markus Armbruster
Read and print up to @var{size} bytes from ring buffer character
871 3949e594 Markus Armbruster
device @var{device}.
872 543f3412 Markus Armbruster
Certain non-printable characters are printed \uXXXX, where XXXX is the
873 543f3412 Markus Armbruster
character code in hexadecimal.  Character \ is printed \\.
874 3949e594 Markus Armbruster
Bug: can screw up when the buffer contains invalid UTF-8 sequences,
875 3949e594 Markus Armbruster
NUL characters, after the ring buffer lost data, and when reading
876 3949e594 Markus Armbruster
stops because the size limit is reached.
877 49b6d722 Lei Li
878 49b6d722 Lei Li
ETEXI
879 49b6d722 Lei Li
880 49b6d722 Lei Li
    {
881 d7f9b689 Luiz Capitulino
        .name       = "migrate",
882 fbc3d96c lirans@il.ibm.com
        .args_type  = "detach:-d,blk:-b,inc:-i,uri:s",
883 fbc3d96c lirans@il.ibm.com
        .params     = "[-d] [-b] [-i] uri",
884 fbc3d96c lirans@il.ibm.com
        .help       = "migrate to URI (using -d to not wait for completion)"
885 fbc3d96c lirans@il.ibm.com
		      "\n\t\t\t -b for migration without shared storage with"
886 fbc3d96c lirans@il.ibm.com
		      " full copy of disk\n\t\t\t -i for migration without "
887 fbc3d96c lirans@il.ibm.com
		      "shared storage with incremental copy of disk "
888 fbc3d96c lirans@il.ibm.com
		      "(base image shared between src and destination)",
889 e1c37d0e Luiz Capitulino
        .mhandler.cmd = hmp_migrate,
890 d7f9b689 Luiz Capitulino
    },
891 d7f9b689 Luiz Capitulino
892 fbc3d96c lirans@il.ibm.com
893 2313086a Blue Swirl
STEXI
894 fbc3d96c lirans@il.ibm.com
@item migrate [-d] [-b] [-i] @var{uri}
895 70fcbbe7 Stefan Weil
@findex migrate
896 2313086a Blue Swirl
Migrate to @var{uri} (using -d to not wait for completion).
897 fbc3d96c lirans@il.ibm.com
	-b for migration with full copy of disk
898 fbc3d96c lirans@il.ibm.com
	-i for migration with incremental copy of disk (base image is shared)
899 2313086a Blue Swirl
ETEXI
900 2313086a Blue Swirl
901 d7f9b689 Luiz Capitulino
    {
902 d7f9b689 Luiz Capitulino
        .name       = "migrate_cancel",
903 d7f9b689 Luiz Capitulino
        .args_type  = "",
904 d7f9b689 Luiz Capitulino
        .params     = "",
905 d7f9b689 Luiz Capitulino
        .help       = "cancel the current VM migration",
906 6cdedb07 Luiz Capitulino
        .mhandler.cmd = hmp_migrate_cancel,
907 d7f9b689 Luiz Capitulino
    },
908 d7f9b689 Luiz Capitulino
909 2313086a Blue Swirl
STEXI
910 2313086a Blue Swirl
@item migrate_cancel
911 70fcbbe7 Stefan Weil
@findex migrate_cancel
912 2313086a Blue Swirl
Cancel the current VM migration.
913 9e1ba4cc Orit Wasserman
914 9e1ba4cc Orit Wasserman
ETEXI
915 9e1ba4cc Orit Wasserman
916 9e1ba4cc Orit Wasserman
    {
917 9e1ba4cc Orit Wasserman
        .name       = "migrate_set_cache_size",
918 9e1ba4cc Orit Wasserman
        .args_type  = "value:o",
919 9e1ba4cc Orit Wasserman
        .params     = "value",
920 9e1ba4cc Orit Wasserman
        .help       = "set cache size (in bytes) for XBZRLE migrations,"
921 9e1ba4cc Orit Wasserman
                      "the cache size will be rounded down to the nearest "
922 9e1ba4cc Orit Wasserman
                      "power of 2.\n"
923 9e1ba4cc Orit Wasserman
                      "The cache size affects the number of cache misses."
924 9e1ba4cc Orit Wasserman
                      "In case of a high cache miss ratio you need to increase"
925 9e1ba4cc Orit Wasserman
                      " the cache size",
926 9e1ba4cc Orit Wasserman
        .mhandler.cmd = hmp_migrate_set_cache_size,
927 9e1ba4cc Orit Wasserman
    },
928 9e1ba4cc Orit Wasserman
929 9e1ba4cc Orit Wasserman
STEXI
930 9e1ba4cc Orit Wasserman
@item migrate_set_cache_size @var{value}
931 9e1ba4cc Orit Wasserman
@findex migrate_set_cache_size
932 9e1ba4cc Orit Wasserman
Set cache size to @var{value} (in bytes) for xbzrle migrations.
933 2313086a Blue Swirl
ETEXI
934 2313086a Blue Swirl
935 d7f9b689 Luiz Capitulino
    {
936 d7f9b689 Luiz Capitulino
        .name       = "migrate_set_speed",
937 ed3d4a80 Jes Sorensen
        .args_type  = "value:o",
938 d7f9b689 Luiz Capitulino
        .params     = "value",
939 ed3d4a80 Jes Sorensen
        .help       = "set maximum speed (in bytes) for migrations. "
940 ed3d4a80 Jes Sorensen
	"Defaults to MB if no size suffix is specified, ie. B/K/M/G/T",
941 3dc85383 Luiz Capitulino
        .mhandler.cmd = hmp_migrate_set_speed,
942 d7f9b689 Luiz Capitulino
    },
943 d7f9b689 Luiz Capitulino
944 2313086a Blue Swirl
STEXI
945 2313086a Blue Swirl
@item migrate_set_speed @var{value}
946 70fcbbe7 Stefan Weil
@findex migrate_set_speed
947 2313086a Blue Swirl
Set maximum speed to @var{value} (in bytes) for migrations.
948 2313086a Blue Swirl
ETEXI
949 2313086a Blue Swirl
950 d7f9b689 Luiz Capitulino
    {
951 d7f9b689 Luiz Capitulino
        .name       = "migrate_set_downtime",
952 b0fbf7d3 Markus Armbruster
        .args_type  = "value:T",
953 d7f9b689 Luiz Capitulino
        .params     = "value",
954 d7f9b689 Luiz Capitulino
        .help       = "set maximum tolerated downtime (in seconds) for migrations",
955 4f0a993b Luiz Capitulino
        .mhandler.cmd = hmp_migrate_set_downtime,
956 d7f9b689 Luiz Capitulino
    },
957 2ea42952 Glauber Costa
958 2ea42952 Glauber Costa
STEXI
959 2ea42952 Glauber Costa
@item migrate_set_downtime @var{second}
960 70fcbbe7 Stefan Weil
@findex migrate_set_downtime
961 2ea42952 Glauber Costa
Set maximum tolerated downtime (in seconds) for migration.
962 2ea42952 Glauber Costa
ETEXI
963 2ea42952 Glauber Costa
964 f8882568 Jes Sorensen
    {
965 00458433 Orit Wasserman
        .name       = "migrate_set_capability",
966 00458433 Orit Wasserman
        .args_type  = "capability:s,state:b",
967 00458433 Orit Wasserman
        .params     = "capability state",
968 00458433 Orit Wasserman
        .help       = "Enable/Disable the usage of a capability for migration",
969 00458433 Orit Wasserman
        .mhandler.cmd = hmp_migrate_set_capability,
970 00458433 Orit Wasserman
    },
971 00458433 Orit Wasserman
972 00458433 Orit Wasserman
STEXI
973 00458433 Orit Wasserman
@item migrate_set_capability @var{capability} @var{state}
974 00458433 Orit Wasserman
@findex migrate_set_capability
975 00458433 Orit Wasserman
Enable/Disable the usage of a capability @var{capability} for migration.
976 00458433 Orit Wasserman
ETEXI
977 00458433 Orit Wasserman
978 00458433 Orit Wasserman
    {
979 2ea720db Jes Sorensen
        .name       = "client_migrate_info",
980 2ea720db Jes Sorensen
        .args_type  = "protocol:s,hostname:s,port:i?,tls-port:i?,cert-subject:s?",
981 2ea720db Jes Sorensen
        .params     = "protocol hostname port tls-port cert-subject",
982 2ea720db Jes Sorensen
        .help       = "send migration info to spice/vnc client",
983 2ea720db Jes Sorensen
        .user_print = monitor_user_noop,
984 edc5cb1a Yonit Halperin
        .mhandler.cmd_async = client_migrate_info,
985 edc5cb1a Yonit Halperin
        .flags      = MONITOR_CMD_ASYNC,
986 f8882568 Jes Sorensen
    },
987 f8882568 Jes Sorensen
988 f8882568 Jes Sorensen
STEXI
989 e866e239 Gerd Hoffmann
@item client_migrate_info @var{protocol} @var{hostname} @var{port} @var{tls-port} @var{cert-subject}
990 e866e239 Gerd Hoffmann
@findex client_migrate_info
991 e866e239 Gerd Hoffmann
Set the spice/vnc connection info for the migration target.  The spice/vnc
992 e866e239 Gerd Hoffmann
server will ask the spice/vnc client to automatically reconnect using the
993 e866e239 Gerd Hoffmann
new parameters (if specified) once the vm migration finished successfully.
994 e866e239 Gerd Hoffmann
ETEXI
995 e866e239 Gerd Hoffmann
996 783e9b48 Wen Congyang
#if defined(CONFIG_HAVE_CORE_DUMP)
997 783e9b48 Wen Congyang
    {
998 783e9b48 Wen Congyang
        .name       = "dump-guest-memory",
999 75363769 Luiz Capitulino
        .args_type  = "paging:-p,filename:F,begin:i?,length:i?",
1000 75363769 Luiz Capitulino
        .params     = "[-p] filename [begin] [length]",
1001 783e9b48 Wen Congyang
        .help       = "dump guest memory to file"
1002 783e9b48 Wen Congyang
                      "\n\t\t\t begin(optional): the starting physical address"
1003 783e9b48 Wen Congyang
                      "\n\t\t\t length(optional): the memory size, in bytes",
1004 783e9b48 Wen Congyang
        .mhandler.cmd = hmp_dump_guest_memory,
1005 783e9b48 Wen Congyang
    },
1006 783e9b48 Wen Congyang
1007 783e9b48 Wen Congyang
1008 783e9b48 Wen Congyang
STEXI
1009 783e9b48 Wen Congyang
@item dump-guest-memory [-p] @var{protocol} @var{begin} @var{length}
1010 783e9b48 Wen Congyang
@findex dump-guest-memory
1011 783e9b48 Wen Congyang
Dump guest memory to @var{protocol}. The file can be processed with crash or
1012 783e9b48 Wen Congyang
gdb.
1013 75363769 Luiz Capitulino
  filename: dump file name
1014 783e9b48 Wen Congyang
    paging: do paging to get guest's memory mapping
1015 783e9b48 Wen Congyang
     begin: the starting physical address. It's optional, and should be
1016 783e9b48 Wen Congyang
            specified with length together.
1017 783e9b48 Wen Congyang
    length: the memory size, in bytes. It's optional, and should be specified
1018 783e9b48 Wen Congyang
            with begin together.
1019 783e9b48 Wen Congyang
ETEXI
1020 783e9b48 Wen Congyang
#endif
1021 783e9b48 Wen Congyang
1022 e866e239 Gerd Hoffmann
    {
1023 2ea720db Jes Sorensen
        .name       = "snapshot_blkdev",
1024 6cc2a415 Paolo Bonzini
        .args_type  = "reuse:-n,device:B,snapshot-file:s?,format:s?",
1025 6cc2a415 Paolo Bonzini
        .params     = "[-n] device [new-image-file] [format]",
1026 2ea720db Jes Sorensen
        .help       = "initiates a live snapshot\n\t\t\t"
1027 2ea720db Jes Sorensen
                      "of device. If a new image file is specified, the\n\t\t\t"
1028 2ea720db Jes Sorensen
                      "new image file will become the new root image.\n\t\t\t"
1029 2ea720db Jes Sorensen
                      "If format is specified, the snapshot file will\n\t\t\t"
1030 2ea720db Jes Sorensen
                      "be created in that format. Otherwise the\n\t\t\t"
1031 6cc2a415 Paolo Bonzini
                      "snapshot will be internal! (currently unsupported).\n\t\t\t"
1032 6cc2a415 Paolo Bonzini
                      "The default format is qcow2.  The -n flag requests QEMU\n\t\t\t"
1033 6cc2a415 Paolo Bonzini
                      "to reuse the image found in new-image-file, instead of\n\t\t\t"
1034 6cc2a415 Paolo Bonzini
                      "recreating it from scratch.",
1035 6106e249 Luiz Capitulino
        .mhandler.cmd = hmp_snapshot_blkdev,
1036 e866e239 Gerd Hoffmann
    },
1037 e866e239 Gerd Hoffmann
1038 e866e239 Gerd Hoffmann
STEXI
1039 f8882568 Jes Sorensen
@item snapshot_blkdev
1040 f8882568 Jes Sorensen
@findex snapshot_blkdev
1041 f8882568 Jes Sorensen
Snapshot device, using snapshot file as target if provided
1042 f8882568 Jes Sorensen
ETEXI
1043 f8882568 Jes Sorensen
1044 d7f9b689 Luiz Capitulino
    {
1045 d9b902db Paolo Bonzini
        .name       = "drive_mirror",
1046 d9b902db Paolo Bonzini
        .args_type  = "reuse:-n,full:-f,device:B,target:s,format:s?",
1047 d9b902db Paolo Bonzini
        .params     = "[-n] [-f] device target [format]",
1048 d9b902db Paolo Bonzini
        .help       = "initiates live storage\n\t\t\t"
1049 d9b902db Paolo Bonzini
                      "migration for a device. The device's contents are\n\t\t\t"
1050 d9b902db Paolo Bonzini
                      "copied to the new image file, including data that\n\t\t\t"
1051 d9b902db Paolo Bonzini
                      "is written after the command is started.\n\t\t\t"
1052 d9b902db Paolo Bonzini
                      "The -n flag requests QEMU to reuse the image found\n\t\t\t"
1053 d9b902db Paolo Bonzini
                      "in new-image-file, instead of recreating it from scratch.\n\t\t\t"
1054 d9b902db Paolo Bonzini
                      "The -f flag requests QEMU to copy the whole disk,\n\t\t\t"
1055 d9b902db Paolo Bonzini
                      "so that the result does not need a backing file.\n\t\t\t",
1056 d9b902db Paolo Bonzini
        .mhandler.cmd = hmp_drive_mirror,
1057 d9b902db Paolo Bonzini
    },
1058 d9b902db Paolo Bonzini
STEXI
1059 d9b902db Paolo Bonzini
@item drive_mirror
1060 d9b902db Paolo Bonzini
@findex drive_mirror
1061 d9b902db Paolo Bonzini
Start mirroring a block device's writes to a new destination,
1062 d9b902db Paolo Bonzini
using the specified target.
1063 d9b902db Paolo Bonzini
ETEXI
1064 d9b902db Paolo Bonzini
1065 d9b902db Paolo Bonzini
    {
1066 d7f9b689 Luiz Capitulino
        .name       = "drive_add",
1067 d7f9b689 Luiz Capitulino
        .args_type  = "pci_addr:s,opts:s",
1068 d7f9b689 Luiz Capitulino
        .params     = "[[<domain>:]<bus>:]<slot>\n"
1069 d7f9b689 Luiz Capitulino
                      "[file=file][,if=type][,bus=n]\n"
1070 fb0490f6 Stefan Hajnoczi
                      "[,unit=m][,media=d][,index=i]\n"
1071 d7f9b689 Luiz Capitulino
                      "[,cyls=c,heads=h,secs=s[,trans=t]]\n"
1072 fb0490f6 Stefan Hajnoczi
                      "[,snapshot=on|off][,cache=on|off]\n"
1073 fb0490f6 Stefan Hajnoczi
                      "[,readonly=on|off][,copy-on-read=on|off]",
1074 d7f9b689 Luiz Capitulino
        .help       = "add drive to PCI storage controller",
1075 af4ce882 Luiz Capitulino
        .mhandler.cmd = drive_hot_add,
1076 d7f9b689 Luiz Capitulino
    },
1077 d7f9b689 Luiz Capitulino
1078 2313086a Blue Swirl
STEXI
1079 2313086a Blue Swirl
@item drive_add
1080 70fcbbe7 Stefan Weil
@findex drive_add
1081 2313086a Blue Swirl
Add drive to PCI storage controller.
1082 2313086a Blue Swirl
ETEXI
1083 2313086a Blue Swirl
1084 2313086a Blue Swirl
#if defined(TARGET_I386)
1085 d7f9b689 Luiz Capitulino
    {
1086 d7f9b689 Luiz Capitulino
        .name       = "pci_add",
1087 d7f9b689 Luiz Capitulino
        .args_type  = "pci_addr:s,type:s,opts:s?",
1088 d7f9b689 Luiz Capitulino
        .params     = "auto|[[<domain>:]<bus>:]<slot> nic|storage [[vlan=n][,macaddr=addr][,model=type]] [file=file][,if=type][,bus=nr]...",
1089 d7f9b689 Luiz Capitulino
        .help       = "hot-add PCI device",
1090 6c6a58ae Markus Armbruster
        .mhandler.cmd = pci_device_hot_add,
1091 d7f9b689 Luiz Capitulino
    },
1092 2313086a Blue Swirl
#endif
1093 d7f9b689 Luiz Capitulino
1094 2313086a Blue Swirl
STEXI
1095 2313086a Blue Swirl
@item pci_add
1096 70fcbbe7 Stefan Weil
@findex pci_add
1097 2313086a Blue Swirl
Hot-add PCI device.
1098 2313086a Blue Swirl
ETEXI
1099 2313086a Blue Swirl
1100 2313086a Blue Swirl
#if defined(TARGET_I386)
1101 d7f9b689 Luiz Capitulino
    {
1102 d7f9b689 Luiz Capitulino
        .name       = "pci_del",
1103 d7f9b689 Luiz Capitulino
        .args_type  = "pci_addr:s",
1104 d7f9b689 Luiz Capitulino
        .params     = "[[<domain>:]<bus>:]<slot>",
1105 d7f9b689 Luiz Capitulino
        .help       = "hot remove PCI device",
1106 b752daf0 Markus Armbruster
        .mhandler.cmd = do_pci_device_hot_remove,
1107 d7f9b689 Luiz Capitulino
    },
1108 2313086a Blue Swirl
#endif
1109 d7f9b689 Luiz Capitulino
1110 2313086a Blue Swirl
STEXI
1111 2313086a Blue Swirl
@item pci_del
1112 70fcbbe7 Stefan Weil
@findex pci_del
1113 2313086a Blue Swirl
Hot remove PCI device.
1114 2313086a Blue Swirl
ETEXI
1115 2313086a Blue Swirl
1116 d7f9b689 Luiz Capitulino
    {
1117 2ae63bda Isaku Yamahata
        .name       = "pcie_aer_inject_error",
1118 2ae63bda Isaku Yamahata
        .args_type  = "advisory_non_fatal:-a,correctable:-c,"
1119 2ae63bda Isaku Yamahata
	              "id:s,error_status:s,"
1120 2ae63bda Isaku Yamahata
	              "header0:i?,header1:i?,header2:i?,header3:i?,"
1121 2ae63bda Isaku Yamahata
	              "prefix0:i?,prefix1:i?,prefix2:i?,prefix3:i?",
1122 2ae63bda Isaku Yamahata
        .params     = "[-a] [-c] id "
1123 2ae63bda Isaku Yamahata
                      "<error_status> [<tlp header> [<tlp header prefix>]]",
1124 2ae63bda Isaku Yamahata
        .help       = "inject pcie aer error\n\t\t\t"
1125 2ae63bda Isaku Yamahata
	              " -a for advisory non fatal error\n\t\t\t"
1126 2ae63bda Isaku Yamahata
	              " -c for correctable error\n\t\t\t"
1127 2ae63bda Isaku Yamahata
                      "<id> = qdev device id\n\t\t\t"
1128 2ae63bda Isaku Yamahata
                      "<error_status> = error string or 32bit\n\t\t\t"
1129 2ae63bda Isaku Yamahata
                      "<tlb header> = 32bit x 4\n\t\t\t"
1130 2ae63bda Isaku Yamahata
                      "<tlb header prefix> = 32bit x 4",
1131 2ae63bda Isaku Yamahata
        .user_print  = pcie_aer_inject_error_print,
1132 1f3392b7 Zhi Yong Wu
        .mhandler.cmd_new = do_pcie_aer_inject_error,
1133 2ae63bda Isaku Yamahata
    },
1134 2ae63bda Isaku Yamahata
1135 2ae63bda Isaku Yamahata
STEXI
1136 2ae63bda Isaku Yamahata
@item pcie_aer_inject_error
1137 2ae63bda Isaku Yamahata
@findex pcie_aer_inject_error
1138 2ae63bda Isaku Yamahata
Inject PCIe AER error
1139 2ae63bda Isaku Yamahata
ETEXI
1140 2ae63bda Isaku Yamahata
1141 2ae63bda Isaku Yamahata
    {
1142 d7f9b689 Luiz Capitulino
        .name       = "host_net_add",
1143 d7f9b689 Luiz Capitulino
        .args_type  = "device:s,opts:s?",
1144 d7f9b689 Luiz Capitulino
        .params     = "tap|user|socket|vde|dump [options]",
1145 d7f9b689 Luiz Capitulino
        .help       = "add host VLAN client",
1146 af4ce882 Luiz Capitulino
        .mhandler.cmd = net_host_device_add,
1147 d7f9b689 Luiz Capitulino
    },
1148 d7f9b689 Luiz Capitulino
1149 2313086a Blue Swirl
STEXI
1150 2313086a Blue Swirl
@item host_net_add
1151 70fcbbe7 Stefan Weil
@findex host_net_add
1152 2313086a Blue Swirl
Add host VLAN client.
1153 2313086a Blue Swirl
ETEXI
1154 2313086a Blue Swirl
1155 d7f9b689 Luiz Capitulino
    {
1156 d7f9b689 Luiz Capitulino
        .name       = "host_net_remove",
1157 d7f9b689 Luiz Capitulino
        .args_type  = "vlan_id:i,device:s",
1158 d7f9b689 Luiz Capitulino
        .params     = "vlan_id name",
1159 d7f9b689 Luiz Capitulino
        .help       = "remove host VLAN client",
1160 af4ce882 Luiz Capitulino
        .mhandler.cmd = net_host_device_remove,
1161 d7f9b689 Luiz Capitulino
    },
1162 d7f9b689 Luiz Capitulino
1163 2313086a Blue Swirl
STEXI
1164 2313086a Blue Swirl
@item host_net_remove
1165 70fcbbe7 Stefan Weil
@findex host_net_remove
1166 2313086a Blue Swirl
Remove host VLAN client.
1167 2313086a Blue Swirl
ETEXI
1168 2313086a Blue Swirl
1169 ae82d324 Markus Armbruster
    {
1170 ae82d324 Markus Armbruster
        .name       = "netdev_add",
1171 ae82d324 Markus Armbruster
        .args_type  = "netdev:O",
1172 40e8c26d Stefan Hajnoczi
        .params     = "[user|tap|socket|hubport],id=str[,prop=value][,...]",
1173 ae82d324 Markus Armbruster
        .help       = "add host network device",
1174 928059a3 Luiz Capitulino
        .mhandler.cmd = hmp_netdev_add,
1175 ae82d324 Markus Armbruster
    },
1176 ae82d324 Markus Armbruster
1177 ae82d324 Markus Armbruster
STEXI
1178 ae82d324 Markus Armbruster
@item netdev_add
1179 ae82d324 Markus Armbruster
@findex netdev_add
1180 ae82d324 Markus Armbruster
Add host network device.
1181 ae82d324 Markus Armbruster
ETEXI
1182 ae82d324 Markus Armbruster
1183 ae82d324 Markus Armbruster
    {
1184 ae82d324 Markus Armbruster
        .name       = "netdev_del",
1185 ae82d324 Markus Armbruster
        .args_type  = "id:s",
1186 ae82d324 Markus Armbruster
        .params     = "id",
1187 ae82d324 Markus Armbruster
        .help       = "remove host network device",
1188 5f964155 Luiz Capitulino
        .mhandler.cmd = hmp_netdev_del,
1189 ae82d324 Markus Armbruster
    },
1190 ae82d324 Markus Armbruster
1191 ae82d324 Markus Armbruster
STEXI
1192 ae82d324 Markus Armbruster
@item netdev_del
1193 ae82d324 Markus Armbruster
@findex netdev_del
1194 ae82d324 Markus Armbruster
Remove host network device.
1195 ae82d324 Markus Armbruster
ETEXI
1196 ae82d324 Markus Armbruster
1197 2313086a Blue Swirl
#ifdef CONFIG_SLIRP
1198 d7f9b689 Luiz Capitulino
    {
1199 d7f9b689 Luiz Capitulino
        .name       = "hostfwd_add",
1200 d7f9b689 Luiz Capitulino
        .args_type  = "arg1:s,arg2:s?,arg3:s?",
1201 d7f9b689 Luiz Capitulino
        .params     = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport-[guestaddr]:guestport",
1202 d7f9b689 Luiz Capitulino
        .help       = "redirect TCP or UDP connections from host to guest (requires -net user)",
1203 af4ce882 Luiz Capitulino
        .mhandler.cmd = net_slirp_hostfwd_add,
1204 d7f9b689 Luiz Capitulino
    },
1205 21413d68 Markus Armbruster
#endif
1206 21413d68 Markus Armbruster
STEXI
1207 21413d68 Markus Armbruster
@item hostfwd_add
1208 21413d68 Markus Armbruster
@findex hostfwd_add
1209 21413d68 Markus Armbruster
Redirect TCP or UDP connections from host to guest (requires -net user).
1210 21413d68 Markus Armbruster
ETEXI
1211 d7f9b689 Luiz Capitulino
1212 21413d68 Markus Armbruster
#ifdef CONFIG_SLIRP
1213 d7f9b689 Luiz Capitulino
    {
1214 d7f9b689 Luiz Capitulino
        .name       = "hostfwd_remove",
1215 d7f9b689 Luiz Capitulino
        .args_type  = "arg1:s,arg2:s?,arg3:s?",
1216 d7f9b689 Luiz Capitulino
        .params     = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport",
1217 d7f9b689 Luiz Capitulino
        .help       = "remove host-to-guest TCP or UDP redirection",
1218 af4ce882 Luiz Capitulino
        .mhandler.cmd = net_slirp_hostfwd_remove,
1219 d7f9b689 Luiz Capitulino
    },
1220 d7f9b689 Luiz Capitulino
1221 2313086a Blue Swirl
#endif
1222 2313086a Blue Swirl
STEXI
1223 21413d68 Markus Armbruster
@item hostfwd_remove
1224 21413d68 Markus Armbruster
@findex hostfwd_remove
1225 21413d68 Markus Armbruster
Remove host-to-guest TCP or UDP redirection.
1226 2313086a Blue Swirl
ETEXI
1227 2313086a Blue Swirl
1228 d7f9b689 Luiz Capitulino
    {
1229 d7f9b689 Luiz Capitulino
        .name       = "balloon",
1230 3b0bd6ec Luiz Capitulino
        .args_type  = "value:M",
1231 d7f9b689 Luiz Capitulino
        .params     = "target",
1232 3c05613a Riccardo Magliocchetti
        .help       = "request VM to change its memory allocation (in MB)",
1233 d72f3264 Luiz Capitulino
        .mhandler.cmd = hmp_balloon,
1234 d7f9b689 Luiz Capitulino
    },
1235 d7f9b689 Luiz Capitulino
1236 2313086a Blue Swirl
STEXI
1237 2313086a Blue Swirl
@item balloon @var{value}
1238 70fcbbe7 Stefan Weil
@findex balloon
1239 2313086a Blue Swirl
Request VM to change its memory allocation to @var{value} (in MB).
1240 2313086a Blue Swirl
ETEXI
1241 2313086a Blue Swirl
1242 d7f9b689 Luiz Capitulino
    {
1243 d7f9b689 Luiz Capitulino
        .name       = "set_link",
1244 c9b26a4c Markus Armbruster
        .args_type  = "name:s,up:b",
1245 c9b26a4c Markus Armbruster
        .params     = "name on|off",
1246 d7f9b689 Luiz Capitulino
        .help       = "change the link status of a network adapter",
1247 4b37156c Luiz Capitulino
        .mhandler.cmd = hmp_set_link,
1248 d7f9b689 Luiz Capitulino
    },
1249 d7f9b689 Luiz Capitulino
1250 2313086a Blue Swirl
STEXI
1251 c9b26a4c Markus Armbruster
@item set_link @var{name} [on|off]
1252 70fcbbe7 Stefan Weil
@findex set_link
1253 c9b26a4c Markus Armbruster
Switch link @var{name} on (i.e. up) or off (i.e. down).
1254 2313086a Blue Swirl
ETEXI
1255 2313086a Blue Swirl
1256 d7f9b689 Luiz Capitulino
    {
1257 d7f9b689 Luiz Capitulino
        .name       = "watchdog_action",
1258 d7f9b689 Luiz Capitulino
        .args_type  = "action:s",
1259 d7f9b689 Luiz Capitulino
        .params     = "[reset|shutdown|poweroff|pause|debug|none]",
1260 d7f9b689 Luiz Capitulino
        .help       = "change watchdog action",
1261 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_watchdog_action,
1262 d7f9b689 Luiz Capitulino
    },
1263 d7f9b689 Luiz Capitulino
1264 2313086a Blue Swirl
STEXI
1265 2313086a Blue Swirl
@item watchdog_action
1266 70fcbbe7 Stefan Weil
@findex watchdog_action
1267 2313086a Blue Swirl
Change watchdog action.
1268 2313086a Blue Swirl
ETEXI
1269 2313086a Blue Swirl
1270 d7f9b689 Luiz Capitulino
    {
1271 d7f9b689 Luiz Capitulino
        .name       = "acl_show",
1272 d7f9b689 Luiz Capitulino
        .args_type  = "aclname:s",
1273 d7f9b689 Luiz Capitulino
        .params     = "aclname",
1274 d7f9b689 Luiz Capitulino
        .help       = "list rules in the access control list",
1275 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_acl_show,
1276 d7f9b689 Luiz Capitulino
    },
1277 d7f9b689 Luiz Capitulino
1278 2313086a Blue Swirl
STEXI
1279 15dfcd45 Jan Kiszka
@item acl_show @var{aclname}
1280 70fcbbe7 Stefan Weil
@findex acl_show
1281 15dfcd45 Jan Kiszka
List all the matching rules in the access control list, and the default
1282 15dfcd45 Jan Kiszka
policy. There are currently two named access control lists,
1283 15dfcd45 Jan Kiszka
@var{vnc.x509dname} and @var{vnc.username} matching on the x509 client
1284 15dfcd45 Jan Kiszka
certificate distinguished name, and SASL username respectively.
1285 15dfcd45 Jan Kiszka
ETEXI
1286 2313086a Blue Swirl
1287 d7f9b689 Luiz Capitulino
    {
1288 d7f9b689 Luiz Capitulino
        .name       = "acl_policy",
1289 d7f9b689 Luiz Capitulino
        .args_type  = "aclname:s,policy:s",
1290 d7f9b689 Luiz Capitulino
        .params     = "aclname allow|deny",
1291 d7f9b689 Luiz Capitulino
        .help       = "set default access control list policy",
1292 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_acl_policy,
1293 d7f9b689 Luiz Capitulino
    },
1294 d7f9b689 Luiz Capitulino
1295 15dfcd45 Jan Kiszka
STEXI
1296 cbbfacc6 Jan Kiszka
@item acl_policy @var{aclname} @code{allow|deny}
1297 70fcbbe7 Stefan Weil
@findex acl_policy
1298 15dfcd45 Jan Kiszka
Set the default access control list policy, used in the event that
1299 2313086a Blue Swirl
none of the explicit rules match. The default policy at startup is
1300 15dfcd45 Jan Kiszka
always @code{deny}.
1301 15dfcd45 Jan Kiszka
ETEXI
1302 15dfcd45 Jan Kiszka
1303 d7f9b689 Luiz Capitulino
    {
1304 d7f9b689 Luiz Capitulino
        .name       = "acl_add",
1305 d7f9b689 Luiz Capitulino
        .args_type  = "aclname:s,match:s,policy:s,index:i?",
1306 d7f9b689 Luiz Capitulino
        .params     = "aclname match allow|deny [index]",
1307 d7f9b689 Luiz Capitulino
        .help       = "add a match rule to the access control list",
1308 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_acl_add,
1309 d7f9b689 Luiz Capitulino
    },
1310 d7f9b689 Luiz Capitulino
1311 15dfcd45 Jan Kiszka
STEXI
1312 0e4aec98 Markus Armbruster
@item acl_add @var{aclname} @var{match} @code{allow|deny} [@var{index}]
1313 0e4aec98 Markus Armbruster
@findex acl_add
1314 15dfcd45 Jan Kiszka
Add a match rule to the access control list, allowing or denying access.
1315 15dfcd45 Jan Kiszka
The match will normally be an exact username or x509 distinguished name,
1316 15dfcd45 Jan Kiszka
but can optionally include wildcard globs. eg @code{*@@EXAMPLE.COM} to
1317 15dfcd45 Jan Kiszka
allow all users in the @code{EXAMPLE.COM} kerberos realm. The match will
1318 2313086a Blue Swirl
normally be appended to the end of the ACL, but can be inserted
1319 15dfcd45 Jan Kiszka
earlier in the list if the optional @var{index} parameter is supplied.
1320 15dfcd45 Jan Kiszka
ETEXI
1321 15dfcd45 Jan Kiszka
1322 d7f9b689 Luiz Capitulino
    {
1323 d7f9b689 Luiz Capitulino
        .name       = "acl_remove",
1324 d7f9b689 Luiz Capitulino
        .args_type  = "aclname:s,match:s",
1325 d7f9b689 Luiz Capitulino
        .params     = "aclname match",
1326 d7f9b689 Luiz Capitulino
        .help       = "remove a match rule from the access control list",
1327 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_acl_remove,
1328 d7f9b689 Luiz Capitulino
    },
1329 d7f9b689 Luiz Capitulino
1330 15dfcd45 Jan Kiszka
STEXI
1331 15dfcd45 Jan Kiszka
@item acl_remove @var{aclname} @var{match}
1332 70fcbbe7 Stefan Weil
@findex acl_remove
1333 15dfcd45 Jan Kiszka
Remove the specified match rule from the access control list.
1334 15dfcd45 Jan Kiszka
ETEXI
1335 15dfcd45 Jan Kiszka
1336 d7f9b689 Luiz Capitulino
    {
1337 d7f9b689 Luiz Capitulino
        .name       = "acl_reset",
1338 d7f9b689 Luiz Capitulino
        .args_type  = "aclname:s",
1339 d7f9b689 Luiz Capitulino
        .params     = "aclname",
1340 d7f9b689 Luiz Capitulino
        .help       = "reset the access control list",
1341 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_acl_reset,
1342 d7f9b689 Luiz Capitulino
    },
1343 d7f9b689 Luiz Capitulino
1344 15dfcd45 Jan Kiszka
STEXI
1345 0e4aec98 Markus Armbruster
@item acl_reset @var{aclname}
1346 0e4aec98 Markus Armbruster
@findex acl_reset
1347 15dfcd45 Jan Kiszka
Remove all matches from the access control list, and set the default
1348 2313086a Blue Swirl
policy back to @code{deny}.
1349 2313086a Blue Swirl
ETEXI
1350 2313086a Blue Swirl
1351 4057725f Paolo Bonzini
    {
1352 4057725f Paolo Bonzini
        .name       = "nbd_server_start",
1353 4057725f Paolo Bonzini
        .args_type  = "all:-a,writable:-w,uri:s",
1354 4057725f Paolo Bonzini
        .params     = "nbd_server_start [-a] [-w] host:port",
1355 4057725f Paolo Bonzini
        .help       = "serve block devices on the given host and port",
1356 4057725f Paolo Bonzini
        .mhandler.cmd = hmp_nbd_server_start,
1357 4057725f Paolo Bonzini
    },
1358 4057725f Paolo Bonzini
STEXI
1359 4057725f Paolo Bonzini
@item nbd_server_start @var{host}:@var{port}
1360 4057725f Paolo Bonzini
@findex nbd_server_start
1361 4057725f Paolo Bonzini
Start an NBD server on the given host and/or port.  If the @option{-a}
1362 4057725f Paolo Bonzini
option is included, all of the virtual machine's block devices that
1363 4057725f Paolo Bonzini
have an inserted media on them are automatically exported; in this case,
1364 4057725f Paolo Bonzini
the @option{-w} option makes the devices writable too.
1365 4057725f Paolo Bonzini
ETEXI
1366 4057725f Paolo Bonzini
1367 4057725f Paolo Bonzini
    {
1368 4057725f Paolo Bonzini
        .name       = "nbd_server_add",
1369 4057725f Paolo Bonzini
        .args_type  = "writable:-w,device:B",
1370 4057725f Paolo Bonzini
        .params     = "nbd_server_add [-w] device",
1371 4057725f Paolo Bonzini
        .help       = "export a block device via NBD",
1372 4057725f Paolo Bonzini
        .mhandler.cmd = hmp_nbd_server_add,
1373 4057725f Paolo Bonzini
    },
1374 4057725f Paolo Bonzini
STEXI
1375 4057725f Paolo Bonzini
@item nbd_server_add @var{device}
1376 4057725f Paolo Bonzini
@findex nbd_server_add
1377 4057725f Paolo Bonzini
Export a block device through QEMU's NBD server, which must be started
1378 4057725f Paolo Bonzini
beforehand with @command{nbd_server_start}.  The @option{-w} option makes the
1379 4057725f Paolo Bonzini
exported device writable too.
1380 4057725f Paolo Bonzini
ETEXI
1381 4057725f Paolo Bonzini
1382 4057725f Paolo Bonzini
    {
1383 4057725f Paolo Bonzini
        .name       = "nbd_server_stop",
1384 4057725f Paolo Bonzini
        .args_type  = "",
1385 4057725f Paolo Bonzini
        .params     = "nbd_server_stop",
1386 4057725f Paolo Bonzini
        .help       = "stop serving block devices using the NBD protocol",
1387 4057725f Paolo Bonzini
        .mhandler.cmd = hmp_nbd_server_stop,
1388 4057725f Paolo Bonzini
    },
1389 4057725f Paolo Bonzini
STEXI
1390 4057725f Paolo Bonzini
@item nbd_server_stop
1391 4057725f Paolo Bonzini
@findex nbd_server_stop
1392 4057725f Paolo Bonzini
Stop the QEMU embedded NBD server.
1393 4057725f Paolo Bonzini
ETEXI
1394 4057725f Paolo Bonzini
1395 4057725f Paolo Bonzini
1396 79c4f6b0 Huang Ying
#if defined(TARGET_I386)
1397 d7f9b689 Luiz Capitulino
1398 d7f9b689 Luiz Capitulino
    {
1399 d7f9b689 Luiz Capitulino
        .name       = "mce",
1400 31ce5e0c Jin Dongming
        .args_type  = "broadcast:-b,cpu_index:i,bank:i,status:l,mcg_status:l,addr:l,misc:l",
1401 31ce5e0c Jin Dongming
        .params     = "[-b] cpu bank status mcgstatus addr misc",
1402 31ce5e0c Jin Dongming
        .help       = "inject a MCE on the given CPU [and broadcast to other CPUs with -b option]",
1403 af4ce882 Luiz Capitulino
        .mhandler.cmd = do_inject_mce,
1404 d7f9b689 Luiz Capitulino
    },
1405 d7f9b689 Luiz Capitulino
1406 79c4f6b0 Huang Ying
#endif
1407 79c4f6b0 Huang Ying
STEXI
1408 79c4f6b0 Huang Ying
@item mce @var{cpu} @var{bank} @var{status} @var{mcgstatus} @var{addr} @var{misc}
1409 70fcbbe7 Stefan Weil
@findex mce (x86)
1410 79c4f6b0 Huang Ying
Inject an MCE on the given CPU (x86 only).
1411 79c4f6b0 Huang Ying
ETEXI
1412 79c4f6b0 Huang Ying
1413 d7f9b689 Luiz Capitulino
    {
1414 d7f9b689 Luiz Capitulino
        .name       = "getfd",
1415 d7f9b689 Luiz Capitulino
        .args_type  = "fdname:s",
1416 d7f9b689 Luiz Capitulino
        .params     = "getfd name",
1417 d7f9b689 Luiz Capitulino
        .help       = "receive a file descriptor via SCM rights and assign it a name",
1418 208c9d1b Corey Bryant
        .mhandler.cmd = hmp_getfd,
1419 d7f9b689 Luiz Capitulino
    },
1420 d7f9b689 Luiz Capitulino
1421 f07918fd Mark McLoughlin
STEXI
1422 f07918fd Mark McLoughlin
@item getfd @var{fdname}
1423 70fcbbe7 Stefan Weil
@findex getfd
1424 f07918fd Mark McLoughlin
If a file descriptor is passed alongside this command using the SCM_RIGHTS
1425 f07918fd Mark McLoughlin
mechanism on unix sockets, it is stored using the name @var{fdname} for
1426 f07918fd Mark McLoughlin
later use by other monitor commands.
1427 f07918fd Mark McLoughlin
ETEXI
1428 f07918fd Mark McLoughlin
1429 d7f9b689 Luiz Capitulino
    {
1430 d7f9b689 Luiz Capitulino
        .name       = "closefd",
1431 d7f9b689 Luiz Capitulino
        .args_type  = "fdname:s",
1432 d7f9b689 Luiz Capitulino
        .params     = "closefd name",
1433 d7f9b689 Luiz Capitulino
        .help       = "close a file descriptor previously passed via SCM rights",
1434 208c9d1b Corey Bryant
        .mhandler.cmd = hmp_closefd,
1435 d7f9b689 Luiz Capitulino
    },
1436 d7f9b689 Luiz Capitulino
1437 f07918fd Mark McLoughlin
STEXI
1438 f07918fd Mark McLoughlin
@item closefd @var{fdname}
1439 70fcbbe7 Stefan Weil
@findex closefd
1440 f07918fd Mark McLoughlin
Close the file descriptor previously assigned to @var{fdname} using the
1441 f07918fd Mark McLoughlin
@code{getfd} command. This is only needed if the file descriptor was never
1442 f07918fd Mark McLoughlin
used by another monitor command.
1443 f07918fd Mark McLoughlin
ETEXI
1444 f07918fd Mark McLoughlin
1445 a3a55a2e Luiz Capitulino
    {
1446 a3a55a2e Luiz Capitulino
        .name       = "block_passwd",
1447 a3a55a2e Luiz Capitulino
        .args_type  = "device:B,password:s",
1448 a3a55a2e Luiz Capitulino
        .params     = "block_passwd device password",
1449 a3a55a2e Luiz Capitulino
        .help       = "set the password of encrypted block devices",
1450 a4dea8a9 Luiz Capitulino
        .mhandler.cmd = hmp_block_passwd,
1451 a3a55a2e Luiz Capitulino
    },
1452 a3a55a2e Luiz Capitulino
1453 a3a55a2e Luiz Capitulino
STEXI
1454 727f005e Zhi Yong Wu
@item block_set_io_throttle @var{device} @var{bps} @var{bps_rd} @var{bps_wr} @var{iops} @var{iops_rd} @var{iops_wr}
1455 727f005e Zhi Yong Wu
@findex block_set_io_throttle
1456 727f005e Zhi Yong Wu
Change I/O throttle limits for a block drive to @var{bps} @var{bps_rd} @var{bps_wr} @var{iops} @var{iops_rd} @var{iops_wr}
1457 727f005e Zhi Yong Wu
ETEXI
1458 727f005e Zhi Yong Wu
1459 727f005e Zhi Yong Wu
    {
1460 727f005e Zhi Yong Wu
        .name       = "block_set_io_throttle",
1461 727f005e Zhi Yong Wu
        .args_type  = "device:B,bps:l,bps_rd:l,bps_wr:l,iops:l,iops_rd:l,iops_wr:l",
1462 727f005e Zhi Yong Wu
        .params     = "device bps bps_rd bps_wr iops iops_rd iops_wr",
1463 727f005e Zhi Yong Wu
        .help       = "change I/O throttle limits for a block drive",
1464 80047da5 Luiz Capitulino
        .mhandler.cmd = hmp_block_set_io_throttle,
1465 727f005e Zhi Yong Wu
    },
1466 727f005e Zhi Yong Wu
1467 727f005e Zhi Yong Wu
STEXI
1468 a3a55a2e Luiz Capitulino
@item block_passwd @var{device} @var{password}
1469 70fcbbe7 Stefan Weil
@findex block_passwd
1470 a3a55a2e Luiz Capitulino
Set the encrypted device @var{device} password to @var{password}
1471 a3a55a2e Luiz Capitulino
ETEXI
1472 b40292e7 Jan Kiszka
1473 33572ece Jan Kiszka
    {
1474 7572150c Gerd Hoffmann
        .name       = "set_password",
1475 7572150c Gerd Hoffmann
        .args_type  = "protocol:s,password:s,connected:s?",
1476 7572150c Gerd Hoffmann
        .params     = "protocol password action-if-connected",
1477 7572150c Gerd Hoffmann
        .help       = "set spice/vnc password",
1478 fbf796fd Luiz Capitulino
        .mhandler.cmd = hmp_set_password,
1479 7572150c Gerd Hoffmann
    },
1480 7572150c Gerd Hoffmann
1481 7572150c Gerd Hoffmann
STEXI
1482 7572150c Gerd Hoffmann
@item set_password [ vnc | spice ] password [ action-if-connected ]
1483 7572150c Gerd Hoffmann
@findex set_password
1484 7572150c Gerd Hoffmann
1485 7572150c Gerd Hoffmann
Change spice/vnc password.  Use zero to make the password stay valid
1486 7572150c Gerd Hoffmann
forever.  @var{action-if-connected} specifies what should happen in
1487 7572150c Gerd Hoffmann
case a connection is established: @var{fail} makes the password change
1488 7572150c Gerd Hoffmann
fail.  @var{disconnect} changes the password and disconnects the
1489 7572150c Gerd Hoffmann
client.  @var{keep} changes the password and keeps the connection up.
1490 7572150c Gerd Hoffmann
@var{keep} is the default.
1491 7572150c Gerd Hoffmann
ETEXI
1492 7572150c Gerd Hoffmann
1493 7572150c Gerd Hoffmann
    {
1494 7572150c Gerd Hoffmann
        .name       = "expire_password",
1495 7572150c Gerd Hoffmann
        .args_type  = "protocol:s,time:s",
1496 7572150c Gerd Hoffmann
        .params     = "protocol time",
1497 7572150c Gerd Hoffmann
        .help       = "set spice/vnc password expire-time",
1498 9ad5372d Luiz Capitulino
        .mhandler.cmd = hmp_expire_password,
1499 7572150c Gerd Hoffmann
    },
1500 7572150c Gerd Hoffmann
1501 7572150c Gerd Hoffmann
STEXI
1502 7572150c Gerd Hoffmann
@item expire_password [ vnc | spice ] expire-time
1503 7572150c Gerd Hoffmann
@findex expire_password
1504 7572150c Gerd Hoffmann
1505 7572150c Gerd Hoffmann
Specify when a password for spice/vnc becomes
1506 7572150c Gerd Hoffmann
invalid. @var{expire-time} accepts:
1507 7572150c Gerd Hoffmann
1508 7572150c Gerd Hoffmann
@table @var
1509 7572150c Gerd Hoffmann
@item now
1510 7572150c Gerd Hoffmann
Invalidate password instantly.
1511 7572150c Gerd Hoffmann
1512 7572150c Gerd Hoffmann
@item never
1513 7572150c Gerd Hoffmann
Password stays valid forever.
1514 7572150c Gerd Hoffmann
1515 7572150c Gerd Hoffmann
@item +nsec
1516 7572150c Gerd Hoffmann
Password stays valid for @var{nsec} seconds starting now.
1517 7572150c Gerd Hoffmann
1518 7572150c Gerd Hoffmann
@item nsec
1519 7572150c Gerd Hoffmann
Password is invalidated at the given time.  @var{nsec} are the seconds
1520 7572150c Gerd Hoffmann
passed since 1970, i.e. unix epoch.
1521 7572150c Gerd Hoffmann
1522 7572150c Gerd Hoffmann
@end table
1523 7572150c Gerd Hoffmann
ETEXI
1524 7572150c Gerd Hoffmann
1525 46920825 Gerd Hoffmann
    {
1526 46920825 Gerd Hoffmann
        .name       = "chardev-add",
1527 46920825 Gerd Hoffmann
        .args_type  = "args:s",
1528 46920825 Gerd Hoffmann
        .params     = "args",
1529 46920825 Gerd Hoffmann
        .help       = "add chardev",
1530 46920825 Gerd Hoffmann
        .mhandler.cmd = hmp_chardev_add,
1531 46920825 Gerd Hoffmann
    },
1532 46920825 Gerd Hoffmann
1533 46920825 Gerd Hoffmann
STEXI
1534 46920825 Gerd Hoffmann
@item chardev_add args
1535 46920825 Gerd Hoffmann
@findex chardev_add
1536 46920825 Gerd Hoffmann
1537 46920825 Gerd Hoffmann
chardev_add accepts the same parameters as the -chardev command line switch.
1538 46920825 Gerd Hoffmann
1539 46920825 Gerd Hoffmann
ETEXI
1540 46920825 Gerd Hoffmann
1541 46920825 Gerd Hoffmann
    {
1542 46920825 Gerd Hoffmann
        .name       = "chardev-remove",
1543 46920825 Gerd Hoffmann
        .args_type  = "id:s",
1544 46920825 Gerd Hoffmann
        .params     = "id",
1545 46920825 Gerd Hoffmann
        .help       = "remove chardev",
1546 46920825 Gerd Hoffmann
        .mhandler.cmd = hmp_chardev_remove,
1547 46920825 Gerd Hoffmann
    },
1548 46920825 Gerd Hoffmann
1549 46920825 Gerd Hoffmann
STEXI
1550 46920825 Gerd Hoffmann
@item chardev_remove id
1551 46920825 Gerd Hoffmann
@findex chardev_remove
1552 46920825 Gerd Hoffmann
1553 46920825 Gerd Hoffmann
Removes the chardev @var{id}.
1554 46920825 Gerd Hoffmann
1555 46920825 Gerd Hoffmann
ETEXI
1556 f1088908 Gerd Hoffmann
1557 f1088908 Gerd Hoffmann
    {
1558 33572ece Jan Kiszka
        .name       = "info",
1559 33572ece Jan Kiszka
        .args_type  = "item:s?",
1560 33572ece Jan Kiszka
        .params     = "[subcommand]",
1561 33572ece Jan Kiszka
        .help       = "show various information about the system state",
1562 84c44613 Wenchao Xia
        .mhandler.cmd = do_info_help,
1563 84c44613 Wenchao Xia
        .sub_table = info_cmds,
1564 33572ece Jan Kiszka
    },
1565 33572ece Jan Kiszka
1566 33572ece Jan Kiszka
STEXI
1567 33572ece Jan Kiszka
@item info @var{subcommand}
1568 33572ece Jan Kiszka
@findex info
1569 33572ece Jan Kiszka
Show various information about the system state.
1570 33572ece Jan Kiszka
1571 33572ece Jan Kiszka
@table @option
1572 33572ece Jan Kiszka
@item info version
1573 33572ece Jan Kiszka
show the version of QEMU
1574 33572ece Jan Kiszka
@item info network
1575 33572ece Jan Kiszka
show the various VLANs and the associated devices
1576 33572ece Jan Kiszka
@item info chardev
1577 33572ece Jan Kiszka
show the character devices
1578 33572ece Jan Kiszka
@item info block
1579 33572ece Jan Kiszka
show the block devices
1580 33572ece Jan Kiszka
@item info blockstats
1581 33572ece Jan Kiszka
show block device statistics
1582 33572ece Jan Kiszka
@item info registers
1583 33572ece Jan Kiszka
show the cpu registers
1584 33572ece Jan Kiszka
@item info cpus
1585 33572ece Jan Kiszka
show infos for each CPU
1586 33572ece Jan Kiszka
@item info history
1587 33572ece Jan Kiszka
show the command line history
1588 33572ece Jan Kiszka
@item info irq
1589 33572ece Jan Kiszka
show the interrupts statistics (if available)
1590 33572ece Jan Kiszka
@item info pic
1591 33572ece Jan Kiszka
show i8259 (PIC) state
1592 33572ece Jan Kiszka
@item info pci
1593 33572ece Jan Kiszka
show emulated PCI device info
1594 33572ece Jan Kiszka
@item info tlb
1595 692f737c Max Filippov
show virtual to physical memory mappings (i386, SH4, SPARC, PPC, and Xtensa only)
1596 33572ece Jan Kiszka
@item info mem
1597 33572ece Jan Kiszka
show the active virtual memory mappings (i386 only)
1598 33572ece Jan Kiszka
@item info jit
1599 33572ece Jan Kiszka
show dynamic compiler info
1600 33572ece Jan Kiszka
@item info numa
1601 33572ece Jan Kiszka
show NUMA information
1602 b40292e7 Jan Kiszka
@item info kvm
1603 b40292e7 Jan Kiszka
show KVM information
1604 33572ece Jan Kiszka
@item info usb
1605 33572ece Jan Kiszka
show USB devices plugged on the virtual USB hub
1606 33572ece Jan Kiszka
@item info usbhost
1607 33572ece Jan Kiszka
show all USB host devices
1608 33572ece Jan Kiszka
@item info profile
1609 33572ece Jan Kiszka
show profiling information
1610 33572ece Jan Kiszka
@item info capture
1611 33572ece Jan Kiszka
show information about active capturing
1612 33572ece Jan Kiszka
@item info snapshots
1613 33572ece Jan Kiszka
show list of VM snapshots
1614 33572ece Jan Kiszka
@item info status
1615 33572ece Jan Kiszka
show the current VM status (running|paused)
1616 33572ece Jan Kiszka
@item info pcmcia
1617 33572ece Jan Kiszka
show guest PCMCIA status
1618 33572ece Jan Kiszka
@item info mice
1619 33572ece Jan Kiszka
show which guest mouse is receiving events
1620 33572ece Jan Kiszka
@item info vnc
1621 33572ece Jan Kiszka
show the vnc server status
1622 33572ece Jan Kiszka
@item info name
1623 33572ece Jan Kiszka
show the current VM name
1624 33572ece Jan Kiszka
@item info uuid
1625 33572ece Jan Kiszka
show the current VM UUID
1626 33572ece Jan Kiszka
@item info cpustats
1627 33572ece Jan Kiszka
show CPU statistics
1628 33572ece Jan Kiszka
@item info usernet
1629 33572ece Jan Kiszka
show user network stack connection states
1630 33572ece Jan Kiszka
@item info migrate
1631 33572ece Jan Kiszka
show migration status
1632 bbf6da32 Orit Wasserman
@item info migrate_capabilities
1633 bbf6da32 Orit Wasserman
show current migration capabilities
1634 9e1ba4cc Orit Wasserman
@item info migrate_cache_size
1635 9e1ba4cc Orit Wasserman
show current migration XBZRLE cache size
1636 33572ece Jan Kiszka
@item info balloon
1637 33572ece Jan Kiszka
show balloon information
1638 33572ece Jan Kiszka
@item info qtree
1639 33572ece Jan Kiszka
show device tree
1640 33572ece Jan Kiszka
@item info qdm
1641 33572ece Jan Kiszka
show qdev device model list
1642 33572ece Jan Kiszka
@item info roms
1643 33572ece Jan Kiszka
show roms
1644 d1a0cf73 Stefan Berger
@item info tpm
1645 d1a0cf73 Stefan Berger
show the TPM device
1646 33572ece Jan Kiszka
@end table
1647 33572ece Jan Kiszka
ETEXI
1648 33572ece Jan Kiszka
1649 31965ae2 Lluís
STEXI
1650 22890ab5 Prerna Saxena
@item info trace-events
1651 22890ab5 Prerna Saxena
show available trace events and their state
1652 22890ab5 Prerna Saxena
ETEXI
1653 22890ab5 Prerna Saxena
1654 2313086a Blue Swirl
STEXI
1655 2313086a Blue Swirl
@end table
1656 2313086a Blue Swirl
ETEXI