Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/1.1/patches/2233230/?format=api
{ "id": 2233230, "url": "http://patchwork.ozlabs.org/api/1.1/patches/2233230/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260505202640.1011006-19-peterx@redhat.com/", "project": { "id": 14, "url": "http://patchwork.ozlabs.org/api/1.1/projects/14/?format=api", "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": "<20260505202640.1011006-19-peterx@redhat.com>", "date": "2026-05-05T20:26:35", "name": "[PULL,18/23] vfio/migration: Add tracepoints for precopy/stopcopy query ioctls", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "ebdb7c0175b9b4696bc0b5d7d8aad8d195bb2d58", "submitter": { "id": 67717, "url": "http://patchwork.ozlabs.org/api/1.1/people/67717/?format=api", "name": "Peter Xu", "email": "peterx@redhat.com" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260505202640.1011006-19-peterx@redhat.com/mbox/", "series": [ { "id": 502897, "url": "http://patchwork.ozlabs.org/api/1.1/series/502897/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=502897", "date": "2026-05-05T20:26:17", "name": "[PULL,01/23] migration: Fix blocking in POSTCOPY_DEVICE during package load", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/502897/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2233230/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2233230/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=c732tGR7;\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=BfCcGKoP;\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=lists1p.gnu.org;\n envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n receiver=patchwork.ozlabs.org)" ], "Received": [ "from lists1p.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 4g99B05y34z1yJ0\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 06 May 2026 06:30:16 +1000 (AEST)", "from localhost ([::1] helo=lists1p.gnu.org)\n\tby lists1p.gnu.org with esmtp (Exim 4.90_1)\n\t(envelope-from <qemu-devel-bounces@nongnu.org>)\n\tid 1wKMMO-0004c3-2W; Tue, 05 May 2026 16:27:16 -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 1wKMMK-0004X0-3n\n for qemu-devel@nongnu.org; Tue, 05 May 2026 16:27:13 -0400", "from us-smtp-delivery-124.mimecast.com ([170.10.129.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 1wKMMH-0002f6-7C\n for qemu-devel@nongnu.org; Tue, 05 May 2026 16:27:11 -0400", "from mail-qk1-f198.google.com (mail-qk1-f198.google.com\n [209.85.222.198]) by relay.mimecast.com with ESMTP with STARTTLS\n (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id\n us-mta-457-pjZ11YRgOFGhEb71RgYl_A-1; Tue, 05 May 2026 16:27:06 -0400", "by mail-qk1-f198.google.com with SMTP id\n af79cd13be357-902e1e4f8ccso341009185a.0\n for <qemu-devel@nongnu.org>; Tue, 05 May 2026 13:27:06 -0700 (PDT)", "from x1.com ([142.189.10.167]) by smtp.gmail.com with ESMTPSA id\n 6a1803df08f44-8b53c6b8123sm155283806d6.35.2026.05.05.13.27.03\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Tue, 05 May 2026 13:27:04 -0700 (PDT)" ], "DKIM-Signature": [ "v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n s=mimecast20190719; t=1778012827;\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=ZOv4dkPxbigP2amkOsD1OyD2ureHpWxPWa9Eo8OsVWA=;\n b=c732tGR74BukJZx/YQhdkp/BCRGM60DbD5zLPH0hbWmoKQFtk8lAWNb/j8mn1f7FFgiyZ2\n JWuVRpAJH80IKUJrd6eRdePt0Vdgi7kBRBFq1x6c11gEa9yIycUiP9HOeDii9bTPAfPR/1\n Kj7l45UZtc5iLGHIQSLdBsmw7jrN5Cg=", "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=redhat.com; s=google; t=1778012825; x=1778617625; 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=ZOv4dkPxbigP2amkOsD1OyD2ureHpWxPWa9Eo8OsVWA=;\n b=BfCcGKoPXrI/ouYOhelUYpBg+Wf+k1EbRIQgJF/gQXRYyRnmQRG0oA6AdwAee/F6By\n xoExRXSp9Ash5eR/Ww9SlQUNtSUa8Qfoyidoobx10f30zy2LvLRu1WLGcOD6wLLWUobd\n 6k/lB5EzPKg1x4FRMcPX80ZrcjK8/osUsM0Z7QGX6uuVS45U13ikGaLYvfd+/GbodBcp\n kwlXt3an085yOxr1jsFdSiRWZGEg/dnTQhVXEl82IJ0kuVGJMscAMlQQp1nK/pwkFI5X\n 6et0lheNVdwwTsIvxpGnT5KTIKEqoAxDQz/9mw9R4yiNndYzGT3sdigWSs8xRhkyzsN0\n e7MA==" ], "X-MC-Unique": "pjZ11YRgOFGhEb71RgYl_A-1", "X-Mimecast-MFC-AGG-ID": "pjZ11YRgOFGhEb71RgYl_A_1778012826", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1778012825; x=1778617625;\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=ZOv4dkPxbigP2amkOsD1OyD2ureHpWxPWa9Eo8OsVWA=;\n b=dxQfmEEyS4YLpH3LwbHFZ2y2LJqhFmf5gkFwVQ/pi/HjL60/ZXWz8+kum9imWSouu5\n 7xcysXZdbchGSFkOrFSoQCE/0iWuxoDi1+22ddh8jwmEyPk0Iemxh/rJSxYPYhqmFHw0\n qj+HvFp0Ac7F2kBJ2fSuM/FrTEXM+WbCyeNTVdZJHt6KdWM9RN0MtMVAWfHeMrSJ3LRG\n Me3Uw0lHp3wG3+ms8ss7EXqtpWIZzKYTPdCiGLk3sgJF+sfXoJVDBjDyU8wxFztQ8EXx\n Z0oX1ZA1Ke0RCLj/FUyBuChMboJMLtyB0p1/Q7tQ4aAu7oSftLtp7gdeuAnAhPYpI917\n xLtg==", "X-Gm-Message-State": "AOJu0Yzs8sTpMPpYYFiVQ2+3nn2vUICBQHYQT10RhTk6FZr4uPY/zgsJ\n DMsFJLBs0ICh8kg1Q1XGjopsi/t4mvDjPyXGinyfhM22guIj324HVUL6k0Jm/r3TKJ1cjoggO/1\n 8XUv2r8P8KD3Ah2o5ohO0KrZi3iFbaw1K4bezU0tT8Bs20bYFQqsMd9S9HTNzfot7YRK7iK9h4T\n Ja0GArs3EykPv+sNMUSn7/bFy6JKWOexy3HqHuSA==", "X-Gm-Gg": "AeBDievwjsBvO17oJlxVMX7OpQEkGP4SbWLUnri3XqzZbVA0zoKrUkJyiTnXreFwrhW\n IqkEjemZV9qlsZtikrOS1f21Ih+3h4lcNCuQSmO/5k9rzAOQUvRarjxtr+4IKmpHV7n8zumEJya\n fbQIy0mTg7A+xSZm2H5koE9KaC79B9E1v8gXm++tndjAgULryjxLtCHY/y4JRSrM0OX1W+j7MXn\n b4d5wqIpY1cLB2KUJFIGb4P6M9kUIEnpBGYlkrfg6uiTnEkOMwNvgLgpaYs4SI9eKzx0JHrdWMw\n qOPdUiVj6RyYJPZu6sfgd02LduhOTiDQ5UFENOj8GUwL5D1oOPX9IoaJYRj8t/kEa4f3oaQxooj\n jbm/Lyypl9JcnJy6cnYNflYYaLuR+89hIZLnHsQt/0H5qMWG4bHNXReo=", "X-Received": [ "by 2002:a05:620a:280e:b0:8f0:10b0:9e4a with SMTP id\n af79cd13be357-904d6fcc196mr91062185a.57.1778012825154;\n Tue, 05 May 2026 13:27:05 -0700 (PDT)", "by 2002:a05:620a:280e:b0:8f0:10b0:9e4a with SMTP id\n af79cd13be357-904d6fcc196mr91057385a.57.1778012824538;\n Tue, 05 May 2026 13:27:04 -0700 (PDT)" ], "From": "Peter Xu <peterx@redhat.com>", "To": "qemu-devel@nongnu.org", "Cc": "Fabiano Rosas <farosas@suse.de>, Paolo Bonzini <pbonzini@redhat.com>,\n Peter Xu <peterx@redhat.com>, Avihai Horon <avihaih@nvidia.com>,\n\t=?utf-8?q?C=C3=A9dric_Le_Goater?= <clg@redhat.com>", "Subject": "[PULL 18/23] vfio/migration: Add tracepoints for precopy/stopcopy\n query ioctls", "Date": "Tue, 5 May 2026 16:26:35 -0400", "Message-ID": "<20260505202640.1011006-19-peterx@redhat.com>", "X-Mailer": "git-send-email 2.53.0", "In-Reply-To": "<20260505202640.1011006-1-peterx@redhat.com>", "References": "<20260505202640.1011006-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.129.124; envelope-from=peterx@redhat.com;\n helo=us-smtp-delivery-124.mimecast.com", "X-Spam_score_int": "-24", "X-Spam_score": "-2.5", "X-Spam_bar": "--", "X-Spam_report": "(-2.5 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.443,\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_H4=0.001, RCVD_IN_MSPIKE_WL=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": "Add two tracepoints for both precopy and stopcopy query ioctls. When at\nit, add one warn_report_once() for each of them when it fails.\n\nReviewed-by: Avihai Horon <avihaih@nvidia.com>\nTested-by: Cédric Le Goater <clg@redhat.com>\nReviewed-by: Cédric Le Goater <clg@redhat.com>\nLink: https://lore.kernel.org/r/20260421202110.306051-17-peterx@redhat.com\nSigned-off-by: Peter Xu <peterx@redhat.com>\n---\n hw/vfio/migration.c | 35 +++++++++++++++++++++++++----------\n hw/vfio/trace-events | 2 ++\n 2 files changed, 27 insertions(+), 10 deletions(-)", "diff": "diff --git a/hw/vfio/migration.c b/hw/vfio/migration.c\nindex e6e6a0d53d..150e28656e 100644\n--- a/hw/vfio/migration.c\n+++ b/hw/vfio/migration.c\n@@ -329,6 +329,7 @@ static int vfio_query_stop_copy_size(VFIODevice *vbasedev)\n struct vfio_device_feature_mig_data_size *mig_data_size =\n (struct vfio_device_feature_mig_data_size *)feature->data;\n VFIOMigration *migration = vbasedev->migration;\n+ int ret;\n \n feature->argsz = sizeof(buf);\n feature->flags =\n@@ -340,12 +341,19 @@ static int vfio_query_stop_copy_size(VFIODevice *vbasedev)\n * is reported so downtime limit won't be violated.\n */\n migration->stopcopy_size = VFIO_MIG_STOP_COPY_SIZE;\n- return -errno;\n+ ret = -errno;\n+ warn_report_once(\"VFIO device %s ioctl(VFIO_DEVICE_FEATURE) on \"\n+ \"VFIO_DEVICE_FEATURE_MIG_DATA_SIZE failed (%d)\",\n+ vbasedev->name, ret);\n+ } else {\n+ migration->stopcopy_size = mig_data_size->stop_copy_length;\n+ ret = 0;\n }\n \n- migration->stopcopy_size = mig_data_size->stop_copy_length;\n+ trace_vfio_query_stop_copy_size(vbasedev->name,\n+ migration->stopcopy_size, ret);\n \n- return 0;\n+ return ret;\n }\n \n static int vfio_query_precopy_size(VFIOMigration *migration)\n@@ -353,18 +361,25 @@ static int vfio_query_precopy_size(VFIOMigration *migration)\n struct vfio_precopy_info precopy = {\n .argsz = sizeof(precopy),\n };\n-\n- migration->precopy_init_size = 0;\n- migration->precopy_dirty_size = 0;\n+ int ret;\n \n if (ioctl(migration->data_fd, VFIO_MIG_GET_PRECOPY_INFO, &precopy)) {\n- return -errno;\n+ migration->precopy_init_size = 0;\n+ migration->precopy_dirty_size = 0;\n+ ret = -errno;\n+ warn_report_once(\"VFIO device %s ioctl(VFIO_MIG_GET_PRECOPY_INFO) \"\n+ \"failed (%d)\", migration->vbasedev->name, ret);\n+ } else {\n+ migration->precopy_init_size = precopy.initial_bytes;\n+ migration->precopy_dirty_size = precopy.dirty_bytes;\n+ ret = 0;\n }\n \n- migration->precopy_init_size = precopy.initial_bytes;\n- migration->precopy_dirty_size = precopy.dirty_bytes;\n+ trace_vfio_query_precopy_size(migration->vbasedev->name,\n+ migration->precopy_init_size,\n+ migration->precopy_dirty_size, ret);\n \n- return 0;\n+ return ret;\n }\n \n /* Returns the size of saved data on success and -errno on error */\ndiff --git a/hw/vfio/trace-events b/hw/vfio/trace-events\nindex 287df0b8cb..2049159015 100644\n--- a/hw/vfio/trace-events\n+++ b/hw/vfio/trace-events\n@@ -162,6 +162,8 @@ vfio_migration_realize(const char *name) \" (%s)\"\n vfio_migration_set_device_state(const char *name, const char *state) \" (%s) state %s\"\n vfio_migration_set_state(const char *name, const char *new_state, const char *recover_state) \" (%s) new state %s, recover state %s\"\n vfio_migration_state_notifier(const char *name, int state) \" (%s) state %d\"\n+vfio_query_precopy_size(const char *name, uint64_t init_size, uint64_t dirty_size, int ret) \" (%s) init %\"PRIu64\" dirty %\"PRIu64\" ret %d\"\n+vfio_query_stop_copy_size(const char *name, uint64_t size, int ret) \" (%s) stopcopy size %\"PRIu64\" ret %d\"\n vfio_save_block(const char *name, int data_size) \" (%s) data_size %d\"\n vfio_save_block_precopy_empty_hit(const char *name) \" (%s)\"\n vfio_save_cleanup(const char *name) \" (%s)\"\n", "prefixes": [ "PULL", "18/23" ] }