From patchwork Tue Sep 19 20:18:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391858 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1C6C1CE79A8 for ; Tue, 19 Sep 2023 20:20:58 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihBt-0001to-A0; Tue, 19 Sep 2023 16:19:25 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBa-0001qp-ML for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:07 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBY-0003XV-P0 for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:06 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154743; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=pHFy0oxUzieh3NO9yEI2Hz0dkRIA9PZWwL9q7Yb9osk=; b=HdNzaa3DOHAjLn0rWaCuazeSJxvtEfGFrpoqhaQItYjYIWcLYj/jCbXaW87EvrZI+uEAa9 IDhrpc9CdQGkkfpaQsBx5g5EbNLqCKpIhOveNmNOnKax5FT9f+7dzs2g81GalcS60Jx4JQ e8ImYyExwNO895a6uw0Oq/kDiD0+9eQ= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-459-sInKGEROPkmv6foS4DIP4g-1; Tue, 19 Sep 2023 16:19:02 -0400 X-MC-Unique: sInKGEROPkmv6foS4DIP4g-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id AE80829ABA1F for ; Tue, 19 Sep 2023 20:19:01 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id 70340140273C; Tue, 19 Sep 2023 20:19:00 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 01/10] qapi: fix example of get-win32-socket command Date: Tue, 19 Sep 2023 22:18:48 +0200 Message-ID: <20230919201857.675913-2-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.129.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: 12 X-Spam_score: 1.2 X-Spam_bar: + X-Spam_report: (1.2 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_SBL_CSS=3.335, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Example output lacks double quotes. Fix it. Fixes: 4cda177c60 "qmp: add 'get-win32-socket'" Signed-off-by: Victor Toso Reviewed-by: Daniel P. Berrangé Reviewed-by: Markus Armbruster --- qapi/misc.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qapi/misc.json b/qapi/misc.json index cda2effa81..be302cadeb 100644 --- a/qapi/misc.json +++ b/qapi/misc.json @@ -290,7 +290,7 @@ # # Example: # -# -> { "execute": "get-win32-socket", "arguments": { "info": "abcd123..", fdname": "skclient" } } +# -> { "execute": "get-win32-socket", "arguments": { "info": "abcd123..", "fdname": "skclient" } } # <- { "return": {} } ## { 'command': 'get-win32-socket', 'data': {'info': 'str', 'fdname': 'str'}, 'if': 'CONFIG_WIN32' } From patchwork Tue Sep 19 20:18:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391862 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 2426ACE79A8 for ; Tue, 19 Sep 2023 20:21:22 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihBr-0001tE-39; Tue, 19 Sep 2023 16:19:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBb-0001qq-8v for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:07 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBZ-0003Xt-Qu for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:06 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154745; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=6DJjUWRPoscKvLU6xKxvS0hJES9aOe+52PbutmdMvaA=; b=V96ivl9HEXGprq3ojgfBTjc0PnJe3QUaEGxJ/EX/8+wpvhw8LSJcFiScPrm3yoD/mYgzjf B5rCC2hQnL+oYCoH34oIJKUUFz4fGBxlA/jvAP3EipvTKTqbU3f8O9whUBNMdBC3wKqbvB wMlhv7SfXOsrgRDx9aa4BwmC5LURvYw= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-561-dw61t5VFNkSj3YEenDO0kw-1; Tue, 19 Sep 2023 16:19:03 -0400 X-MC-Unique: dw61t5VFNkSj3YEenDO0kw-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 56C4A811E94 for ; Tue, 19 Sep 2023 20:19:03 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id 16EA8140273C; Tue, 19 Sep 2023 20:19:01 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 02/10] qapi: fix example of dumpdtb command Date: Tue, 19 Sep 2023 22:18:49 +0200 Message-ID: <20230919201857.675913-3-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.129.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Example output has extra end curly bracket. Switch with comma. Signed-off-by: Victor Toso Reviewed-by: Daniel P. Berrangé Reviewed-by: Markus Armbruster --- qapi/machine.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qapi/machine.json b/qapi/machine.json index a08b6576ca..9eb76193e0 100644 --- a/qapi/machine.json +++ b/qapi/machine.json @@ -1684,7 +1684,7 @@ # # Example: # -# -> { "execute": "dumpdtb" } +# -> { "execute": "dumpdtb", # "arguments": { "filename": "fdt.dtb" } } # <- { "return": {} } ## From patchwork Tue Sep 19 20:18:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391861 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7E3DDCE79A9 for ; Tue, 19 Sep 2023 20:21:13 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihBr-0001tZ-7N; Tue, 19 Sep 2023 16:19:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBd-0001qz-3f for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:09 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBb-0003Zb-F7 for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154746; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=FvjvtyZKi1vX8xXmUbmUkvWFi+XjJNE+lvxSJtmCyyo=; b=VF9A1Z+OK8+R71xG/usJA6Edhr9WAJmCW2mFuPInp7gl1zA2STMfDEyHTY97SUJGWOxAHx X64vdvKVGKDZpnjH591s2IyT4SucImwInpaEHANJrvLdeLbTGbiKvTC8zWbZoWwFXC/rlU pjawlRUQ46f8N4r3fY8GsIPdO23HUrM= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-641-MSacCTI0NAyCpa93HUthsw-1; Tue, 19 Sep 2023 16:19:05 -0400 X-MC-Unique: MSacCTI0NAyCpa93HUthsw-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id F34E13C11A07 for ; Tue, 19 Sep 2023 20:19:04 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id B3981140E950; Tue, 19 Sep 2023 20:19:03 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 03/10] qapi: fix example of cancel-vcpu-dirty-limit command Date: Tue, 19 Sep 2023 22:18:50 +0200 Message-ID: <20230919201857.675913-4-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.129.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: 12 X-Spam_score: 1.2 X-Spam_bar: + X-Spam_report: (1.2 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_SBL_CSS=3.335, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Example output has extra end curly bracket. Remove it. Signed-off-by: Victor Toso Reviewed-by: Daniel P. Berrangé Reviewed-by: Markus Armbruster --- qapi/migration.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qapi/migration.json b/qapi/migration.json index 8843e74b59..9385b9f87c 100644 --- a/qapi/migration.json +++ b/qapi/migration.json @@ -2010,7 +2010,7 @@ # # Example: # -# -> {"execute": "cancel-vcpu-dirty-limit"}, +# -> {"execute": "cancel-vcpu-dirty-limit", # "arguments": { "cpu-index": 1 } } # <- { "return": {} } ## From patchwork Tue Sep 19 20:18:51 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391855 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 8217ACE79A9 for ; Tue, 19 Sep 2023 20:20:22 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihBk-0001ru-UP; Tue, 19 Sep 2023 16:19:17 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBf-0001rV-DR for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:12 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBd-0003Zx-UI for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:11 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154749; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=1k61A6RGWpHYDXeTJtZfhXqITHXpgcKROZh5RDG7nbY=; b=ZKz4KVpsEA/UTaQ3FrNG2Bv3jGnrNlN3h6KPraxAqjC0DO0d/NTIJPNul/EUy2Vsd5cMm0 QizQcZdw/pLqedZ7CDlIAVUJeLnwBibLhZcNfuGzH3DLZxXBINGjtJgaX59ZJdth2dMo+d LtQCBpoV4BU+4CcJtd+XgCDUFOA1Wso= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-422-1ek4nd6hPp27L2lJds6pGg-1; Tue, 19 Sep 2023 16:19:07 -0400 X-MC-Unique: 1ek4nd6hPp27L2lJds6pGg-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id BF33A3812588 for ; Tue, 19 Sep 2023 20:19:06 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id 5C78C140E950; Tue, 19 Sep 2023 20:19:05 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 04/10] qapi: fix example of set-vcpu-dirty-limit command Date: Tue, 19 Sep 2023 22:18:51 +0200 Message-ID: <20230919201857.675913-5-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.133.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: 12 X-Spam_score: 1.2 X-Spam_bar: + X-Spam_report: (1.2 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_SBL_CSS=3.335, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Example output has extra end curly bracket. Remove it. Signed-off-by: Victor Toso Reviewed-by: Daniel P. Berrangé Reviewed-by: Markus Armbruster --- qapi/migration.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qapi/migration.json b/qapi/migration.json index 9385b9f87c..2658cdbcbe 100644 --- a/qapi/migration.json +++ b/qapi/migration.json @@ -1986,7 +1986,7 @@ # # Example: # -# -> {"execute": "set-vcpu-dirty-limit"} +# -> {"execute": "set-vcpu-dirty-limit", # "arguments": { "dirty-rate": 200, # "cpu-index": 1 } } # <- { "return": {} } From patchwork Tue Sep 19 20:18:52 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391863 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 92233CE79A9 for ; Tue, 19 Sep 2023 20:21:22 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihBu-0001uN-AQ; Tue, 19 Sep 2023 16:19:26 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBh-0001rm-MX for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:14 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBg-0003aI-CI for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:13 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154751; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Y1t4tCysOIsjj1EFb5D9HFvh5h51eWAK8Fcaf+59+wM=; b=FIKQHHvNR3JtqQL8XiZOIAJFeb328N700ETQsE2fLZEl2kqHDn4Ek2XK6CsQo1rPGyElsw Qqm1NKGMVLICqxQPsPgaStuFzf5FKXaVkAWjTp2lRTL9csC34kkw7cNZ1+EzFpGbLG39pZ uOghF76F4XaXm+tIgJJtktcsAmcSQUY= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-673-jaGwmaNROAaMbjOftJkEsQ-1; Tue, 19 Sep 2023 16:19:10 -0400 X-MC-Unique: jaGwmaNROAaMbjOftJkEsQ-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id CBE361C01720 for ; Tue, 19 Sep 2023 20:19:09 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id 52C99140E950; Tue, 19 Sep 2023 20:19:07 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 05/10] qapi: fix example of calc-dirty-rate command Date: Tue, 19 Sep 2023 22:18:52 +0200 Message-ID: <20230919201857.675913-6-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.129.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: 12 X-Spam_score: 1.2 X-Spam_bar: + X-Spam_report: (1.2 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_SBL_CSS=3.335, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Example output has property name with single quotes. Fix it. Signed-off-by: Victor Toso Reviewed-by: Daniel P. Berrangé Reviewed-by: Markus Armbruster --- qapi/migration.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qapi/migration.json b/qapi/migration.json index 2658cdbcbe..45dac41f67 100644 --- a/qapi/migration.json +++ b/qapi/migration.json @@ -1922,7 +1922,7 @@ # Example: # # -> {"execute": "calc-dirty-rate", "arguments": {"calc-time": 1, -# 'sample-pages': 512} } +# "sample-pages": 512} } # <- { "return": {} } ## { 'command': 'calc-dirty-rate', 'data': {'calc-time': 'int64', From patchwork Tue Sep 19 20:18:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391864 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 289A7CE79AA for ; Tue, 19 Sep 2023 20:21:24 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihBv-0001uh-Vv; Tue, 19 Sep 2023 16:19:28 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBj-0001rv-Hq for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:16 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBi-0003aT-6S for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154753; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=NNFyZN88nrgtZzZcG0YQR6CAWMg+fRmP3W5q8h6ZJFE=; b=AQNYMxHVqzF7POa9zGy/Qh32EgENYDod1EIDCV5BIgkN5kRd38rBFUZeyKo/vtjrXnKVQs gXH24PJJN0sjL60ZOugyCE6dRtXCmvcSjlqcMnhHKhx8ED8L9mBtQRliFLrkQOlJWjZac9 lmrkde3oLcVPTkLT7PkvTFc1MPWzsWY= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-60-oT-M4v83PxeHQVFhW6fcxQ-1; Tue, 19 Sep 2023 16:19:11 -0400 X-MC-Unique: oT-M4v83PxeHQVFhW6fcxQ-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 88544811E7B for ; Tue, 19 Sep 2023 20:19:11 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id 47D87140E950; Tue, 19 Sep 2023 20:19:10 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 06/10] qapi: fix example of NETDEV_STREAM_CONNECTED event Date: Tue, 19 Sep 2023 22:18:53 +0200 Message-ID: <20230919201857.675913-7-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.133.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Example output was using single quotes. Fix it. Signed-off-by: Victor Toso Reviewed-by: Daniel P. Berrangé Reviewed-by: Markus Armbruster --- qapi/net.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/qapi/net.json b/qapi/net.json index 313c8a606e..81988e499a 100644 --- a/qapi/net.json +++ b/qapi/net.json @@ -930,9 +930,9 @@ # # Example: # -# <- { 'event': 'NETDEV_STREAM_DISCONNECTED', -# 'data': {'netdev-id': 'netdev0'}, -# 'timestamp': {'seconds': 1663330937, 'microseconds': 526695} } +# <- { "event": "NETDEV_STREAM_DISCONNECTED", +# "data": {"netdev-id": "netdev0"}, +# "timestamp": {"seconds": 1663330937, "microseconds": 526695} } ## { 'event': 'NETDEV_STREAM_DISCONNECTED', 'data': { 'netdev-id': 'str' } } From patchwork Tue Sep 19 20:18:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391860 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EB7A9CE79A8 for ; Tue, 19 Sep 2023 20:21:03 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihBw-0001vE-G7; Tue, 19 Sep 2023 16:19:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBm-0001sF-Co for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:18 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBk-0003ai-T5 for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:18 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154756; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=DaIv7QYIs85wZyypYVvtp41wiFN3jTuNPRr7lspyX94=; b=WHkphPcBu+Xy3hx9EljwEheEXWfP3bKdML9ftd1E40YaHp6fNNBNvinJbtOklI5uQ/RKEV j97KSgig7UJvCkYxTnB2S5OojFWiTnmKLpmrDajNONAbVdSAs37IPsVmSmMeuoXTY0Uvra sztLEbsLOmYd6t5pvDhUdbw4qsFhwq8= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-79-4vwys81GPVq-i4JJiR8Ndg-1; Tue, 19 Sep 2023 16:19:13 -0400 X-MC-Unique: 4vwys81GPVq-i4JJiR8Ndg-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 462F93812589 for ; Tue, 19 Sep 2023 20:19:13 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id 0709F140E950; Tue, 19 Sep 2023 20:19:11 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 07/10] qapi: fix example of query-blockstats command Date: Tue, 19 Sep 2023 22:18:54 +0200 Message-ID: <20230919201857.675913-8-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.129.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: 12 X-Spam_score: 1.2 X-Spam_bar: + X-Spam_report: (1.2 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_SBL_CSS=3.335, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Example output has several missing commas. Add them. Signed-off-by: Victor Toso Reviewed-by: Daniel P. Berrangé Reviewed-by: Markus Armbruster --- qapi/block-core.json | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/qapi/block-core.json b/qapi/block-core.json index 2b1d493d6e..6a81103594 100644 --- a/qapi/block-core.json +++ b/qapi/block-core.json @@ -1167,10 +1167,10 @@ # "wr_bytes":9786368, # "wr_operations":751, # "rd_bytes":122567168, -# "rd_operations":36772 -# "wr_total_times_ns":313253456 -# "rd_total_times_ns":3465673657 -# "flush_total_times_ns":49653 +# "rd_operations":36772, +# "wr_total_times_ns":313253456, +# "rd_total_times_ns":3465673657, +# "flush_total_times_ns":49653, # "flush_operations":61, # "rd_merged":0, # "wr_merged":0, @@ -1184,10 +1184,10 @@ # "wr_bytes":9786368, # "wr_operations":692, # "rd_bytes":122739200, -# "rd_operations":36604 +# "rd_operations":36604, # "flush_operations":51, -# "wr_total_times_ns":313253456 -# "rd_total_times_ns":3465673657 +# "wr_total_times_ns":313253456, +# "rd_total_times_ns":3465673657, # "flush_total_times_ns":49653, # "rd_merged":0, # "wr_merged":0, @@ -1204,10 +1204,10 @@ # "wr_bytes":0, # "wr_operations":0, # "rd_bytes":0, -# "rd_operations":0 +# "rd_operations":0, # "flush_operations":0, -# "wr_total_times_ns":0 -# "rd_total_times_ns":0 +# "wr_total_times_ns":0, +# "rd_total_times_ns":0, # "flush_total_times_ns":0, # "rd_merged":0, # "wr_merged":0, @@ -1223,10 +1223,10 @@ # "wr_bytes":0, # "wr_operations":0, # "rd_bytes":0, -# "rd_operations":0 +# "rd_operations":0, # "flush_operations":0, -# "wr_total_times_ns":0 -# "rd_total_times_ns":0 +# "wr_total_times_ns":0, +# "rd_total_times_ns":0, # "flush_total_times_ns":0, # "rd_merged":0, # "wr_merged":0, @@ -1242,10 +1242,10 @@ # "wr_bytes":0, # "wr_operations":0, # "rd_bytes":0, -# "rd_operations":0 +# "rd_operations":0, # "flush_operations":0, -# "wr_total_times_ns":0 -# "rd_total_times_ns":0 +# "wr_total_times_ns":0, +# "rd_total_times_ns":0, # "flush_total_times_ns":0, # "rd_merged":0, # "wr_merged":0, From patchwork Tue Sep 19 20:18:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391859 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CD44FCE79A9 for ; Tue, 19 Sep 2023 20:21:03 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihBr-0001tm-KV; Tue, 19 Sep 2023 16:19:24 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBn-0001sb-H0 for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:20 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBl-0003ao-9k for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:19 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154756; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=vFhItgYwiKRgBjlBV2lz1k/iU5E7C7917I3dI+Rz35U=; b=VwxS2NgkOyhm0G7joVJ7MbSRHnfGQ9uU38wLXcDSaXgiqQLPk6Kl5D/VoaoF2iSD/AydJu 6B+Z0eYEGZpzNhuiBsbc33z8njwg8nMlv0HjKGX08EmoPWKrbKPcSgskeARGxY+n1OkZ8P Y4LjTMoSSJxkXYooknkhgWlR1zHlQkI= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-614-FfjhjUOUO92h7apT8oG5Gg-1; Tue, 19 Sep 2023 16:19:15 -0400 X-MC-Unique: FfjhjUOUO92h7apT8oG5Gg-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id D5E73185A78E for ; Tue, 19 Sep 2023 20:19:14 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id A35A8140E950; Tue, 19 Sep 2023 20:19:13 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 08/10] qapi: fix example of query-rocker-of-dpa-flows command Date: Tue, 19 Sep 2023 22:18:55 +0200 Message-ID: <20230919201857.675913-9-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.133.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Example output has a comment embedded in the array. Remove it. The end result is a list of size 1. Signed-off-by: Victor Toso Reviewed-by: Daniel P. Berrangé --- qapi/rocker.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/qapi/rocker.json b/qapi/rocker.json index 31ce0b36f6..858e4f4a45 100644 --- a/qapi/rocker.json +++ b/qapi/rocker.json @@ -249,8 +249,7 @@ # "cookie": 0, # "action": {"goto-tbl": 10}, # "mask": {"in-pport": 4294901760} -# }, -# {...more...}, +# } # ]} ## { 'command': 'query-rocker-of-dpa-flows', From patchwork Tue Sep 19 20:18:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391857 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 8D362CE79A9 for ; Tue, 19 Sep 2023 20:20:57 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihC3-0001wL-Cn; Tue, 19 Sep 2023 16:19:35 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBo-0001sc-9x for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:20 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBm-0003b4-TU for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154758; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Y89pdSKeZgpbFhOLDYjIYVSS2ugFvteeVmqAfZgcOfg=; b=dv7WDNDIqKchJZsrJZFBpU3vsbV3R1dcbTnA4XjDRD5CqQuofP+qcVlYT3o3afVkr9WYKv R4eSAmW5jk8WVSScMBGsCf00CUXutfb64tFH87QuOfja6e8Cz5GJWUCOBHtNTOIfmkSFLJ 0ONM77fJ2SmsmQ3H3kTxPmmUFOb/ogo= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-628-Dg51QzmfMoqV09guqffXXA-1; Tue, 19 Sep 2023 16:19:16 -0400 X-MC-Unique: Dg51QzmfMoqV09guqffXXA-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 58141185A78E for ; Tue, 19 Sep 2023 20:19:16 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id 39EFB140E950; Tue, 19 Sep 2023 20:19:15 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 09/10] qapi: fix example of query-spice command Date: Tue, 19 Sep 2023 22:18:56 +0200 Message-ID: <20230919201857.675913-10-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.133.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Example output has a comment embedded in the array. Remove it. The end result is a list of size 2. Signed-off-by: Victor Toso Reviewed-by: Daniel P. Berrangé --- qapi/ui.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/qapi/ui.json b/qapi/ui.json index 006616aa77..6ed36c45ea 100644 --- a/qapi/ui.json +++ b/qapi/ui.json @@ -363,8 +363,7 @@ # "host": "127.0.0.1", # "channel-id": 0, # "tls": false -# }, -# [ ... more channels follow ... ] +# } # ] # } # } From patchwork Tue Sep 19 20:18:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Victor Toso X-Patchwork-Id: 13391865 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7D4A8CE79A9 for ; Tue, 19 Sep 2023 20:21:25 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qihC3-0001wQ-Kh; Tue, 19 Sep 2023 16:19:35 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBs-0001tp-Mi for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:25 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qihBq-0003bP-66 for qemu-devel@nongnu.org; Tue, 19 Sep 2023 16:19:24 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1695154760; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=A9KaqBORTWChrzTyjpRiAxjEpmDPGczw0cItk9Az6oM=; b=gnpGj/PG/zUfBRhuFd5TfpCuJH3VIXp31SHpdHkOoiA+1EJN5zRfHLB62NIdgmAZDamfM6 yWKhPQmLYe8C0dYBM41qW/7SpsjFb/bCbWNqZd5aw79hrwWgPQs2cb5wWl5tZNl+2O6Ktw 8kNShjgHRj2MMflGY30/JnyEwInGPAE= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-644-lmizNo1zPB6Z6oJi1OFEXA-1; Tue, 19 Sep 2023 16:19:19 -0400 X-MC-Unique: lmizNo1zPB6Z6oJi1OFEXA-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id DD6EF8039C8 for ; Tue, 19 Sep 2023 20:19:18 +0000 (UTC) Received: from tapioca.lan (unknown [10.45.224.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id B340C140E950; Tue, 19 Sep 2023 20:19:16 +0000 (UTC) From: Victor Toso To: qemu-devel@nongnu.org Cc: Markus Armbruster , John Snow , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= Subject: [PATCH v3 10/10] qapi: scripts: add a generator for qapi's examples Date: Tue, 19 Sep 2023 22:18:57 +0200 Message-ID: <20230919201857.675913-11-victortoso@redhat.com> In-Reply-To: <20230919201857.675913-1-victortoso@redhat.com> References: <20230919201857.675913-1-victortoso@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 Received-SPF: pass client-ip=170.10.133.124; envelope-from=victortoso@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org This generator has two goals: 1. Mechanical validation of QAPI examples 2. Generate the examples in a JSON format to be consumed for extra validation. The generator iterates over every Example section, parsing both server and client messages. The generator prints any inconsistency found, for example: | Error: Extra data: line 1 column 39 (char 38) | Location: cancel-vcpu-dirty-limit at qapi/migration.json:2017 | Data: {"execute": "cancel-vcpu-dirty-limit"}, | "arguments": { "cpu-index": 1 } } The generator will output other JSON file with all the examples in the QAPI module that they came from. This can be used to validate the introspection between QAPI/QMP to language bindings, for example: | { "examples": [ | { | "id": "ksuxwzfayw", | "client": [ | { | "sequence-order": 1 | "message-type": "command", | "message": | { "arguments": | { "device": "scratch", "size": 1073741824 }, | "execute": "block_resize" | }, | } ], | "server": [ | { | "sequence-order": 2 | "message-type": "return", | "message": { "return": {} }, | } ] | } | ] } Note that the order matters, as read by the Example section and translated into "sequence-order". A language binding project can then consume this files to Marshal and Unmarshal, comparing if the results are what is to be expected. RFC discussion: https://lists.gnu.org/archive/html/qemu-devel/2022-08/msg04641.html Signed-off-by: Victor Toso --- scripts/qapi/dumpexamples.py | 208 +++++++++++++++++++++++++++++++++++ scripts/qapi/main.py | 3 +- 2 files changed, 210 insertions(+), 1 deletion(-) create mode 100644 scripts/qapi/dumpexamples.py diff --git a/scripts/qapi/dumpexamples.py b/scripts/qapi/dumpexamples.py new file mode 100644 index 0000000000..55d9f13ab7 --- /dev/null +++ b/scripts/qapi/dumpexamples.py @@ -0,0 +1,208 @@ +""" +Dump examples for Developers +""" +# Copyright (c) 2023 Red Hat Inc. +# +# Authors: +# Victor Toso +# +# This work is licensed under the terms of the GNU GPL, version 2. +# See the COPYING file in the top-level directory. + +# Just for type hint on self +from __future__ import annotations + +import os +import json +import random +import string + +from typing import Dict, List, Optional + +from .schema import ( + QAPISchema, + QAPISchemaType, + QAPISchemaVisitor, + QAPISchemaEnumMember, + QAPISchemaFeature, + QAPISchemaIfCond, + QAPISchemaObjectType, + QAPISchemaObjectTypeMember, + QAPISchemaVariants, +) +from .source import QAPISourceInfo + + +def gen_examples(schema: QAPISchema, + output_dir: str, + prefix: str) -> None: + vis = QAPISchemaGenExamplesVisitor(prefix) + schema.visit(vis) + vis.write(output_dir) + + +def get_id(random, size: int) -> str: + letters = string.ascii_lowercase + return ''.join(random.choice(letters) for i in range(size)) + + +def next_object(text, start, end, context) -> (Dict, bool): + # Start of json object + start = text.find("{", start) + end = text.rfind("}", start, end+1) + + # try catch, pretty print issues + try: + ret = json.loads(text[start:end+1]) + except Exception as e: + print("Error: {}\nLocation: {}\nData: {}\n".format( + str(e), context, text[start:end+1])) + return {}, True + else: + return ret, False + + +def parse_text_to_dicts(text: str, context: str) -> (List[Dict], bool): + examples, clients, servers = [], [], [] + failed = False + + count = 1 + c, s = text.find("->"), text.find("<-") + while c != -1 or s != -1: + if c == -1 or (s != -1 and s < c): + start, target = s, servers + else: + start, target = c, clients + + # Find the client and server, if any + if c != -1: + c = text.find("->", start + 1) + if s != -1: + s = text.find("<-", start + 1) + + # Find the limit of current's object. + # We first look for the next message, either client or server. If none + # is avaible, we set the end of the text as limit. + if c == -1 and s != -1: + end = s + elif c != -1 and s == -1: + end = c + elif c != -1 and s != -1: + end = (c < s) and c or s + else: + end = len(text) - 1 + + message, error = next_object(text, start, end, context) + if error: + failed = True + + if len(message) > 0: + message_type = "return" + if "execute" in message: + message_type = "command" + elif "event" in message: + message_type = "event" + + target.append({ + "sequence-order": count, + "message-type": message_type, + "message": message + }) + count += 1 + + examples.append({"client": clients, "server": servers}) + return examples, failed + + +def parse_examples_of(self: QAPISchemaGenExamplesVisitor, + name: str): + + assert(name in self.schema._entity_dict) + obj = self.schema._entity_dict[name] + + if not obj.info.pragma.doc_required: + return + + assert((obj.doc is not None)) + module_name = obj._module.name + + # We initialize random with the name so that we get consistent example + # ids over different generations. The ids of a given example might + # change when adding/removing examples, but that's acceptable as the + # goal is just to grep $id to find what example failed at a given test + # with minimum chorn over regenerating. + random.seed(name, version=2) + + for s in obj.doc.sections: + if s.name != "Example": + continue + + if module_name not in self.target: + self.target[module_name] = [] + + context = f'''{name} at {obj.info.fname}:{obj.info.line}''' + examples, failed = parse_text_to_dicts(s.text, context) + if failed: + # To warn user that docs needs fixing + self.failed = True + + for example in examples: + self.target[module_name].append({ + "id": get_id(random, 10), + "client": example["client"], + "server": example["server"] + }) + + +class QAPISchemaGenExamplesVisitor(QAPISchemaVisitor): + + def __init__(self, prefix: str): + super().__init__() + self.target = {} + self.schema = None + self.failed = False + + def visit_begin(self, schema): + self.schema = schema + + def visit_end(self): + self.schema = None + assert not self.failed, "Should fix the docs" + + def write(self: QAPISchemaGenExamplesVisitor, + output_dir: str) -> None: + for filename, content in self.target.items(): + pathname = os.path.join(output_dir, "examples", filename) + odir = os.path.dirname(pathname) + os.makedirs(odir, exist_ok=True) + result = {"examples": content} + + with open(pathname, "w") as outfile: + outfile.write(json.dumps(result, indent=2, sort_keys=True)) + + def visit_command(self: QAPISchemaGenExamplesVisitor, + name: str, + info: Optional[QAPISourceInfo], + ifcond: QAPISchemaIfCond, + features: List[QAPISchemaFeature], + arg_type: Optional[QAPISchemaObjectType], + ret_type: Optional[QAPISchemaType], + gen: bool, + success_response: bool, + boxed: bool, + allow_oob: bool, + allow_preconfig: bool, + coroutine: bool) -> None: + + if gen: + parse_examples_of(self, name) + + def visit_event(self: QAPISchemaGenExamplesVisitor, + name: str, + info: Optional[QAPISourceInfo], + ifcond: QAPISchemaIfCond, + features: List[QAPISchemaFeature], + arg_type: Optional[QAPISchemaObjectType], + boxed: bool): + + parse_examples_of(self, name) diff --git a/scripts/qapi/main.py b/scripts/qapi/main.py index 316736b6a2..9482439fa9 100644 --- a/scripts/qapi/main.py +++ b/scripts/qapi/main.py @@ -13,6 +13,7 @@ from .commands import gen_commands from .common import must_match +from .dumpexamples import gen_examples from .error import QAPIError from .events import gen_events from .introspect import gen_introspect @@ -53,7 +54,7 @@ def generate(schema_file: str, gen_commands(schema, output_dir, prefix, gen_tracing) gen_events(schema, output_dir, prefix) gen_introspect(schema, output_dir, prefix, unmask) - + gen_examples(schema, output_dir, prefix) def main() -> int: """