aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2016-06-23 13:42:29 +0200
committerMarkus Armbruster <armbru@redhat.com>2017-01-16 09:15:30 +0100
commit2212092e11db4c92416f989db9000737daaf9d37 (patch)
tree8df264ef0617cfafc295afec00b1ca1f46793e49
parent77b6681ec224af6047a4ba76d7558c150a205718 (diff)
qmp-commands: move 'chardev-add' doc to schema
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com>
-rw-r--r--docs/qmp-commands.txt28
-rw-r--r--qapi-schema.json19
2 files changed, 19 insertions, 28 deletions
diff --git a/docs/qmp-commands.txt b/docs/qmp-commands.txt
index 4201b50279..393e2280bf 100644
--- a/docs/qmp-commands.txt
+++ b/docs/qmp-commands.txt
@@ -1252,34 +1252,6 @@ Example:
-> { "execute": "query-tpm-types" }
<- { "return": [ "passthrough" ] }
-chardev-add
-----------------
-
-Add a chardev.
-
-Arguments:
-
-- "id": the chardev's ID, must be unique (json-string)
-- "backend": chardev backend type + parameters
-
-Examples:
-
--> { "execute" : "chardev-add",
- "arguments" : { "id" : "foo",
- "backend" : { "type" : "null", "data" : {} } } }
-<- { "return": {} }
-
--> { "execute" : "chardev-add",
- "arguments" : { "id" : "bar",
- "backend" : { "type" : "file",
- "data" : { "out" : "/tmp/bar.log" } } } }
-<- { "return": {} }
-
--> { "execute" : "chardev-add",
- "arguments" : { "id" : "baz",
- "backend" : { "type" : "pty", "data" : {} } } }
-<- { "return": { "pty" : "/dev/pty/42" } }
-
chardev-remove
--------------
diff --git a/qapi-schema.json b/qapi-schema.json
index 2f171c0155..9b6a8d35b8 100644
--- a/qapi-schema.json
+++ b/qapi-schema.json
@@ -4839,6 +4839,25 @@
# Returns: ChardevReturn.
#
# Since: 1.4
+#
+# Example:
+#
+# -> { "execute" : "chardev-add",
+# "arguments" : { "id" : "foo",
+# "backend" : { "type" : "null", "data" : {} } } }
+# <- { "return": {} }
+#
+# -> { "execute" : "chardev-add",
+# "arguments" : { "id" : "bar",
+# "backend" : { "type" : "file",
+# "data" : { "out" : "/tmp/bar.log" } } } }
+# <- { "return": {} }
+#
+# -> { "execute" : "chardev-add",
+# "arguments" : { "id" : "baz",
+# "backend" : { "type" : "pty", "data" : {} } } }
+# <- { "return": { "pty" : "/dev/pty/42" } }
+#
##
{ 'command': 'chardev-add', 'data': {'id' : 'str',
'backend' : 'ChardevBackend' },