{"id":2221161,"url":"http://patchwork.ozlabs.org/api/1.0/patches/2221161/?format=json","project":{"id":14,"url":"http://patchwork.ozlabs.org/api/1.0/projects/14/?format=json","name":"QEMU Development","link_name":"qemu-devel","list_id":"qemu-devel.nongnu.org","list_email":"qemu-devel@nongnu.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20260408165559.157108-3-peterx@redhat.com>","date":"2026-04-08T16:55:46","name":"[02/14] migration/qapi: Rename MigrationStats to MigrationRAMStats","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"c07132ddbbdb1ad92ffdace804fca3eb1666ee2b","submitter":{"id":67717,"url":"http://patchwork.ozlabs.org/api/1.0/people/67717/?format=json","name":"Peter Xu","email":"peterx@redhat.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/qemu-devel/patch/20260408165559.157108-3-peterx@redhat.com/mbox/","series":[{"id":499176,"url":"http://patchwork.ozlabs.org/api/1.0/series/499176/?format=json","date":"2026-04-08T16:55:55","name":"migration/vfio: Fix a few issues on API misuse or statistic reports","version":1,"mbox":"http://patchwork.ozlabs.org/series/499176/mbox/"}],"check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2221161/checks/","tags":{},"headers":{"Return-Path":"<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256\n header.s=mimecast20190719 header.b=KpqbwZgR;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256\n header.s=google header.b=N2gMpHNT;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=nongnu.org\n (client-ip=209.51.188.17; helo=lists.gnu.org;\n envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n receiver=patchwork.ozlabs.org)"],"Received":["from lists.gnu.org (lists1p.gnu.org [209.51.188.17])\n\t(using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4frY9r15p8z1yD6\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 09 Apr 2026 05:32:32 +1000 (AEST)","from localhost ([::1] helo=lists1p.gnu.org)\n\tby lists.gnu.org with esmtp (Exim 4.90_1)\n\t(envelope-from <qemu-devel-bounces@nongnu.org>)\n\tid 1wAYT0-0006H6-KM; Wed, 08 Apr 2026 15:21:34 -0400","from eggs.gnu.org ([2001:470:142:3::10])\n by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <peterx@redhat.com>) id 1wAY3z-0006Ex-5P\n for qemu-devel@nongnu.org; Wed, 08 Apr 2026 14:55:43 -0400","from us-smtp-delivery-124.mimecast.com ([170.10.133.124])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <peterx@redhat.com>) id 1wAWCF-000278-Uk\n for qemu-devel@nongnu.org; Wed, 08 Apr 2026 12:56:10 -0400","from mail-qt1-f198.google.com (mail-qt1-f198.google.com\n [209.85.160.198]) by relay.mimecast.com with ESMTP with STARTTLS\n (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id\n us-mta-212-yOR6rZAsPhKyyTxY1sYEYQ-1; Wed, 08 Apr 2026 12:56:06 -0400","by mail-qt1-f198.google.com with SMTP id\n d75a77b69052e-50b44f7b7bbso32251cf.3\n for <qemu-devel@nongnu.org>; Wed, 08 Apr 2026 09:56:06 -0700 (PDT)","from x1.com ([142.189.10.167]) by smtp.gmail.com with ESMTPSA id\n d75a77b69052e-50d712c2617sm130491901cf.31.2026.04.08.09.56.02\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Wed, 08 Apr 2026 09:56:03 -0700 (PDT)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n s=mimecast20190719; t=1775667367;\n h=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n to:to:cc:cc:mime-version:mime-version:content-type:content-type:\n content-transfer-encoding:content-transfer-encoding:\n in-reply-to:in-reply-to:references:references;\n bh=vMp79kTswNcI5IIMHrzT1aaIDuja5B+32QTFFePbYkM=;\n b=KpqbwZgRCnL0C17T4UJ5/8zyJkpRWz9LSWoS0JemA6Jtqv+bn+UsLW4Zm9OtT2zN0apEaT\n HSq29BGNtVQn0l2UMXBkfvshNmbUh7EJehvYnmjpaHoM24RrnwUNkXTDJhcFEzqxeFUzPb\n cHkRe0bJfbdhgSTzxrg+95DkL+Da5dw=","v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=redhat.com; s=google; t=1775667365; x=1776272165; darn=nongnu.org;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=vMp79kTswNcI5IIMHrzT1aaIDuja5B+32QTFFePbYkM=;\n b=N2gMpHNTDZFqeg6LjYG0ymhxJcYhUj2VLHG5T/BSAAweYRIgW2VJSql+H22QgC7xi4\n dYi3m+4DVs3WLGA2+/WO+YR3u+GIMZf3UlRTrh40D2wnTy0a9hii1d8jdhFzf4RTH/dc\n KV8/pg5e1FUfCSsp3V3OOAKivzttLRghmDlxMJ7vCJj8Hmfdi8T6eiUE1HxHuyCQodTs\n MSntd69yV56bIqyykMnXOTFE+xC45roATS9Gmfl6VQOcgP5FbHQrTEHBBjtQ00DfSQdT\n 6KPukb/aFTieGgLN4D+dinu2tC633u8iqmX3notmHS1/ClDH484EKO32qhyEmQQDWRMR\n qxRA=="],"X-MC-Unique":"yOR6rZAsPhKyyTxY1sYEYQ-1","X-Mimecast-MFC-AGG-ID":"yOR6rZAsPhKyyTxY1sYEYQ_1775667365","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1775667365; x=1776272165;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=vMp79kTswNcI5IIMHrzT1aaIDuja5B+32QTFFePbYkM=;\n b=cDrWJ91hPyzAmhXIv9WpMZi+BUtu8NW9QabjtXqs+4dUhWNdLXpjFLArqBAdgcyZQu\n T63HPBLmD1gHPHARnpYrKDaOjKMOCgKglRkcryGs5MLRphX49akbpKgax1xyaGpiomro\n 5HBT5todWib50c06JDEmryqmbkxuIE9Io7a5L3rXg5UCfJ2RzadV8CDA8wLejX2p+g7o\n cEJrB7Iim8lKo3UcCYoyUeDW/miKMMqNBHcHgcdmJ1fO5dMhGau9oNB5xEfSTAw+senJ\n FX9lizuw0nTIDWVg5byNE+nhfjFYHe6EvrOosPuZGt/tXNrgppm4tdz1BUft/fElPuj7\n wOZg==","X-Gm-Message-State":"AOJu0YzB7rmB5ZaeN+wHDZ+iSdIDkpQTny+L/ciFjt2NgPRrPRNyO9sn\n 7yy66hD+r0hU9pobojLPizzg+maH3KXH7N5IVe6hsAnCt1MXUTxB8ijPriH0QF4bJQaUQ/7oq1g\n sU/edwfAw1NjTNPDpCYvJS7AMMWPdY1XcA4R2hFyH74xnAonZ92JL3sJ8T6UrQpNBqUu2seO3H/\n GV/n5+GquENRR71VoXJz0+lx3oOAiZpox4jYZadw==","X-Gm-Gg":"AeBDies2MOTcVJql+ARHrkPmr9b+Xbxe9q1jsDbr6/BOf4VQBYnPi01SbBGs6eMEafV\n fIx3LZ/bMrXqWkEvIh0tKbsGvjl7vAkTGy3ERrjF+xs8LdGJDf/w5WoomZktdvHIKmRoFsFUqVB\n JZZkwQO8xJcO9U43kkCX3LsUcJzse3IoQGN3FknsixqiwI6k6iZJKh0IwiEdGml40CKF1n+wZE0\n Qcm9+8qNloQIygnzwub57Fajc5N4jEKlWO0pTYZsMFtwVdRjz18gC1B2EKy8xFG3qQjBc18Irp9\n J5L807qPzERNeVB/BgW0fqwLyAAQNMo6wiUyxjX7X2R/n1GjUHA7bJv6Ek9qNaBgGY+p8fNBJ8F\n hqK7B74A2VDpmC8cx1mNof/eGvbLtY2rDVvZT6oZiEgGr","X-Received":["by 2002:ac8:5cd0:0:b0:50d:85c1:3616 with SMTP id\n d75a77b69052e-50dc2261277mr1108091cf.43.1775667364940;\n Wed, 08 Apr 2026 09:56:04 -0700 (PDT)","by 2002:ac8:5cd0:0:b0:50d:85c1:3616 with SMTP id\n d75a77b69052e-50dc2261277mr1107391cf.43.1775667364247;\n Wed, 08 Apr 2026 09:56:04 -0700 (PDT)"],"From":"Peter Xu <peterx@redhat.com>","To":"qemu-devel@nongnu.org","Cc":"\"Maciej S . Szmigiero\" <mail@maciej.szmigiero.name>, =?utf-8?q?Daniel_P_?=\n\t=?utf-8?q?=2E_Berrang=C3=A9?= <berrange@redhat.com>,\n Zhiyi Guo <zhguo@redhat.com>, Juraj Marcin <jmarcin@redhat.com>,\n Peter Xu <peterx@redhat.com>, Prasad Pandit <ppandit@redhat.com>,\n Avihai Horon <avihaih@nvidia.com>, Kirti Wankhede <kwankhede@nvidia.com>,\n\t=?utf-8?q?C=C3=A9dric_Le_Goater?= <clg@redhat.com>,\n Fabiano Rosas <farosas@suse.de>, Joao Martins <joao.m.martins@oracle.com>,\n Markus Armbruster <armbru@redhat.com>, Alex Williamson <alex@shazbot.org>,\n devel@lists.libvirt.org","Subject":"[PATCH 02/14] migration/qapi: Rename MigrationStats to\n MigrationRAMStats","Date":"Wed,  8 Apr 2026 12:55:46 -0400","Message-ID":"<20260408165559.157108-3-peterx@redhat.com>","X-Mailer":"git-send-email 2.53.0","In-Reply-To":"<20260408165559.157108-1-peterx@redhat.com>","References":"<20260408165559.157108-1-peterx@redhat.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Received-SPF":"pass client-ip=170.10.133.124; envelope-from=peterx@redhat.com;\n helo=us-smtp-delivery-124.mimecast.com","X-Spam_score_int":"-25","X-Spam_score":"-2.6","X-Spam_bar":"--","X-Spam_report":"(-2.6 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.54,\n DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,\n RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=0.001,\n RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001,\n SPF_HELO_PASS=-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":"qemu development <qemu-devel.nongnu.org>","List-Unsubscribe":"<https://lists.nongnu.org/mailman/options/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe>","List-Archive":"<https://lists.nongnu.org/archive/html/qemu-devel>","List-Post":"<mailto:qemu-devel@nongnu.org>","List-Help":"<mailto:qemu-devel-request@nongnu.org?subject=help>","List-Subscribe":"<https://lists.nongnu.org/mailman/listinfo/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=subscribe>","Errors-To":"qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org","Sender":"qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org"},"content":"This stats is only about RAM, make it accurate.  This paves way for\nstatistics for all devices.\n\nThanks to Markus, who pointed out that docs/devel/qapi-code-gen.rst has a\nsection \"Compatibility considerations\" stated:\n\n    Since type names are not visible in the Client JSON Protocol, types\n    may be freely renamed.  Even certain refactorings are invisible, such\n    as splitting members from one type into a common base type.\n\nHence this change is not ABI violation according to the document.\n\nWhile at it, touch up the lines to make it read better, correct the\nrestriction on migration status being 'active' or 'completed': over time we\ngrew too many new status that will also report \"ram\" section.\n\nCc: Daniel P. Berrangé <berrange@redhat.com>\nCc: devel@lists.libvirt.org\nReviewed-by: Markus Armbruster <armbru@redhat.com>\nSigned-off-by: Peter Xu <peterx@redhat.com>\n---\n docs/about/removed-features.rst |  2 +-\n qapi/migration.json             | 10 +++++-----\n migration/migration-stats.h     |  2 +-\n 3 files changed, 7 insertions(+), 7 deletions(-)","diff":"diff --git a/docs/about/removed-features.rst b/docs/about/removed-features.rst\nindex 557a24679a..ccd49b5615 100644\n--- a/docs/about/removed-features.rst\n+++ b/docs/about/removed-features.rst\n@@ -699,7 +699,7 @@ was superseded by ``sections``.\n ``query-migrate`` return value member ``skipped`` (removed in 9.1)\n ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''\n \n-Member ``skipped`` of the ``MigrationStats`` struct hasn't been used\n+Member ``skipped`` of the ``MigrationRAMStats`` struct hasn't been used\n for more than 10 years. Removed with no replacement.\n \n ``migrate`` command option ``inc`` (removed in 9.1)\ndiff --git a/qapi/migration.json b/qapi/migration.json\nindex 7134d4ce47..e3ad3f0604 100644\n--- a/qapi/migration.json\n+++ b/qapi/migration.json\n@@ -12,7 +12,7 @@\n { 'include': 'sockets.json' }\n \n ##\n-# @MigrationStats:\n+# @MigrationRAMStats:\n #\n # Detailed migration status.\n #\n@@ -64,7 +64,7 @@\n #\n # Since: 0.14\n ##\n-{ 'struct': 'MigrationStats',\n+{ 'struct': 'MigrationRAMStats',\n   'data': {'transferred': 'int', 'remaining': 'int', 'total': 'int' ,\n            'duplicate': 'int',\n            'normal': 'int',\n@@ -209,8 +209,8 @@\n #     If this field is not returned, no migration process has been\n #     initiated\n #\n-# @ram: `MigrationStats` containing detailed migration status, only\n-#     returned if status is 'active' or 'completed'(since 1.2)\n+# @ram: Detailed migration RAM statistics, only returned if migration\n+#     is in progress or completed (since 1.2)\n #\n # @xbzrle-cache: `XBZRLECacheStats` containing detailed XBZRLE\n #     migration statistics, only returned if XBZRLE feature is on and\n@@ -309,7 +309,7 @@\n # Since: 0.14\n ##\n { 'struct': 'MigrationInfo',\n-  'data': {'*status': 'MigrationStatus', '*ram': 'MigrationStats',\n+  'data': {'*status': 'MigrationStatus', '*ram': 'MigrationRAMStats',\n            '*vfio': 'VfioStats',\n            '*xbzrle-cache': 'XBZRLECacheStats',\n            '*total-time': 'int',\ndiff --git a/migration/migration-stats.h b/migration/migration-stats.h\nindex c0f50144c9..1153520f7a 100644\n--- a/migration/migration-stats.h\n+++ b/migration/migration-stats.h\n@@ -27,7 +27,7 @@\n \n /*\n  * These are the ram migration statistic counters.  It is loosely\n- * based on MigrationStats.\n+ * based on MigrationRAMStats.\n  */\n typedef struct {\n     /*\n","prefixes":["02/14"]}