[Qemu-devel] [PULL 11/21] qapi/block: Document restrictions for node names

Kevin Wolf posted 21 patches 6 years, 8 months ago
There is a newer version of this series
[Qemu-devel] [PULL 11/21] qapi/block: Document restrictions for node names
Posted by Kevin Wolf 6 years, 8 months ago
blockdev-add fails if an invalid node name is given, so we should
document what a valid node name even is.

Reported-by: Cong Li <coli@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Cong Li <coli@redhat.com>
Reviewed-by: Alberto Garcia <berto@igalia.com>
---
 qapi/block-core.json | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/qapi/block-core.json b/qapi/block-core.json
index 5b9084a394..f20efc97f7 100644
--- a/qapi/block-core.json
+++ b/qapi/block-core.json
@@ -3572,6 +3572,9 @@
 # @driver:        block driver name
 # @node-name:     the node name of the new node (Since 2.0).
 #                 This option is required on the top level of blockdev-add.
+#                 Valid node names start with an alphabetic character and may
+#                 contain only alphanumeric characters, '-', '.' and '_'. Their
+#                 maximum length is 31 characters.
 # @discard:       discard-related options (default: ignore)
 # @cache:         cache-related options
 # @read-only:     whether the block device should be read-only (default: false).
-- 
2.13.6