Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/7644/?format=api
https://patches.dpdk.org/api/patches/7644/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/1444907319-26348-1-git-send-email-marcel@redhat.com/", "project": { "id": 1, "url": "https://patches.dpdk.org/api/projects/1/?format=api", "name": "DPDK", "link_name": "dpdk", "list_id": "dev.dpdk.org", "list_email": "dev@dpdk.org", "web_url": "http://core.dpdk.org", "scm_url": "git://dpdk.org/dpdk", "webscm_url": "http://git.dpdk.org/dpdk", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<1444907319-26348-1-git-send-email-marcel@redhat.com>", "list_archive_url": "https://inbox.dpdk.org/dev/1444907319-26348-1-git-send-email-marcel@redhat.com", "date": "2015-10-15T11:08:39", "name": "[dpdk-dev] vhost-user: enable virtio 1.0", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": true, "hash": "1f3dfefe89cccccf312eaec60e218bab895c0b29", "submitter": { "id": 331, "url": "https://patches.dpdk.org/api/people/331/?format=api", "name": "Marcel Apfelbaum", "email": "marcel@redhat.com" }, "delegate": null, "mbox": "https://patches.dpdk.org/project/dpdk/patch/1444907319-26348-1-git-send-email-marcel@redhat.com/mbox/", "series": [], "comments": "https://patches.dpdk.org/api/patches/7644/comments/", "check": "pending", "checks": "https://patches.dpdk.org/api/patches/7644/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@dpdk.org", "Delivered-To": "patchwork@dpdk.org", "Received": [ "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id 065F25927;\n\tThu, 15 Oct 2015 13:08:45 +0200 (CEST)", "from mx1.redhat.com (mx1.redhat.com [209.132.183.28])\n\tby dpdk.org (Postfix) with ESMTP id AFE80231C\n\tfor <dev@dpdk.org>; Thu, 15 Oct 2015 13:08:43 +0200 (CEST)", "from int-mx11.intmail.prod.int.phx2.redhat.com\n\t(int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24])\n\tby mx1.redhat.com (Postfix) with ESMTPS id E9144BAEC7;\n\tThu, 15 Oct 2015 11:08:42 +0000 (UTC)", "from work.redhat.com (vpn1-4-234.ams2.redhat.com [10.36.4.234])\n\tby int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with\n\tESMTP id t9FB8epV015883; Thu, 15 Oct 2015 07:08:41 -0400" ], "From": "Marcel Apfelbaum <marcel@redhat.com>", "To": "dev@dpdk.org", "Date": "Thu, 15 Oct 2015 14:08:39 +0300", "Message-Id": "<1444907319-26348-1-git-send-email-marcel@redhat.com>", "X-Scanned-By": "MIMEDefang 2.68 on 10.5.11.24", "Cc": "marcel@redhat.com, mst@redhat.com", "Subject": "[dpdk-dev] [PATCH] vhost-user: enable virtio 1.0", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "patches and discussions about DPDK <dev.dpdk.org>", "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://dpdk.org/ml/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "Make vhost-user virtio 1.0 compatible by adding it to the\nsupported features and keeping the header length\nthe same as for mergeable RX buffers.\n\nSigned-off-by: Marcel Apfelbaum <marcel@redhat.com>\n---\n\nTo be applied on top of:\n [dpdk-dev] [PATCH v6 00/13] vhost-user multiple queues enabling\n\nThanks,\nMarcel\n \n lib/librte_vhost/virtio-net.c | 15 ++++++++-------\n 1 file changed, 8 insertions(+), 7 deletions(-)", "diff": "diff --git a/lib/librte_vhost/virtio-net.c b/lib/librte_vhost/virtio-net.c\nindex a51327d..ee4650e 100644\n--- a/lib/librte_vhost/virtio-net.c\n+++ b/lib/librte_vhost/virtio-net.c\n@@ -75,6 +75,7 @@ static struct virtio_net_config_ll *ll_root;\n \t\t\t\t(1ULL << VIRTIO_NET_F_CTRL_VQ) | \\\n \t\t\t\t(1ULL << VIRTIO_NET_F_CTRL_RX) | \\\n \t\t\t\t(1ULL << VIRTIO_NET_F_MQ) | \\\n+\t\t\t\t(1ULL << VIRTIO_F_VERSION_1) | \\\n \t\t\t\t(1ULL << VHOST_F_LOG_ALL) | \\\n \t\t\t\t(1ULL << VHOST_USER_F_PROTOCOL_FEATURES))\n static uint64_t VHOST_FEATURES = VHOST_SUPPORTED_FEATURES;\n@@ -477,17 +478,17 @@ set_features(struct vhost_device_ctx ctx, uint64_t *pu)\n \t\treturn -1;\n \n \tdev->features = *pu;\n-\tif (dev->features & (1 << VIRTIO_NET_F_MRG_RXBUF)) {\n-\t\tLOG_DEBUG(VHOST_CONFIG,\n-\t\t\t\"(%\"PRIu64\") Mergeable RX buffers enabled\\n\",\n-\t\t\tdev->device_fh);\n+\tif (dev->features &\n+\t ((1 << VIRTIO_NET_F_MRG_RXBUF) | (1ULL << VIRTIO_F_VERSION_1))) {\n \t\tvhost_hlen = sizeof(struct virtio_net_hdr_mrg_rxbuf);\n \t} else {\n-\t\tLOG_DEBUG(VHOST_CONFIG,\n-\t\t\t\"(%\"PRIu64\") Mergeable RX buffers disabled\\n\",\n-\t\t\tdev->device_fh);\n \t\tvhost_hlen = sizeof(struct virtio_net_hdr);\n \t}\n+\tLOG_DEBUG(VHOST_CONFIG,\n+ \"(%\"PRIu64\") Mergeable RX buffers %s, virtio 1 %s\\n\",\n+\t dev->device_fh,\n+ (dev->features & (1 << VIRTIO_NET_F_MRG_RXBUF)) ? \"on\" : \"off\",\n+ (dev->features & (1ULL << VIRTIO_F_VERSION_1)) ? \"on\" : \"off\");\n \n \tfor (i = 0; i < dev->virt_qp_nb; i++) {\n \t\tuint16_t base_idx = i * VIRTIO_QNUM;\n", "prefixes": [ "dpdk-dev" ] }{ "id": 7644, "url": "