* [PULL 00/11] QAPI patches patches for 2025-04-08
@ 2025-04-08 7:19 Markus Armbruster
2025-04-08 7:19 ` [PULL 01/11] docs/devel/qapi-code-gen: Tidy up whitespace Markus Armbruster
` (12 more replies)
0 siblings, 13 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha
The following changes since commit dfaecc04c46d298e9ee81bd0ca96d8754f1c27ed:
Merge tag 'pull-riscv-to-apply-20250407-1' of https://github.com/alistair23/qemu into staging (2025-04-07 09:18:33 -0400)
are available in the Git repository at:
https://repo.or.cz/qemu/armbru.git tags/pull-qapi-2025-04-08
for you to fetch changes up to 8d41a7dfc2a8f21228b7f29314dd68ad0aa96d10:
qga/qapi-schema: Add a proper introduction (2025-04-08 09:04:34 +0200)
----------------------------------------------------------------
QAPI patches patches for 2025-04-08
----------------------------------------------------------------
Markus Armbruster (11):
docs/devel/qapi-code-gen: Tidy up whitespace
qapi/rocker: Tidy up query-rocker-of-dpa-flows example
docs/interop: Delete "QEMU Guest Agent Protocol Reference" TOC
docs/interop: Sanitize QMP reference manuals TOC
docs/devel/qapi-code-gen: Improve the part on qmp-example directive
docs/sphinx/qmp_lexer: Generalize elision syntax
docs/sphinx/qmp_lexer: Highlight elisions like comments, not prompts
qapi/qapi-schema: Update introduction for example notation
qapi/qapi-schema: Address the introduction's bit rot
storage-daemon/qapi/qapi-schema: Add a proper introduction
qga/qapi-schema: Add a proper introduction
docs/devel/qapi-code-gen.rst | 53 ++++++++++++++++------------
docs/interop/qemu-ga-ref.rst | 3 --
docs/interop/qemu-qmp-ref.rst | 2 +-
docs/interop/qemu-storage-daemon-qmp-ref.rst | 2 +-
docs/sphinx/qmp_lexer.py | 2 +-
qapi/qapi-schema.json | 31 +++++-----------
qapi/rocker.json | 2 +-
qga/qapi-schema.json | 20 +++++++++--
storage-daemon/qapi/qapi-schema.json | 22 ++++++++++--
tests/qapi-schema/doc-good.json | 2 +-
tests/qapi-schema/doc-good.out | 2 +-
tests/qapi-schema/doc-good.txt | 2 +-
12 files changed, 83 insertions(+), 60 deletions(-)
--
2.48.1
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PULL 01/11] docs/devel/qapi-code-gen: Tidy up whitespace
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
@ 2025-04-08 7:19 ` Markus Armbruster
2025-04-08 7:19 ` [PULL 02/11] qapi/rocker: Tidy up query-rocker-of-dpa-flows example Markus Armbruster
` (11 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
Consistently use two spaces to separate sentences.
Put "::" on a line of its own when it's preceded by whitespace.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-2-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
docs/devel/qapi-code-gen.rst | 26 ++++++++++++++------------
1 file changed, 14 insertions(+), 12 deletions(-)
diff --git a/docs/devel/qapi-code-gen.rst b/docs/devel/qapi-code-gen.rst
index f9cfe8721f..ad517349fc 100644
--- a/docs/devel/qapi-code-gen.rst
+++ b/docs/devel/qapi-code-gen.rst
@@ -763,8 +763,8 @@ Names beginning with ``x-`` used to signify "experimental". This
convention has been replaced by special feature "unstable".
Pragmas ``command-name-exceptions`` and ``member-name-exceptions`` let
-you violate naming rules. Use for new code is strongly discouraged. See
-`Pragma directives`_ for details.
+you violate naming rules. Use for new code is strongly discouraged.
+See `Pragma directives`_ for details.
Downstream extensions
@@ -1013,7 +1013,7 @@ like this::
document the success and the error response, respectively.
"Errors" sections should be formatted as an rST list, each entry
-detailing a relevant error condition. For example::
+detailing a relevant error condition. For example::
# Errors:
# - If @device does not exist, DeviceNotFound
@@ -1026,13 +1026,13 @@ definition.
QMP). In other sections, the text is formatted, and rST markup can be
used.
-QMP Examples can be added by using the ``.. qmp-example::``
-directive. In its simplest form, this can be used to contain a single
-QMP code block which accepts standard JSON syntax with additional server
+QMP Examples can be added by using the ``.. qmp-example::`` directive.
+In its simplest form, this can be used to contain a single QMP code
+block which accepts standard JSON syntax with additional server
directionality indicators (``->`` and ``<-``), and elisions (``...``).
Optionally, a plaintext title may be provided by using the ``:title:``
-directive option. If the title is omitted, the example title will
+directive option. If the title is omitted, the example title will
default to "Example:".
A simple QMP example::
@@ -1043,10 +1043,10 @@ A simple QMP example::
# -> { "execute": "query-block" }
# <- { ... }
-More complex or multi-step examples where exposition is needed before or
-between QMP code blocks can be created by using the ``:annotated:``
-directive option. When using this option, nested QMP code blocks must be
-entered explicitly with rST's ``::`` syntax.
+More complex or multi-step examples where exposition is needed before
+or between QMP code blocks can be created by using the ``:annotated:``
+directive option. When using this option, nested QMP code blocks must
+be entered explicitly with rST's ``::`` syntax.
Highlighting in non-QMP languages can be accomplished by using the
``.. code-block:: lang`` directive, and non-highlighted text can be
@@ -1466,7 +1466,9 @@ As an example, we'll use the following schema, which describes a
single complex user-defined type, along with command which takes a
list of that type as a parameter, and returns a single element of that
type. The user is responsible for writing the implementation of
-qmp_my_command(); everything else is produced by the generator. ::
+qmp_my_command(); everything else is produced by the generator.
+
+::
$ cat example-schema.json
{ 'struct': 'UserDefOne',
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 02/11] qapi/rocker: Tidy up query-rocker-of-dpa-flows example
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
2025-04-08 7:19 ` [PULL 01/11] docs/devel/qapi-code-gen: Tidy up whitespace Markus Armbruster
@ 2025-04-08 7:19 ` Markus Armbruster
2025-04-08 7:19 ` [PULL 03/11] docs/interop: Delete "QEMU Guest Agent Protocol Reference" TOC Markus Armbruster
` (10 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
The command can return any number of RockerOfDpaFlow objects. The
example shows it returning exactly two, with the second object's
members elided. Tweak it so it elides elements after the first
instead.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-3-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
[Commit message typo fixed]
---
qapi/rocker.json | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/qapi/rocker.json b/qapi/rocker.json
index 51aa5b4930..0c7ef1f77c 100644
--- a/qapi/rocker.json
+++ b/qapi/rocker.json
@@ -254,7 +254,7 @@
# "action": {"goto-tbl": 10},
# "mask": {"in-pport": 4294901760}
# },
-# {...},
+# ...
# ]}
##
{ 'command': 'query-rocker-of-dpa-flows',
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 03/11] docs/interop: Delete "QEMU Guest Agent Protocol Reference" TOC
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
2025-04-08 7:19 ` [PULL 01/11] docs/devel/qapi-code-gen: Tidy up whitespace Markus Armbruster
2025-04-08 7:19 ` [PULL 02/11] qapi/rocker: Tidy up query-rocker-of-dpa-flows example Markus Armbruster
@ 2025-04-08 7:19 ` Markus Armbruster
2025-04-08 7:19 ` [PULL 04/11] docs/interop: Sanitize QMP reference manuals TOC Markus Armbruster
` (9 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
The "QEMU Guest Agent Protocol Reference" starts with the following
table of contents:
Contents
* QEMU Guest Agent Protocol Reference
* QEMU guest agent protocol commands and structs
This is useless. Delete the entire TOC.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-4-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
docs/interop/qemu-ga-ref.rst | 3 ---
1 file changed, 3 deletions(-)
diff --git a/docs/interop/qemu-ga-ref.rst b/docs/interop/qemu-ga-ref.rst
index 19b5c7a549..25f6e24b03 100644
--- a/docs/interop/qemu-ga-ref.rst
+++ b/docs/interop/qemu-ga-ref.rst
@@ -1,9 +1,6 @@
QEMU Guest Agent Protocol Reference
===================================
-.. contents::
- :depth: 3
-
.. qapi-doc:: qga/qapi-schema.json
:transmogrify:
:namespace: QGA
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 04/11] docs/interop: Sanitize QMP reference manuals TOC
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (2 preceding siblings ...)
2025-04-08 7:19 ` [PULL 03/11] docs/interop: Delete "QEMU Guest Agent Protocol Reference" TOC Markus Armbruster
@ 2025-04-08 7:19 ` Markus Armbruster
2025-04-08 7:19 ` [PULL 05/11] docs/devel/qapi-code-gen: Improve the part on qmp-example directive Markus Armbruster
` (8 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
The "QEMU QMP Reference Manual" and the "QEMU Storage Daemon QMP
Reference Manual" start with a table of contents that looks like this:
Contents
* Title of the manual
* Title of first first-level section
* Title of its first second-level section
* Title of its second second-level section
...
* Title of second first-level section
...
The first level is useless. Drop it.
While there, delete the option that limits the TOC to depth 3. Its
actual depth was 3 before the patch, and is now 2.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-5-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
docs/interop/qemu-qmp-ref.rst | 2 +-
docs/interop/qemu-storage-daemon-qmp-ref.rst | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/docs/interop/qemu-qmp-ref.rst b/docs/interop/qemu-qmp-ref.rst
index ef8792b53f..3bc1ca12b1 100644
--- a/docs/interop/qemu-qmp-ref.rst
+++ b/docs/interop/qemu-qmp-ref.rst
@@ -4,7 +4,7 @@ QEMU QMP Reference Manual
=========================
.. contents::
- :depth: 3
+ :local:
.. qapi-doc:: qapi/qapi-schema.json
:transmogrify:
diff --git a/docs/interop/qemu-storage-daemon-qmp-ref.rst b/docs/interop/qemu-storage-daemon-qmp-ref.rst
index d0228d63b8..dc7bde262a 100644
--- a/docs/interop/qemu-storage-daemon-qmp-ref.rst
+++ b/docs/interop/qemu-storage-daemon-qmp-ref.rst
@@ -2,7 +2,7 @@ QEMU Storage Daemon QMP Reference Manual
========================================
.. contents::
- :depth: 3
+ :local:
.. qapi-doc:: storage-daemon/qapi/qapi-schema.json
:transmogrify:
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 05/11] docs/devel/qapi-code-gen: Improve the part on qmp-example directive
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (3 preceding siblings ...)
2025-04-08 7:19 ` [PULL 04/11] docs/interop: Sanitize QMP reference manuals TOC Markus Armbruster
@ 2025-04-08 7:19 ` Markus Armbruster
2025-04-08 7:19 ` [PULL 06/11] docs/sphinx/qmp_lexer: Generalize elision syntax Markus Armbruster
` (7 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-6-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
docs/devel/qapi-code-gen.rst | 23 ++++++++++++++---------
1 file changed, 14 insertions(+), 9 deletions(-)
diff --git a/docs/devel/qapi-code-gen.rst b/docs/devel/qapi-code-gen.rst
index ad517349fc..25a46fafb6 100644
--- a/docs/devel/qapi-code-gen.rst
+++ b/docs/devel/qapi-code-gen.rst
@@ -1038,20 +1038,15 @@ default to "Example:".
A simple QMP example::
# .. qmp-example::
- # :title: Using query-block
#
- # -> { "execute": "query-block" }
- # <- { ... }
+ # -> { "execute": "query-name" }
+ # <- { "return": { "name": "Fred" } }
More complex or multi-step examples where exposition is needed before
or between QMP code blocks can be created by using the ``:annotated:``
directive option. When using this option, nested QMP code blocks must
be entered explicitly with rST's ``::`` syntax.
-Highlighting in non-QMP languages can be accomplished by using the
-``.. code-block:: lang`` directive, and non-highlighted text can be
-achieved by omitting the language argument.
-
For example::
# .. qmp-example::
@@ -1061,11 +1056,21 @@ For example::
# This is a more complex example that can use
# ``arbitrary rST syntax`` in its exposition::
#
- # -> { "execute": "query-block" }
- # <- { ... }
+ # -> { "execute": "query-block" }
+ # <- { "return": [
+ # {
+ # "device": "ide0-hd0",
+ # ...
+ # }
+ # ...
+ # ] }
#
# Above, lengthy output has been omitted for brevity.
+Highlighting in non-QMP languages can be accomplished by using the
+``.. code-block:: lang`` directive, and non-highlighted text can be
+achieved by omitting the language argument.
+
Examples of complete definition documentation::
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 06/11] docs/sphinx/qmp_lexer: Generalize elision syntax
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (4 preceding siblings ...)
2025-04-08 7:19 ` [PULL 05/11] docs/devel/qapi-code-gen: Improve the part on qmp-example directive Markus Armbruster
@ 2025-04-08 7:19 ` Markus Armbruster
2025-04-08 7:19 ` [PULL 07/11] docs/sphinx/qmp_lexer: Highlight elisions like comments, not prompts Markus Armbruster
` (6 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
Accept "... lorem ipsum ..." in addition to "...".
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-7-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
docs/devel/qapi-code-gen.rst | 6 ++++--
docs/sphinx/qmp_lexer.py | 2 +-
tests/qapi-schema/doc-good.json | 2 +-
tests/qapi-schema/doc-good.out | 2 +-
tests/qapi-schema/doc-good.txt | 2 +-
5 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/docs/devel/qapi-code-gen.rst b/docs/devel/qapi-code-gen.rst
index 25a46fafb6..231cc0fecf 100644
--- a/docs/devel/qapi-code-gen.rst
+++ b/docs/devel/qapi-code-gen.rst
@@ -1029,7 +1029,9 @@ used.
QMP Examples can be added by using the ``.. qmp-example::`` directive.
In its simplest form, this can be used to contain a single QMP code
block which accepts standard JSON syntax with additional server
-directionality indicators (``->`` and ``<-``), and elisions (``...``).
+directionality indicators (``->`` and ``<-``), and elisions. An
+elision is commonly ``...``, but it can also be or a pair of ``...``
+with text in between.
Optionally, a plaintext title may be provided by using the ``:title:``
directive option. If the title is omitted, the example title will
@@ -1062,7 +1064,7 @@ For example::
# "device": "ide0-hd0",
# ...
# }
- # ...
+ # ... more ...
# ] }
#
# Above, lengthy output has been omitted for brevity.
diff --git a/docs/sphinx/qmp_lexer.py b/docs/sphinx/qmp_lexer.py
index a59de8a079..1bd1b81b70 100644
--- a/docs/sphinx/qmp_lexer.py
+++ b/docs/sphinx/qmp_lexer.py
@@ -24,7 +24,7 @@ class QMPExampleMarkersLexer(RegexLexer):
'root': [
(r'-> ', token.Generic.Prompt),
(r'<- ', token.Generic.Prompt),
- (r' ?\.{3} ?', token.Generic.Prompt),
+ (r'\.{3}( .* \.{3})?', token.Generic.Prompt),
]
}
diff --git a/tests/qapi-schema/doc-good.json b/tests/qapi-schema/doc-good.json
index 0a4f139f83..14b808f909 100644
--- a/tests/qapi-schema/doc-good.json
+++ b/tests/qapi-schema/doc-good.json
@@ -212,7 +212,7 @@
#
# -> "this example"
#
-# <- "has no title"
+# <- ... has no title ...
##
{ 'command': 'cmd-boxed', 'boxed': true,
'data': 'Object',
diff --git a/tests/qapi-schema/doc-good.out b/tests/qapi-schema/doc-good.out
index 5773f1dd6d..dc8352eed4 100644
--- a/tests/qapi-schema/doc-good.out
+++ b/tests/qapi-schema/doc-good.out
@@ -217,7 +217,7 @@ another feature
-> "this example"
- <- "has no title"
+ <- ... has no title ...
doc symbol=EVT_BOXED
body=
diff --git a/tests/qapi-schema/doc-good.txt b/tests/qapi-schema/doc-good.txt
index cb37db606a..17a1d56ef1 100644
--- a/tests/qapi-schema/doc-good.txt
+++ b/tests/qapi-schema/doc-good.txt
@@ -264,7 +264,7 @@ Example::
-> "this example"
- <- "has no title"
+ <- ... has no title ...
"EVT_BOXED" (Event)
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 07/11] docs/sphinx/qmp_lexer: Highlight elisions like comments, not prompts
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (5 preceding siblings ...)
2025-04-08 7:19 ` [PULL 06/11] docs/sphinx/qmp_lexer: Generalize elision syntax Markus Armbruster
@ 2025-04-08 7:19 ` Markus Armbruster
2025-04-08 7:19 ` [PULL 08/11] qapi/qapi-schema: Update introduction for example notation Markus Armbruster
` (5 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-8-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
docs/sphinx/qmp_lexer.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/sphinx/qmp_lexer.py b/docs/sphinx/qmp_lexer.py
index 1bd1b81b70..7b3b808d12 100644
--- a/docs/sphinx/qmp_lexer.py
+++ b/docs/sphinx/qmp_lexer.py
@@ -24,7 +24,7 @@ class QMPExampleMarkersLexer(RegexLexer):
'root': [
(r'-> ', token.Generic.Prompt),
(r'<- ', token.Generic.Prompt),
- (r'\.{3}( .* \.{3})?', token.Generic.Prompt),
+ (r'\.{3}( .* \.{3})?', token.Comment.Multiline),
]
}
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 08/11] qapi/qapi-schema: Update introduction for example notation
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (6 preceding siblings ...)
2025-04-08 7:19 ` [PULL 07/11] docs/sphinx/qmp_lexer: Highlight elisions like comments, not prompts Markus Armbruster
@ 2025-04-08 7:19 ` Markus Armbruster
2025-04-08 7:19 ` [PULL 09/11] qapi/qapi-schema: Address the introduction's bit rot Markus Armbruster
` (4 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
The introduction explains example notation. The series merged in
merge commit e6485190f77e (in 9.1) improved how they look in generated
docs, but neglected to update the introduction accordingly. Do that
now.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-9-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
qapi/qapi-schema.json | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/qapi/qapi-schema.json b/qapi/qapi-schema.json
index c41c01eb2a..0d027d5017 100644
--- a/qapi/qapi-schema.json
+++ b/qapi/qapi-schema.json
@@ -26,10 +26,10 @@
#
# Example:
#
-# ::
+# .. qmp-example::
#
-# -> data issued by the Client
-# <- Server data response
+# -> ... text sent by client (commands) ...
+# <- ... text sent by server (command responses and events) ...
#
# Please refer to the
# :doc:`QEMU Machine Protocol Specification </interop/qmp-spec>`
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 09/11] qapi/qapi-schema: Address the introduction's bit rot
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (7 preceding siblings ...)
2025-04-08 7:19 ` [PULL 08/11] qapi/qapi-schema: Update introduction for example notation Markus Armbruster
@ 2025-04-08 7:19 ` Markus Armbruster
2025-04-08 7:20 ` [PULL 10/11] storage-daemon/qapi/qapi-schema: Add a proper introduction Markus Armbruster
` (3 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:19 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
Cut the crap that stopped making sense years ago. Adjust the
remainder.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-10-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
qapi/qapi-schema.json | 27 +++++++--------------------
1 file changed, 7 insertions(+), 20 deletions(-)
diff --git a/qapi/qapi-schema.json b/qapi/qapi-schema.json
index 0d027d5017..7bc600bb76 100644
--- a/qapi/qapi-schema.json
+++ b/qapi/qapi-schema.json
@@ -3,37 +3,24 @@
##
# = Introduction
#
-# This document describes all commands currently supported by QMP.
+# This manual describes the commands and events supported by the QEMU
+# Monitor Protocol (QMP).
#
# For locating a particular item, please see the `qapi-qmp-index`.
#
-# Most of the time their usage is exactly the same as in the user
-# Monitor, this means that any other document which also describe
-# commands (the manpage, QEMU's manual, etc) can and should be
-# consulted.
-#
-# QMP has two types of commands: regular and query commands. Regular
-# commands usually change the Virtual Machine's state someway, while
-# query commands just return information. The sections below are
-# divided accordingly.
-#
-# It's important to observe that all communication examples are
-# formatted in a reader-friendly way, so that they're easier to
-# understand. However, in real protocol usage, they're emitted as a
-# single line.
-#
-# Also, the following notation is used to denote data flow:
-#
-# Example:
+# The following notation is used in examples:
#
# .. qmp-example::
#
# -> ... text sent by client (commands) ...
# <- ... text sent by server (command responses and events) ...
#
+# Example text is formatted for readability. However, in real
+# protocol usage, its commonly emitted as a single line.
+#
# Please refer to the
# :doc:`QEMU Machine Protocol Specification </interop/qmp-spec>`
-# for detailed information on the Server command and response formats.
+# for the general format of commands, responses, and events.
##
{ 'include': 'pragma.json' }
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 10/11] storage-daemon/qapi/qapi-schema: Add a proper introduction
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (8 preceding siblings ...)
2025-04-08 7:19 ` [PULL 09/11] qapi/qapi-schema: Address the introduction's bit rot Markus Armbruster
@ 2025-04-08 7:20 ` Markus Armbruster
2025-04-08 7:20 ` [PULL 11/11] qga/qapi-schema: " Markus Armbruster
` (2 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:20 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
Contents adapted from qapi/qapi-schema.json.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-11-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
storage-daemon/qapi/qapi-schema.json | 22 +++++++++++++++++++---
1 file changed, 19 insertions(+), 3 deletions(-)
diff --git a/storage-daemon/qapi/qapi-schema.json b/storage-daemon/qapi/qapi-schema.json
index 2a562ee32e..0427594c98 100644
--- a/storage-daemon/qapi/qapi-schema.json
+++ b/storage-daemon/qapi/qapi-schema.json
@@ -14,10 +14,26 @@
# storage daemon.
##
-# = QEMU storage daemon protocol commands and structs
+# = Introduction
#
-# For a concise listing of all commands, events, and types in the QEMU
-# storage daemon, please consult the `qapi-qsd-index`.
+# This manual describes the commands and events supported by the QEMU
+# storage daemon QMP.
+#
+# For locating a particular item, please see the `qapi-qsd-index`.
+#
+# The following notation is used in examples:
+#
+# .. qmp-example::
+#
+# -> ... text sent by client (commands) ...
+# <- ... text sent by server (command responses and events) ...
+#
+# Example text is formatted for readability. However, in real
+# protocol usage, its commonly emitted as a single line.
+#
+# Please refer to the
+# :doc:`QEMU Machine Protocol Specification </interop/qmp-spec>`
+# for the general format of commands, responses, and events.
##
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PULL 11/11] qga/qapi-schema: Add a proper introduction
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (9 preceding siblings ...)
2025-04-08 7:20 ` [PULL 10/11] storage-daemon/qapi/qapi-schema: Add a proper introduction Markus Armbruster
@ 2025-04-08 7:20 ` Markus Armbruster
2025-04-08 7:45 ` [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
2025-04-09 8:31 ` Stefan Hajnoczi
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:20 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha, Eric Blake
Contents adapted from qapi/qapi-schema.json.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250404121413.1743790-12-armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
qga/qapi-schema.json | 20 +++++++++++++++++---
1 file changed, 17 insertions(+), 3 deletions(-)
diff --git a/qga/qapi-schema.json b/qga/qapi-schema.json
index 35ec0e7db3..5316bfacbf 100644
--- a/qga/qapi-schema.json
+++ b/qga/qapi-schema.json
@@ -2,10 +2,24 @@
# vim: filetype=python
##
-# = QEMU guest agent protocol commands and structs
+# This manual describes the commands supported by the QEMU Guest
+# Agent Protocol.
#
-# For a concise listing of all commands, events, and types in the QEMU
-# guest agent, please consult the `qapi-qga-index`.
+# For locating a particular item, please see the `qapi-qga-index`.
+#
+# The following notation is used in examples:
+#
+# .. qmp-example::
+#
+# -> ... text sent by client (commands) ...
+# <- ... text sent by server (command responses and events) ...
+#
+# Example text is formatted for readability. However, in real
+# protocol usage, its commonly emitted as a single line.
+#
+# Please refer to the
+# :doc:`QEMU Machine Protocol Specification </interop/qmp-spec>`
+# for the general format of commands, responses, and events.
##
{ 'pragma': { 'doc-required': true } }
--
2.48.1
^ permalink raw reply related [flat|nested] 14+ messages in thread
* Re: [PULL 00/11] QAPI patches patches for 2025-04-08
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (10 preceding siblings ...)
2025-04-08 7:20 ` [PULL 11/11] qga/qapi-schema: " Markus Armbruster
@ 2025-04-08 7:45 ` Markus Armbruster
2025-04-09 8:31 ` Stefan Hajnoczi
12 siblings, 0 replies; 14+ messages in thread
From: Markus Armbruster @ 2025-04-08 7:45 UTC (permalink / raw)
To: qemu-devel; +Cc: stefanha
Here's my argument for taking this into 10.0.
The changes can be divided into four parts:
1. Address deficiencies right at the beginning of the three QMP manuals:
* "QEMU QMP Reference Manual" section "Introduction" suffers from bit
rot: much of the contents is useless or misleading.
* The "QEMU Storage Daemon QMP Reference Manual" and the "QEMU Guest
Agent Protocol Reference" lack a proper introduction.
* "QEMU Guest Agent Protocol Reference" has a useless table of
contents.
* "QEMU QMP Reference Manual" and "QEMU Storage Daemon QMP Reference
Manual" both have a needlessly ugly table of contents.
2. Render the example notation in these introductions properly. This
involves changing *one* line of code in docs/sphinx/qmp_lexer.py.
This is the only code change, everything else is documentation.
3. Minor cleanup of rocker QMP documentation
4. Minor improvement of QAPI developer documentation
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PULL 00/11] QAPI patches patches for 2025-04-08
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
` (11 preceding siblings ...)
2025-04-08 7:45 ` [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
@ 2025-04-09 8:31 ` Stefan Hajnoczi
12 siblings, 0 replies; 14+ messages in thread
From: Stefan Hajnoczi @ 2025-04-09 8:31 UTC (permalink / raw)
To: Markus Armbruster; +Cc: qemu-devel, stefanha
[-- Attachment #1: Type: text/plain, Size: 116 bytes --]
Applied, thanks.
Please update the changelog at https://wiki.qemu.org/ChangeLog/10.0 for any user-visible changes.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2025-04-09 8:31 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-08 7:19 [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
2025-04-08 7:19 ` [PULL 01/11] docs/devel/qapi-code-gen: Tidy up whitespace Markus Armbruster
2025-04-08 7:19 ` [PULL 02/11] qapi/rocker: Tidy up query-rocker-of-dpa-flows example Markus Armbruster
2025-04-08 7:19 ` [PULL 03/11] docs/interop: Delete "QEMU Guest Agent Protocol Reference" TOC Markus Armbruster
2025-04-08 7:19 ` [PULL 04/11] docs/interop: Sanitize QMP reference manuals TOC Markus Armbruster
2025-04-08 7:19 ` [PULL 05/11] docs/devel/qapi-code-gen: Improve the part on qmp-example directive Markus Armbruster
2025-04-08 7:19 ` [PULL 06/11] docs/sphinx/qmp_lexer: Generalize elision syntax Markus Armbruster
2025-04-08 7:19 ` [PULL 07/11] docs/sphinx/qmp_lexer: Highlight elisions like comments, not prompts Markus Armbruster
2025-04-08 7:19 ` [PULL 08/11] qapi/qapi-schema: Update introduction for example notation Markus Armbruster
2025-04-08 7:19 ` [PULL 09/11] qapi/qapi-schema: Address the introduction's bit rot Markus Armbruster
2025-04-08 7:20 ` [PULL 10/11] storage-daemon/qapi/qapi-schema: Add a proper introduction Markus Armbruster
2025-04-08 7:20 ` [PULL 11/11] qga/qapi-schema: " Markus Armbruster
2025-04-08 7:45 ` [PULL 00/11] QAPI patches patches for 2025-04-08 Markus Armbruster
2025-04-09 8:31 ` Stefan Hajnoczi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).