Skip to contentSkip to conversation

docs/interop: convert text files to restructuredText

PATCH Superseded [email protected] 2 participants 3 messages May 15, 2025 – May 16, 2025

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 docs/interop: convert text files to restructuredText

From: Souleymane Conte <[email protected]>

---
 docs/interop/index.rst                |   1 +
 docs/interop/{qcow2.txt => qcow2.rst} | 210 +++++++++++++++-----------
 2 files changed, 123 insertions(+), 88 deletions(-)
 rename docs/interop/{qcow2.txt => qcow2.rst} (89%)
docs/interop/index.rst +1 -0
index 999e44eae1..bfe3cf0beb 100644
@@ -23,6 +23,7 @@ are useful for making QEMU interoperate with other software.
    qemu-ga-ref
    qemu-qmp-ref
    qemu-storage-daemon-qmp-ref
+   qcow2
    vhost-user
    vhost-user-gpu
    vhost-vdpa
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +122 -88

512 lines not on this page · raw message

Signature · 1 line
2.49.0
#1 lore raw
Quoted 11 lines · On Thu, May 15, 2025 at 10:24:00AM +0000, [email protected] wrote:

From: Souleymane Conte <[email protected]>

---
 docs/interop/index.rst                |   1 +
 docs/interop/{qcow2.txt => qcow2.rst} | 210 +++++++++++++++-----------
 2 files changed, 123 insertions(+), 88 deletions(-)
 rename docs/interop/{qcow2.txt => qcow2.rst} (89%)

As long as we're touching this file,...

docs/interop/qcow2.rst the respective feature (e.g. because the feature was introduced only later) to · line 303

Quoted 11 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +3 -1
+Feature name table
+------------------
 
 The feature name table is an optional header extension that contains the name
 for features used by the image. It can be used by applications that don't know
@@ -288,7 +300,7 @@ the respective feature (e.g. because the feature was introduced only later) to
 display a useful error message.
 
 The number of entries in the feature name table is determined by the length of
-the header extension data. Each entry look like this:
+the header extension data. Each entry look like this::

s/look/looks/

Quoted 26 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +8 -7
@@ -377,35 +392,40 @@ Logically the layout looks like
 
   +-----------------------------+
   | QCow2 header                |
+  +-----------------------------+
   | QCow2 header extension X    |
+  +-----------------------------+
   | QCow2 header extension FDE  |
+  +-----------------------------+
   | QCow2 header extension ...  |
+  +-----------------------------+
   | QCow2 header extension Z    |
   +-----------------------------+
+  | ...                         |
+  +-----------------------------+
+  | ...                         |
+  +-----------------------------+
   | ....other QCow2 tables....  |
-  .                             .
-  .                             .
   +-----------------------------+
-  | +-------------------------+ |
-  | | LUKS partition header   | |
-  | +-------------------------+ |
-  | | LUKS key material 1     | |
-  | +-------------------------+ |

docs/interop/qcow2.rst Logically the layout looks like · line 413

Quoted 10 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +4 -6
-  | | LUKS key material 2     | |
-  | +-------------------------+ |
-  | | LUKS key material ...   | |
-  | +-------------------------+ |
-  | | LUKS key material 8     | |
-  | +-------------------------+ |
+  | LUKS partition header       |
+  +-----------------------------+
+  | LUKS key material 1         |
+  +-----------------------------+

Is there no way to nest a table in .rst?

Quoted 6 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +2 -0
+Host cluster management
+-----------------------
 
 qcow2 manages the allocation of host clusters by maintaining a reference count
 for each host cluster. A refcount of 0 means that the cluster is free, 1 means

docs/interop/qcow2.rst Although a large enough refcount table can reserve clusters past 64 PB · line 478

Quoted 10 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +2 -5
@@ -453,14 +474,15 @@ Although a large enough refcount table can reserve clusters past 64 PB
 large), note that some qcow2 metadata such as L1/L2 tables must point
 to clusters prior to that point.
 
-Note: qemu has an implementation limit of 8 MB as the maximum refcount
-table size.  With a 2 MB cluster size and a default refcount_order of
-4, it is unable to reference host resources beyond 2 EB (61 bits); in
-the worst case, with a 512 cluster size and refcount_order of 6, it is
-unable to access beyond 32 GB (35 bits).
+.. note::
+    qemu has an implementation limit of 8 MB as the maximum refcount

Should we be changing s/qemu/QEMU/ while editing this file?

Signature · 3 lines
Eric Blake, Principal Software Engineer
Red Hat, Inc.
Virtualization:  qemu.org | libguestfs.org
#2 lore raw

