From nobody Wed Nov 5 11:06:58 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1504541654503593.5709949158808; Mon, 4 Sep 2017 09:14:14 -0700 (PDT) Received: from localhost ([::1]:54763 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dou0r-000397-GX for importer@patchew.org; Mon, 04 Sep 2017 12:14:13 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46882) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dotvJ-0007Kd-Mi for qemu-devel@nongnu.org; Mon, 04 Sep 2017 12:08:34 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dotvE-0008RS-Mc for qemu-devel@nongnu.org; Mon, 04 Sep 2017 12:08:29 -0400 Received: from mail-wm0-x244.google.com ([2a00:1450:400c:c09::244]:33075) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dotvE-0008RA-GM for qemu-devel@nongnu.org; Mon, 04 Sep 2017 12:08:24 -0400 Received: by mail-wm0-x244.google.com with SMTP id 187so726460wmn.0 for ; Mon, 04 Sep 2017 09:08:24 -0700 (PDT) Received: from localhost.localdomain.localdomain ([217.110.131.66]) by smtp.gmail.com with ESMTPSA id x67sm976582wma.7.2017.09.04.09.08.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 04 Sep 2017 09:08:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=PMWb39TG6i90d/bBdYkgh1s4O4E5BpKYtBUKz04GHyM=; b=Bbidqhn0CLjik2+jTQ3pmnhi4ZjXabf8oozdg/X6+ooKCE9rEyQ/Q46GVZ7IAYNHXY uDmEkVz7+xFdDkC7877PUpsxqrGNgBx0pyCeeNcEzlstfRiSqRBbBbhibPYGdapfc1a5 Q7hrwOzmnV2xnGv1VYvDqE4+n0Kk+YlNd7HAlMEID45kwUN88baf1nQOd1s1j9tUd1+x nglgJCIwU7GWrEdiuYwsk/D2zPkv6sdOSa7JAeNywWen5ef9yyK4hSumvu1bJY1Reiah rmzV72paTb1Y/GN+aDHtwKNZr9z5gte3KS/Y8GLS+HTUrJbtVhakFxSgZ9mKO+XMvIxl ve2A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=PMWb39TG6i90d/bBdYkgh1s4O4E5BpKYtBUKz04GHyM=; b=HR1rhY9+rmYmGO7Z1XKk5snl0wxNW4szMPUsPQtUPeZJxzmOCoWCfAYgqWNn5DPfH5 mlRCGJH2qTsDPR67de7AcIGr9o+lTDuWNUoiovvC0eIKq748bOyWgR0X2gYtkLDBYhKB RJKjBFy/lPp2IaFNhgHV367T6T75YuFub/G4TXe/8zdvKmHdOynK7Og9Lz3ALC1H7rWr 9KwmEwCJgi1oXkVkO025ZAu7lguCIZY4qggA5r+q2RvVI7fSu8ti1HmUdoJ6GnIl+hOq FmNVgHAPuQqxm+UjjPd94YUGNHzpnGSIvboNEvZPGFm8D3bA6fb/0Bd1rehJjHFDex7X gblQ== X-Gm-Message-State: AHPjjUhPx70pQHlJe4SpD2bJ37UprDbrX5NLySnSt9JJm5j+z5Mu2BT7 a5zZpYNh4jSwEg== X-Google-Smtp-Source: ADKCNb4dHyC8hT8zSfVxxu1es0NXCsRuKSbw3y9iwfa6GNPiiuJcpr16WWTDFLq4P3zrDIJhFuKupA== X-Received: by 10.28.131.211 with SMTP id f202mr763934wmd.187.1504541303474; Mon, 04 Sep 2017 09:08:23 -0700 (PDT) From: Pradeep Jagadeesh X-Google-Original-From: Pradeep Jagadeesh To: "eric blake" , "greg kurz" Date: Mon, 4 Sep 2017 12:07:43 -0400 Message-Id: <1504541267-36954-3-git-send-email-pradeep.jagadeesh@huawei.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1504541267-36954-1-git-send-email-pradeep.jagadeesh@huawei.com> References: <1504541267-36954-1-git-send-email-pradeep.jagadeesh@huawei.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:400c:c09::244 Subject: [Qemu-devel] [PATCH v10 2/6] qmp: Create IOThrottle structure X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jani kokkonen , alberto garcia , Pradeep Jagadeesh , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" This patch enables qmp interfaces for the fsdev devices. This provides two interfaces one for querying info of all the fsdev devices. The second one to set the IO limits for the required fsdev device. Signed-off-by: Pradeep Jagadeesh Reviewed-by: Greg Kurz Reviewed-by: Eric Blake Reviewed-by: Alberto Garcia Reviewed-by: Markus Armbruster --- qapi/block-core.json | 34 +++++++++++++++++++++++++--------- 1 file changed, 25 insertions(+), 9 deletions(-) diff --git a/qapi/block-core.json b/qapi/block-core.json index 833c602..a01074c 100644 --- a/qapi/block-core.json +++ b/qapi/block-core.json @@ -1819,11 +1819,13 @@ 'data': 'BlockIOThrottle' } =20 ## -# @BlockIOThrottle: -# -# A set of parameters describing block throttling. +# =3D=3D QAPI IOThrottle definitions +## + +## +# @IOThrottle: # -# @device: Block device name (deprecated, use @id instead) +# A set of parameters describing IO throttling # # @id: The name or QOM path of the guest device (since: 2.8) # @@ -1889,12 +1891,11 @@ # # @iops_size: an I/O size in bytes (Since 1.7) # -# @group: throttle group name (Since 2.4) # -# Since: 1.1 +# Since: 2.11 ## -{ 'struct': 'BlockIOThrottle', - 'data': { '*device': 'str', '*id': 'str', 'bps': 'int', 'bps_rd': 'int', +{ 'struct': 'IOThrottle', + 'data': { '*id': 'str', 'bps': 'int', 'bps_rd': 'int', 'bps_wr': 'int', 'iops': 'int', 'iops_rd': 'int', 'iops_wr': '= int', '*bps_max': 'int', '*bps_rd_max': 'int', '*bps_wr_max': 'int', '*iops_max': 'int', @@ -1902,7 +1903,22 @@ '*bps_max_length': 'int', '*bps_rd_max_length': 'int', '*bps_wr_max_length': 'int', '*iops_max_length': 'int', '*iops_rd_max_length': 'int', '*iops_wr_max_length': 'int', - '*iops_size': 'int', '*group': 'str' } } + '*iops_size': 'int' } } + +## +# @BlockIOThrottle: +# +# A set of parameters describing block throttling. +# +# @device: Block device name (deprecated, use @id instead) +# +# @group: throttle group name (Since 2.4) +# +# Since: 1.1 +## +{ 'struct': 'BlockIOThrottle', + 'base': 'IOThrottle', + 'data': { '*device': 'str', '*group': 'str' } } =20 ## # @block-stream: --=20 1.8.3.1