From patchwork Fri Sep 25 14:03:34 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Marc-Andr=C3=A9_Lureau?= X-Patchwork-Id: 522815 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 5AF0214090A for ; Sat, 26 Sep 2015 00:07:27 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=DbFwz5Zb; dkim-atps=neutral Received: from localhost ([::1]:41971 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZfTem-0003Cs-Tp for incoming@patchwork.ozlabs.org; Fri, 25 Sep 2015 10:07:24 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41499) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZfTbl-0006Hf-70 for qemu-devel@nongnu.org; Fri, 25 Sep 2015 10:04:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZfTbj-0003Kh-Td for qemu-devel@nongnu.org; Fri, 25 Sep 2015 10:04:17 -0400 Received: from mail-wi0-x229.google.com ([2a00:1450:400c:c05::229]:36144) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZfTbj-0003K4-D0 for qemu-devel@nongnu.org; Fri, 25 Sep 2015 10:04:15 -0400 Received: by wicgb1 with SMTP id gb1so22041729wic.1 for ; Fri, 25 Sep 2015 07:04:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; bh=AkeRDNTqtGnORy9e6VsYXIr73iJ6yFI7g16+yo/F2zo=; b=DbFwz5ZbcHdJX+hPTvTyjkrE8q5Z3aBs3YIfMfK3Djbw/LHSsNzLryA1PBh/oH0nPA gR/8DrKuPFHLzxG8UnATS+qcCEUKkNktQSC0iMl3KQMLTE29i9c9j7lbVbS0qx7JQDb3 vSklttgAPpq0Uoavf/jdIbVWuW6m02XAlAvKhPiTEWWu04DreAmYRwOvRThYqZ5YNmA5 Dfe96AvDNcLRRKQAy8L3uXdzMGLV+3XDXBsywRLi8KiGQj/y4dVMi2raAV22lp7tGoST Xi1MiRP6KkiPETIOOMPTYSpxIPTEl3mGWcYgqwqHpjVQLp0gYcNEyxiqL1hc3eNuVhCR NnBA== X-Received: by 10.194.93.229 with SMTP id cx5mr6374323wjb.62.1443189854763; Fri, 25 Sep 2015 07:04:14 -0700 (PDT) Received: from localhost ([149.6.167.210]) by smtp.gmail.com with ESMTPSA id r4sm3401841wia.19.2015.09.25.07.04.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 25 Sep 2015 07:04:13 -0700 (PDT) From: marcandre.lureau@redhat.com To: qemu-devel@nongnu.org Date: Fri, 25 Sep 2015 16:03:34 +0200 Message-Id: <1443189844-20341-7-git-send-email-marcandre.lureau@redhat.com> X-Mailer: git-send-email 2.4.3 In-Reply-To: <1443189844-20341-1-git-send-email-marcandre.lureau@redhat.com> References: <1443189844-20341-1-git-send-email-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c05::229 Cc: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , armbru@redhat.com, mdroth@linux.vnet.ibm.com Subject: [Qemu-devel] [PATCH 06/36] qapi: move documentation bits in schema files X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Marc-André Lureau Moving the remaining bits of documentation to the schema files. Signed-off-by: Marc-André Lureau --- qapi-schema.json | 48 ++++++++++++++++++++++++++++++++++++++++++- qmp-commands.hx | 62 -------------------------------------------------------- 2 files changed, 47 insertions(+), 63 deletions(-) diff --git a/qapi-schema.json b/qapi-schema.json index 1383011..c8ee75d 100644 --- a/qapi-schema.json +++ b/qapi-schema.json @@ -1,6 +1,52 @@ # -*- Mode: Python -*- +## +# = Introduction +# +# This document describes all commands currently supported by QMP. +# +# 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: +# +# | -> data issued by the Client +# | <- Server data response +# +# Please, refer to the QMP specification (QMP/qmp-spec.txt) for detailed +# information on the Server command and response formats. +# +# = Stability Considerations +# +# The current QMP command set (described in this file) may be useful for a +# number of use cases, however it's limited and several commands have bad +# defined semantics, specially with regard to command completion. +# +# These problems are going to be solved incrementally in the next QEMU releases +# and we're going to establish a deprecation policy for badly defined commands. +# +# If you're planning to adopt QMP, please observe the following: +# +# 1. The deprecation policy will take effect and be documented soon, please +# check the documentation of each used command as soon as a new release of +# QEMU is available +# +# 2. DO NOT rely on anything which is not explicit documented +# +# 3. Errors, in special, are not documented. Applications should NOT check +# for specific errors classes or data (it's strongly recommended to only +# check for the "error" key) # -# QAPI Schema # QAPI common definitions { 'include': 'qapi/common.json' } diff --git a/qmp-commands.hx b/qmp-commands.hx index c09918b..3a7af18 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1,65 +1,3 @@ -HXCOMM QMP dispatch table and documentation -HXCOMM Text between SQMP and EQMP is copied to the QMP documentation file and -HXCOMM does not show up in the other formats. - -SQMP - QMP Supported Commands - ---------------------- - -This document describes all commands currently supported by QMP. - -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: - --> data issued by the Client -<- Server data response - -Please, refer to the QMP specification (QMP/qmp-spec.txt) for detailed -information on the Server command and response formats. - -NOTE: This document is temporary and will be replaced soon. - -1. Stability Considerations -=========================== - -The current QMP command set (described in this file) may be useful for a -number of use cases, however it's limited and several commands have bad -defined semantics, specially with regard to command completion. - -These problems are going to be solved incrementally in the next QEMU releases -and we're going to establish a deprecation policy for badly defined commands. - -If you're planning to adopt QMP, please observe the following: - - 1. The deprecation policy will take effect and be documented soon, please - check the documentation of each used command as soon as a new release of - QEMU is available - - 2. DO NOT rely on anything which is not explicit documented - - 3. Errors, in special, are not documented. Applications should NOT check - for specific errors classes or data (it's strongly recommended to only - check for the "error" key) - -2. Regular Commands -=================== - -Server's responses in the examples below are always a success response, please -refer to the QMP specification for more details on error responses. - -EQMP - { .name = "quit", .args_type = "",