Hi,
Thanks a lot for your review and helpful suggestions.

I will address the following points in v2:
- Fix the typo: "Each entry look" → "Each entry looks"
- Improve the layout for the LUKS section in the visual diagram
- Check whether nested tables are possible in reStructuredText
- Update "qemu" to "QEMU" for consistency, where appropriate

I'll prepare and send a v2 shortly.

Souleymane Conte

Quoted 101 lines · Eric Blake
Quoted 11 lines · On Thu, May 15, 2025 at 10:24:00AM +0000, [email protected] wrote:

From: Souleymane Conte <[email protected]>

---
 docs/interop/index.rst                |   1 +
 docs/interop/{qcow2.txt => qcow2.rst} | 210 +++++++++++++++-----------
 2 files changed, 123 insertions(+), 88 deletions(-)
 rename docs/interop/{qcow2.txt => qcow2.rst} (89%)

As long as we're touching this file,...

Quoted 4 lines

+Feature name table
+------------------

The feature name table is an optional header extension that contains

the name

Quoted 1 line

for features used by the image. It can be used by applications that

don't know

Review the respective feature (e.g. because the feature was

Quoted 1 line
(quoted diff) +0 -0
@@ -288,7 +300,7 @@ the respective feature (e.g. because the feature was

introduced only later) to

docs/interop/qcow2.rst the respective feature (e.g. because the feature was introduced only later) to

Quoted 3 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +0 -0
 display a useful error message.
 
 The number of entries in the feature name table is determined by the

length of

docs/interop/qcow2.rst the respective feature (e.g. because the feature was introduced only later) to · line 303

Quoted 2 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +1 -1
-the header extension data. Each entry look like this:
+the header extension data. Each entry look like this::

s/look/looks/

Quoted 26 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +8 -7
@@ -377,35 +392,40 @@ Logically the layout looks like
 
   +-----------------------------+
   | QCow2 header                |
+  +-----------------------------+
   | QCow2 header extension X    |
+  +-----------------------------+
   | QCow2 header extension FDE  |
+  +-----------------------------+
   | QCow2 header extension ...  |
+  +-----------------------------+
   | QCow2 header extension Z    |
   +-----------------------------+
+  | ...                         |
+  +-----------------------------+
+  | ...                         |
+  +-----------------------------+
   | ....other QCow2 tables....  |
-  .                             .
-  .                             .
   +-----------------------------+
-  | +-------------------------+ |
-  | | LUKS partition header   | |
-  | +-------------------------+ |
-  | | LUKS key material 1     | |
-  | +-------------------------+ |

docs/interop/qcow2.rst Logically the layout looks like · line 413

Quoted 10 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +4 -6
-  | | LUKS key material 2     | |
-  | +-------------------------+ |
-  | | LUKS key material ...   | |
-  | +-------------------------+ |
-  | | LUKS key material 8     | |
-  | +-------------------------+ |
+  | LUKS partition header       |
+  +-----------------------------+
+  | LUKS key material 1         |
+  +-----------------------------+

Is there no way to nest a table in .rst?

docs/interop/qcow2.rst The algorithms used for encryption vary depending on the method

Quoted 4 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +2 -0
+Host cluster management
+-----------------------
 
 qcow2 manages the allocation of host clusters by maintaining a

reference count

Review Logically the layout looks like · line 418

Quoted 1 line
(quoted diff) +0 -0
 for each host cluster. A refcount of 0 means that the cluster is free,

1 means

Review Although a large enough refcount table can reserve

Quoted 1 line
(quoted diff) +0 -0
@@ -453,14 +474,15 @@ Although a large enough refcount table can reserve

clusters past 64 PB

docs/interop/qcow2.rst Although a large enough refcount table can reserve clusters past 64 PB · line 478

Quoted 10 lines
docs/interop/qcow2.rst renamed from docs/interop/qcow2.txt +2 -5
 large), note that some qcow2 metadata such as L1/L2 tables must point
 to clusters prior to that point.
 
-Note: qemu has an implementation limit of 8 MB as the maximum refcount
-table size.  With a 2 MB cluster size and a default refcount_order of
-4, it is unable to reference host resources beyond 2 EB (61 bits); in
-the worst case, with a 512 cluster size and refcount_order of 6, it is
-unable to access beyond 32 GB (35 bits).
+.. note::
+    qemu has an implementation limit of 8 MB as the maximum refcount

Should we be changing s/qemu/QEMU/ while editing this file?

--
Eric Blake, Principal Software Engineer
Red Hat, Inc.
Virtualization: qemu.org | libguestfs.org