Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/44360/?format=api
http://patches.dpdk.org/api/patches/44360/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/20180906181947.20646-7-jfreimann@redhat.com/", "project": { "id": 1, "url": "http://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": "<20180906181947.20646-7-jfreimann@redhat.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20180906181947.20646-7-jfreimann@redhat.com", "date": "2018-09-06T18:19:42", "name": "[v5,06/11] net/virtio-user: add option to use packed queues", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "434762bb6e899aaa07597aa5a40dfe10b982211b", "submitter": { "id": 745, "url": "http://patches.dpdk.org/api/people/745/?format=api", "name": "Jens Freimann", "email": "jfreimann@redhat.com" }, "delegate": { "id": 2642, "url": "http://patches.dpdk.org/api/users/2642/?format=api", "username": "mcoquelin", "first_name": "Maxime", "last_name": "Coquelin", "email": "maxime.coquelin@redhat.com" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/20180906181947.20646-7-jfreimann@redhat.com/mbox/", "series": [ { "id": 1215, "url": "http://patches.dpdk.org/api/series/1215/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=1215", "date": "2018-09-06T18:19:36", "name": "implement packed virtqueues", "version": 5, "mbox": "http://patches.dpdk.org/series/1215/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/44360/comments/", "check": "success", "checks": "http://patches.dpdk.org/api/patches/44360/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 [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id E2371568A;\n\tThu, 6 Sep 2018 20:20:23 +0200 (CEST)", "from mx1.redhat.com (mx3-rdu2.redhat.com [66.187.233.73])\n\tby dpdk.org (Postfix) with ESMTP id C0C244F9B\n\tfor <dev@dpdk.org>; Thu, 6 Sep 2018 20:20:22 +0200 (CEST)", "from smtp.corp.redhat.com\n\t(int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6])\n\t(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby mx1.redhat.com (Postfix) with ESMTPS id 5E95E80C3C31;\n\tThu, 6 Sep 2018 18:20:22 +0000 (UTC)", "from localhost (ovpn-116-129.ams2.redhat.com [10.36.116.129])\n\tby smtp.corp.redhat.com (Postfix) with ESMTPS id 3C9DB2166BA2;\n\tThu, 6 Sep 2018 18:20:18 +0000 (UTC)" ], "From": "Jens Freimann <jfreimann@redhat.com>", "To": "dev@dpdk.org", "Cc": "tiwei.bie@intel.com,\n\tmaxime.coquelin@redhat.com", "Date": "Thu, 6 Sep 2018 19:19:42 +0100", "Message-Id": "<20180906181947.20646-7-jfreimann@redhat.com>", "In-Reply-To": "<20180906181947.20646-1-jfreimann@redhat.com>", "References": "<20180906181947.20646-1-jfreimann@redhat.com>", "X-Scanned-By": "MIMEDefang 2.78 on 10.11.54.6", "X-Greylist": [ "Sender IP whitelisted, not delayed by milter-greylist-4.5.16\n\t(mx1.redhat.com [10.11.55.8]); Thu, 06 Sep 2018 18:20:22 +0000 (UTC)", "inspected by milter-greylist-4.5.16 (mx1.redhat.com\n\t[10.11.55.8]); \n\tThu, 06 Sep 2018 18:20:22 +0000 (UTC) for IP:'10.11.54.6'\n\tDOMAIN:'int-mx06.intmail.prod.int.rdu2.redhat.com'\n\tHELO:'smtp.corp.redhat.com' FROM:'jfreimann@redhat.com' RCPT:''" ], "Subject": "[dpdk-dev] [PATCH v5 06/11] net/virtio-user: add option to use\n\tpacked queues", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://mails.dpdk.org/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "From: Yuanhan Liu <yuanhan.liu@linux.intel.com>\n\nAdd option to enable packed queue support for virtio-user\ndevices.\n\nSigned-off-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>\n---\n drivers/net/virtio/virtio_user/virtio_user_dev.c | 10 ++++++++--\n drivers/net/virtio/virtio_user/virtio_user_dev.h | 2 +-\n drivers/net/virtio/virtio_user_ethdev.c | 14 +++++++++++++-\n 3 files changed, 22 insertions(+), 4 deletions(-)", "diff": "diff --git a/drivers/net/virtio/virtio_user/virtio_user_dev.c b/drivers/net/virtio/virtio_user/virtio_user_dev.c\nindex 7df600b02..9979bea0d 100644\n--- a/drivers/net/virtio/virtio_user/virtio_user_dev.c\n+++ b/drivers/net/virtio/virtio_user/virtio_user_dev.c\n@@ -372,12 +372,13 @@ virtio_user_dev_setup(struct virtio_user_dev *dev)\n \t 1ULL << VIRTIO_NET_F_GUEST_TSO4\t|\t\\\n \t 1ULL << VIRTIO_NET_F_GUEST_TSO6\t|\t\\\n \t 1ULL << VIRTIO_F_IN_ORDER\t\t|\t\\\n-\t 1ULL << VIRTIO_F_VERSION_1)\n+\t 1ULL << VIRTIO_F_VERSION_1\t\t|\t\\\n+\t 1ULL << VIRTIO_F_RING_PACKED)\n \n int\n virtio_user_dev_init(struct virtio_user_dev *dev, char *path, int queues,\n \t\t int cq, int queue_size, const char *mac, char **ifname,\n-\t\t int mrg_rxbuf, int in_order)\n+\t\t int mrg_rxbuf, int in_order, int packed_vq)\n {\n \tpthread_mutex_init(&dev->mutex, NULL);\n \tsnprintf(dev->path, PATH_MAX, \"%s\", path);\n@@ -432,6 +433,11 @@ virtio_user_dev_init(struct virtio_user_dev *dev, char *path, int queues,\n \t\tdev->unsupported_features |= (1ull << VIRTIO_F_IN_ORDER);\n \t}\n \n+\tif (packed_vq)\n+\t\tdev->device_features |= (1ull << VIRTIO_F_RING_PACKED);\n+\telse\n+\t\tdev->device_features &= ~(1ull << VIRTIO_F_RING_PACKED);\n+\n \tif (dev->mac_specified) {\n \t\tdev->device_features |= (1ull << VIRTIO_NET_F_MAC);\n \t} else {\ndiff --git a/drivers/net/virtio/virtio_user/virtio_user_dev.h b/drivers/net/virtio/virtio_user/virtio_user_dev.h\nindex d6e0e137b..7f46ba1d9 100644\n--- a/drivers/net/virtio/virtio_user/virtio_user_dev.h\n+++ b/drivers/net/virtio/virtio_user/virtio_user_dev.h\n@@ -49,7 +49,7 @@ int virtio_user_start_device(struct virtio_user_dev *dev);\n int virtio_user_stop_device(struct virtio_user_dev *dev);\n int virtio_user_dev_init(struct virtio_user_dev *dev, char *path, int queues,\n \t\t\t int cq, int queue_size, const char *mac, char **ifname,\n-\t\t\t int mrg_rxbuf, int in_order);\n+\t\t\t int mrg_rxbuf, int in_order, int packed_vq);\n void virtio_user_dev_uninit(struct virtio_user_dev *dev);\n void virtio_user_handle_cq(struct virtio_user_dev *dev, uint16_t queue_idx);\n uint8_t virtio_user_handle_mq(struct virtio_user_dev *dev, uint16_t q_pairs);\ndiff --git a/drivers/net/virtio/virtio_user_ethdev.c b/drivers/net/virtio/virtio_user_ethdev.c\nindex 525d16cab..72ac86186 100644\n--- a/drivers/net/virtio/virtio_user_ethdev.c\n+++ b/drivers/net/virtio/virtio_user_ethdev.c\n@@ -364,6 +364,8 @@ static const char *valid_args[] = {\n \tVIRTIO_USER_ARG_MRG_RXBUF,\n #define VIRTIO_USER_ARG_IN_ORDER \"in_order\"\n \tVIRTIO_USER_ARG_IN_ORDER,\n+#define VIRTIO_USER_ARG_PACKED_VQ \"packed_vq\"\n+\tVIRTIO_USER_ARG_PACKED_VQ,\n \tNULL\n };\n \n@@ -473,6 +475,7 @@ virtio_user_pmd_probe(struct rte_vdev_device *dev)\n \tchar *ifname = NULL;\n \tchar *mac_addr = NULL;\n \tint ret = -1;\n+\tuint64_t packed_vq = 0;\n \n \tkvlist = rte_kvargs_parse(rte_vdev_device_args(dev), valid_args);\n \tif (!kvlist) {\n@@ -556,6 +559,15 @@ virtio_user_pmd_probe(struct rte_vdev_device *dev)\n \t\tcq = 1;\n \t}\n \n+\tif (rte_kvargs_count(kvlist, VIRTIO_USER_ARG_PACKED_VQ) == 1) {\n+\t\tif (rte_kvargs_process(kvlist, VIRTIO_USER_ARG_PACKED_VQ,\n+\t\t\t\t &get_integer_arg, &packed_vq) < 0) {\n+\t\t\tPMD_INIT_LOG(ERR, \"error to parse %s\",\n+\t\t\t\t VIRTIO_USER_ARG_PACKED_VQ);\n+\t\t\tgoto end;\n+\t\t}\n+\t}\n+\n \tif (queues > 1 && cq == 0) {\n \t\tPMD_INIT_LOG(ERR, \"multi-q requires ctrl-q\");\n \t\tgoto end;\n@@ -603,7 +615,7 @@ virtio_user_pmd_probe(struct rte_vdev_device *dev)\n \t\t\tvu_dev->is_server = false;\n \t\tif (virtio_user_dev_init(hw->virtio_user_dev, path, queues, cq,\n \t\t\t\t queue_size, mac_addr, &ifname, mrg_rxbuf,\n-\t\t\t\t in_order) < 0) {\n+\t\t\t\t in_order, packed_vq) < 0) {\n \t\t\tPMD_INIT_LOG(ERR, \"virtio_user_dev_init fails\");\n \t\t\tvirtio_user_eth_dev_free(eth_dev);\n \t\t\tgoto end;\n", "prefixes": [ "v5", "06/11" ] }{ "id": 44360, "url": "