Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/2194491/?format=api
{ "id": 2194491, "url": "http://patchwork.ozlabs.org/api/patches/2194491/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260209073908.2125178-9-vsementsov@yandex-team.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": "<20260209073908.2125178-9-vsementsov@yandex-team.ru>", "list_archive_url": null, "date": "2026-02-09T07:39:05", "name": "[08/10] vhost: rename vring pointer fields to reflect user addresses", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "b35c9aff4759dd9016a50751c8510e8e8f62a23c", "submitter": { "id": 84116, "url": "http://patchwork.ozlabs.org/api/people/84116/?format=api", "name": "Vladimir Sementsov-Ogievskiy", "email": "vsementsov@yandex-team.ru" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260209073908.2125178-9-vsementsov@yandex-team.ru/mbox/", "series": [ { "id": 491471, "url": "http://patchwork.ozlabs.org/api/series/491471/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=491471", "date": "2026-02-09T07:38:57", "name": "vhost-user: VHOST_USER_PROTOCOL_F_GPA_ADDRESSES", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/491471/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2194491/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2194491/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\tdkim=pass (1024-bit key;\n unprotected) header.d=yandex-team.ru header.i=@yandex-team.ru\n header.a=rsa-sha256 header.s=default header.b=UN9tpCFe;\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)", "mail-nwsmtp-smtp-corp-main-56.klg.yp-c.yandex.net;\n dkim=pass header.i=@yandex-team.ru" ], "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 4f8c6f4ynKz1xtr\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 09 Feb 2026 18:40:10 +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 1vpLrp-0000q2-IQ; Mon, 09 Feb 2026 02:39:33 -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 <vsementsov@yandex-team.ru>)\n id 1vpLrg-0000n7-R1\n for qemu-devel@nongnu.org; Mon, 09 Feb 2026 02:39:26 -0500", "from forwardcorp1d.mail.yandex.net\n ([2a02:6b8:c41:1300:1:45:d181:df01])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <vsementsov@yandex-team.ru>)\n id 1vpLrb-0004gA-Dt\n for qemu-devel@nongnu.org; Mon, 09 Feb 2026 02:39:24 -0500", "from mail-nwsmtp-smtp-corp-main-56.klg.yp-c.yandex.net\n (mail-nwsmtp-smtp-corp-main-56.klg.yp-c.yandex.net\n [IPv6:2a02:6b8:c42:65a0:0:640:e1de:0])\n by forwardcorp1d.mail.yandex.net (Yandex) with ESMTPS id 39935807F7;\n Mon, 09 Feb 2026 10:39:18 +0300 (MSK)", "from vsementsov-lin (unknown [2a02:6bf:8080:129::1:13])\n by mail-nwsmtp-smtp-corp-main-56.klg.yp-c.yandex.net (smtpcorp/Yandex) with\n ESMTPSA id BdLXu72As8c0-vI9MJv00; Mon, 09 Feb 2026 10:39:17 +0300" ], "X-Yandex-Fwd": "1", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex-team.ru;\n s=default; t=1770622757;\n bh=IrKi0wkNb4EqfoJsPMr+89zx9dQBD2rZEgN7gLm9Wuc=;\n h=Message-ID:Date:In-Reply-To:Cc:Subject:References:To:From;\n b=UN9tpCFePLsDELbdRh2f4TR51dilj6Jw9e1PKCJUDApwlAq4y2e2klvm4ZHNt/Ouv\n Gvv4BMpKDnpE60stBLPFNi59dJ34+J8FxYF5tseFtUOLXRUIanA6haIQN6FJH1b+xE\n 4IsvYpDp1ut4usgOWyU6p6ikYRcSrNBpE5Pg9Y6U=", "From": "Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>", "To": "mst@redhat.com", "Cc": "sgarzare@redhat.com, qemu-devel@nongnu.org, vsementsov@yandex-team.ru,\n d-tatianin@yandex-team.ru", "Subject": "[PATCH 08/10] vhost: rename vring pointer fields to reflect user\n addresses", "Date": "Mon, 9 Feb 2026 10:39:05 +0300", "Message-ID": "<20260209073908.2125178-9-vsementsov@yandex-team.ru>", "X-Mailer": "git-send-email 2.52.0", "In-Reply-To": "<20260209073908.2125178-1-vsementsov@yandex-team.ru>", "References": "<20260209073908.2125178-1-vsementsov@yandex-team.ru>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Received-SPF": "pass client-ip=2a02:6b8:c41:1300:1:45:d181:df01;\n envelope-from=vsementsov@yandex-team.ru; helo=forwardcorp1d.mail.yandex.net", "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, DKIM_SIGNED=0.1,\n DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001,\n 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": "Rename vq->desc/avail/used to vq->desc_user/avail_user/used_user to\nclearly indicate these fields contain user space addresses, not\nphysical addresses.\n\nSigned-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>\n---\n hw/virtio/vhost.c | 37 +++++++++++++++++++------------------\n include/hw/virtio/vhost.h | 6 +++---\n 2 files changed, 22 insertions(+), 21 deletions(-)", "diff": "diff --git a/hw/virtio/vhost.c b/hw/virtio/vhost.c\nindex 659efee2b0..1cde1aaebf 100644\n--- a/hw/virtio/vhost.c\n+++ b/hw/virtio/vhost.c\n@@ -489,11 +489,11 @@ static void vhost_vrings_unmap(struct vhost_dev *dev,\n return;\n }\n \n- vhost_memory_unmap(dev, &vq->used, vq->used_size, touched,\n+ vhost_memory_unmap(dev, &vq->used_user, vq->used_size, touched,\n touched ? vq->used_size : 0);\n- vhost_memory_unmap(dev, &vq->avail, vq->avail_size, 0,\n+ vhost_memory_unmap(dev, &vq->avail_user, vq->avail_size, 0,\n touched ? vq->avail_size : 0);\n- vhost_memory_unmap(dev, &vq->desc, vq->desc_size, 0,\n+ vhost_memory_unmap(dev, &vq->desc_user, vq->desc_size, 0,\n touched ? vq->desc_size : 0);\n }\n \n@@ -504,13 +504,13 @@ static int vhost_vrings_map(struct vhost_dev *dev,\n {\n vq->desc_size = virtio_queue_get_desc_size(vdev, idx);\n vq->desc_phys = virtio_queue_get_desc_addr(vdev, idx);\n- vq->desc = NULL;\n+ vq->desc_user = NULL;\n vq->avail_size = virtio_queue_get_avail_size(vdev, idx);\n vq->avail_phys = virtio_queue_get_avail_addr(vdev, idx);\n- vq->avail = NULL;\n+ vq->avail_user = NULL;\n vq->used_size = virtio_queue_get_used_size(vdev, idx);\n vq->used_phys = virtio_queue_get_used_addr(vdev, idx);\n- vq->used = NULL;\n+ vq->used_user = NULL;\n \n if (vq->desc_phys == 0) {\n /* Queue might not be ready for start */\n@@ -521,16 +521,17 @@ static int vhost_vrings_map(struct vhost_dev *dev,\n return 1;\n }\n \n- vq->desc = vhost_memory_map(dev, vq->desc_phys, vq->desc_size, false);\n- if (!vq->desc) {\n+ vq->desc_user = vhost_memory_map(dev, vq->desc_phys, vq->desc_size, false);\n+ if (!vq->desc_user) {\n goto fail;\n }\n- vq->avail = vhost_memory_map(dev, vq->avail_phys, vq->avail_size, false);\n- if (!vq->avail) {\n+ vq->avail_user = vhost_memory_map(dev, vq->avail_phys, vq->avail_size,\n+ false);\n+ if (!vq->avail_user) {\n goto fail;\n }\n- vq->used = vhost_memory_map(dev, vq->used_phys, vq->used_size, true);\n- if (!vq->used) {\n+ vq->used_user = vhost_memory_map(dev, vq->used_phys, vq->used_size, true);\n+ if (!vq->used_user) {\n goto fail;\n }\n \n@@ -594,7 +595,7 @@ static int vhost_verify_ring_mappings(struct vhost_dev *dev,\n \n j = 0;\n r = vhost_verify_ring_part_mapping(\n- vq->desc, vq->desc_phys, vq->desc_size,\n+ vq->desc_user, vq->desc_phys, vq->desc_size,\n reg_hva, reg_gpa, reg_size);\n if (r) {\n break;\n@@ -602,7 +603,7 @@ static int vhost_verify_ring_mappings(struct vhost_dev *dev,\n \n j++;\n r = vhost_verify_ring_part_mapping(\n- vq->avail, vq->avail_phys, vq->avail_size,\n+ vq->avail_user, vq->avail_phys, vq->avail_size,\n reg_hva, reg_gpa, reg_size);\n if (r) {\n break;\n@@ -610,7 +611,7 @@ static int vhost_verify_ring_mappings(struct vhost_dev *dev,\n \n j++;\n r = vhost_verify_ring_part_mapping(\n- vq->used, vq->used_phys, vq->used_size,\n+ vq->used_user, vq->used_phys, vq->used_size,\n reg_hva, reg_gpa, reg_size);\n if (r) {\n break;\n@@ -1106,9 +1107,9 @@ static int vhost_virtqueue_set_addr(struct vhost_dev *dev,\n addr.avail_user_addr = (uint64_t)(unsigned long)vq->avail_phys;\n addr.used_user_addr = (uint64_t)(unsigned long)vq->used_phys;\n } else {\n- addr.desc_user_addr = (uint64_t)(unsigned long)vq->desc;\n- addr.avail_user_addr = (uint64_t)(unsigned long)vq->avail;\n- addr.used_user_addr = (uint64_t)(unsigned long)vq->used;\n+ addr.desc_user_addr = (uint64_t)(unsigned long)vq->desc_user;\n+ addr.avail_user_addr = (uint64_t)(unsigned long)vq->avail_user;\n+ addr.used_user_addr = (uint64_t)(unsigned long)vq->used_user;\n }\n addr.index = idx;\n addr.log_guest_addr = vq->used_phys;\ndiff --git a/include/hw/virtio/vhost.h b/include/hw/virtio/vhost.h\nindex b292e9f0fe..684bafcaad 100644\n--- a/include/hw/virtio/vhost.h\n+++ b/include/hw/virtio/vhost.h\n@@ -24,9 +24,9 @@ struct vhost_inflight {\n struct vhost_virtqueue {\n int kick;\n int call;\n- void *desc;\n- void *avail;\n- void *used;\n+ void *desc_user;\n+ void *avail_user;\n+ void *used_user;\n int num;\n unsigned long long desc_phys;\n unsigned desc_size;\n", "prefixes": [ "08/10" ] }