get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/2195057/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 2195057,
    "url": "http://patchwork.ozlabs.org/api/patches/2195057/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260210121657.69363-7-mjt@tls.msk.ru/",
    "project": {
        "id": 14,
        "url": "http://patchwork.ozlabs.org/api/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": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20260210121657.69363-7-mjt@tls.msk.ru>",
    "list_archive_url": null,
    "date": "2026-02-10T12:16:40",
    "name": "[Stable-10.0.8,76/85] vdpa: fix vhost-vdpa suspended state not be shared",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "d8211488156152b7b889586e170ecffd337f3157",
    "submitter": {
        "id": 183,
        "url": "http://patchwork.ozlabs.org/api/people/183/?format=api",
        "name": "Michael Tokarev",
        "email": "mjt@tls.msk.ru"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260210121657.69363-7-mjt@tls.msk.ru/mbox/",
    "series": [
        {
            "id": 491663,
            "url": "http://patchwork.ozlabs.org/api/series/491663/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=491663",
            "date": "2026-02-10T12:16:40",
            "name": "Patch Round-up for stable 10.0.8, freeze on 2026-02-10 (frozen)",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/491663/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2195057/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2195057/checks/",
    "tags": {},
    "related": [],
    "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 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 (lists.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 4f9LJ811mCz1xtr\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 10 Feb 2026 23:20:56 +1100 (AEDT)",
            "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 1vpmjT-0002eK-MN; Tue, 10 Feb 2026 07:20:47 -0500",
            "from eggs.gnu.org ([2001:470:142:3::10])\n by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <mjt@tls.msk.ru>)\n id 1vpmiG-0007X1-3t; Tue, 10 Feb 2026 07:19:31 -0500",
            "from isrv.corpit.ru ([212.248.84.144])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <mjt@tls.msk.ru>)\n id 1vpmiE-0001km-29; Tue, 10 Feb 2026 07:19:27 -0500",
            "from tsrv.corpit.ru (tsrv.tls.msk.ru [192.168.177.2])\n by isrv.corpit.ru (Postfix) with ESMTP id B326F187DE0;\n Tue, 10 Feb 2026 15:16:17 +0300 (MSK)",
            "from think4mjt.tls.msk.ru (mjtthink.wg.tls.msk.ru [192.168.177.146])\n by tsrv.corpit.ru (Postfix) with ESMTP id 4D9CC360CF4;\n Tue, 10 Feb 2026 15:17:13 +0300 (MSK)"
        ],
        "From": "Michael Tokarev <mjt@tls.msk.ru>",
        "To": "qemu-devel@nongnu.org",
        "Cc": "qemu-stable@nongnu.org, Wafer Xie <wafer@jaguarmicro.com>, =?utf-8?q?Eug?=\n\t=?utf-8?q?enio_P=C3=A9rez?= <eperezma@redhat.com>,\n Jason Wang <jasowang@redhat.com>, \"Michael S. Tsirkin\" <mst@redhat.com>,\n Michael Tokarev <mjt@tls.msk.ru>",
        "Subject": "[Stable-10.0.8 76/85] vdpa: fix vhost-vdpa suspended state not be\n shared",
        "Date": "Tue, 10 Feb 2026 15:16:40 +0300",
        "Message-ID": "<20260210121657.69363-7-mjt@tls.msk.ru>",
        "X-Mailer": "git-send-email 2.47.3",
        "In-Reply-To": "<qemu-stable-10.0.8-20260210151548@cover.tls.msk.ru>",
        "References": "<qemu-stable-10.0.8-20260210151548@cover.tls.msk.ru>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=UTF-8",
        "Content-Transfer-Encoding": "8bit",
        "Received-SPF": "pass client-ip=212.248.84.144; envelope-from=mjt@tls.msk.ru;\n helo=isrv.corpit.ru",
        "X-Spam_score_int": "-18",
        "X-Spam_score": "-1.9",
        "X-Spam_bar": "-",
        "X-Spam_report": "(-1.9 / 5.0 requ) BAYES_00=-1.9,\n RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001,\n 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": "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": "From: Wafer Xie <wafer@jaguarmicro.com>\n\nWhen stopping a vhost-vdpa device, only the first queue pair is marked as suspended,\nwhile the remaining queues are not updated to the suspended state.\nAs a result, when stopping a multi-queue vhost-vdpa device,\nthe following error message will be printed.\n\nqemu-system-x86_64:vhost VQ 2 ring restore failed: -1: Operation not permitted (1)\n\nqemu-system-x86_64:vhost VQ 3 ring restore failed: -1: Operation not permitted (1)\n\nSo move v->suspended to v->shared, and then all the vhost_vdpa devices cannot\nhave different suspended states.\n\nFixes: 0bb302a9960a (\"vdpa: add vhost_vdpa_suspend\")\nSuggested-by: Eugenio Pérez <eperezma@redhat.com>\nAcked-by: Eugenio Pérez <eperezma@redhat.com>\nAcked-by: Jason Wang <jasowang@redhat.com>\nSigned-off-by: Wafer Xie <wafer@jaguarmicro.com>\nReviewed-by: Michael S. Tsirkin <mst@redhat.com>\nSigned-off-by: Michael S. Tsirkin <mst@redhat.com>\nAcked-by: Jason Wang <jasowang@redhat.com>\nMessage-Id: <20251119132452.3117-1-wafer@jaguarmicro.com>\n(cherry picked from commit fd3a2c601ab4a1bdb669e4c584b364e00a978702)\n(Mjt: context fixup due to missing v10.0.0-1280-g494c50dcc099\n \"vdpa: move memory listener register to vhost_vdpa_init\")\nSigned-off-by: Michael Tokarev <mjt@tls.msk.ru>",
    "diff": "diff --git a/hw/virtio/vhost-vdpa.c b/hw/virtio/vhost-vdpa.c\nindex 7efbde3d4c..51c675271e 100644\n--- a/hw/virtio/vhost-vdpa.c\n+++ b/hw/virtio/vhost-vdpa.c\n@@ -890,7 +890,7 @@ static int vhost_vdpa_reset_device(struct vhost_dev *dev)\n \n     ret = vhost_vdpa_call(dev, VHOST_VDPA_SET_STATUS, &status);\n     trace_vhost_vdpa_reset_device(dev);\n-    v->suspended = false;\n+    v->shared->suspended = false;\n     return ret;\n }\n \n@@ -1339,7 +1339,7 @@ static void vhost_vdpa_suspend(struct vhost_dev *dev)\n         if (unlikely(r)) {\n             error_report(\"Cannot suspend: %s(%d)\", g_strerror(errno), errno);\n         } else {\n-            v->suspended = true;\n+            v->shared->suspended = true;\n             return;\n         }\n     }\n@@ -1461,7 +1461,7 @@ static int vhost_vdpa_get_vring_base(struct vhost_dev *dev,\n         return 0;\n     }\n \n-    if (!v->suspended) {\n+    if (!v->shared->suspended) {\n         /*\n          * Cannot trust in value returned by device, let vhost recover used\n          * idx from guest.\ndiff --git a/include/hw/virtio/vhost-vdpa.h b/include/hw/virtio/vhost-vdpa.h\nindex 0a9575b469..03289d4e32 100644\n--- a/include/hw/virtio/vhost-vdpa.h\n+++ b/include/hw/virtio/vhost-vdpa.h\n@@ -56,6 +56,12 @@ typedef struct vhost_vdpa_shared {\n \n     /* SVQ switching is in progress, or already completed? */\n     SVQTransitionState svq_switching;\n+\n+    /*\n+     * Device suspended successfully.\n+     * The vhost_vdpa devices cannot have different suspended states.\n+     */\n+    bool suspended;\n } VhostVDPAShared;\n \n typedef struct vhost_vdpa {\n@@ -63,8 +69,6 @@ typedef struct vhost_vdpa {\n     uint32_t address_space_id;\n     uint64_t acked_features;\n     bool shadow_vqs_enabled;\n-    /* Device suspended successfully */\n-    bool suspended;\n     VhostVDPAShared *shared;\n     GPtrArray *shadow_vqs;\n     const VhostShadowVirtqueueOps *shadow_vq_ops;\n",
    "prefixes": [
        "Stable-10.0.8",
        "76/85"
    ]
}