Show a patch.

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

{
    "id": 43323,
    "url": "http://patches.dpdk.org/api/patches/43323/",
    "web_url": "http://patches.dpdk.org/patch/43323/",
    "project": {
        "id": 1,
        "url": "http://patches.dpdk.org/api/projects/1/",
        "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"
    },
    "msgid": "<20180724210853.22767-2-stephen@networkplumber.org>",
    "date": "2018-07-24T21:08:50",
    "name": "[1/4] netvsc: change rx descriptor setup and sizing",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "cb3bef41f6c736a11b2213e57b0bb67e69d94160",
    "submitter": {
        "id": 27,
        "url": "http://patches.dpdk.org/api/people/27/",
        "name": "Stephen Hemminger",
        "email": "stephen@networkplumber.org"
    },
    "delegate": {
        "id": 319,
        "url": "http://patches.dpdk.org/api/users/319/",
        "username": "fyigit",
        "first_name": "Ferruh",
        "last_name": "Yigit",
        "email": "ferruh.yigit@intel.com"
    },
    "mbox": "http://patches.dpdk.org/patch/43323/mbox/",
    "series": [
        {
            "id": 748,
            "url": "http://patches.dpdk.org/api/series/748/",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=748",
            "date": "2018-07-24T21:08:49",
            "name": "netvsc PMD performance fixes",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/748/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/43323/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/43323/checks/",
    "tags": {},
    "headers": {
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "Return-Path": "<dev-bounces@dpdk.org>",
        "To": "dev@dpdk.org",
        "X-Google-Smtp-Source": "AAOMgpfk7AEWk7GMo0EgKSFWFxgxvIM/XBnYAMvPp6W2F4B8d13PENMbdOXZ5WbnnhEvRaD9PBoGAg==",
        "Message-Id": "<20180724210853.22767-2-stephen@networkplumber.org>",
        "X-Mailer": "git-send-email 2.18.0",
        "X-Gm-Message-State": "AOUpUlFjvhxUXXgnzgubxfZXVdo7LHO517RXgctT4oAj4dpp87VFAvN9\n\t6zPFSHHJVRgLSIsl4kw09XsehBVSvT4=",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=networkplumber-org.20150623.gappssmtp.com; s=20150623;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references;\n\tbh=pw16iFMvloPDZZFKtnXHtLMyrJCAFAY1nt2nTDVz3V0=;\n\tb=dn82qQAVsMEwqOXhUnF2QPUQs12eSNhP9Ia/pgqCe6OBEKMQOTsee3lpxnqaGTcb7K\n\th3FX9m/bYwRDoMFtt0Pr+2jKMGuq000HFc9tZc/a/LgEUtLKxxPNf522HSWbODLC6gxG\n\tr4vDRcgg7zlCH6p/+QpJwvTZisS4vadWuyfBUdV/iAuwZPffqah7g3102/XxiWxa6/it\n\toz70S3iLDJrqUNIHlGkl84S07PwblM4U3E/3iIIlQY7tAFUoX1hUzcNmGOyI9ydNPSV6\n\twyl+2M15orbnMbg6ICQJeU11fVbSb3uUKCkgCNaiuBW13BcdhTFpyg1y1hDor4oIkhRI\n\t52vw==",
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "X-BeenThere": "dev@dpdk.org",
        "Received": [
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 0B642322C;\n\tTue, 24 Jul 2018 23:09:09 +0200 (CEST)",
            "from mail-pl0-f66.google.com (mail-pl0-f66.google.com\n\t[209.85.160.66]) by dpdk.org (Postfix) with ESMTP id E9B9398\n\tfor <dev@dpdk.org>; Tue, 24 Jul 2018 23:09:03 +0200 (CEST)",
            "by mail-pl0-f66.google.com with SMTP id w3-v6so2296505plq.2\n\tfor <dev@dpdk.org>; Tue, 24 Jul 2018 14:09:03 -0700 (PDT)",
            "from xeon-e3.wavecable.com (204-195-22-127.wavecable.com.\n\t[204.195.22.127]) by smtp.gmail.com with ESMTPSA id\n\td11-v6sm16921161pfo.135.2018.07.24.14.09.01\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\n\tTue, 24 Jul 2018 14:09:01 -0700 (PDT)"
        ],
        "Subject": "[dpdk-dev] [PATCH 1/4] netvsc: change rx descriptor setup and sizing",
        "In-Reply-To": "<20180724210853.22767-1-stephen@networkplumber.org>",
        "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-Post": "<mailto:dev@dpdk.org>",
        "Cc": "Stephen Hemminger <stephen@networkplumber.org>,\n\tStephen Hemminger <sthemmin@microsoft.com>",
        "Precedence": "list",
        "From": "Stephen Hemminger <stephen@networkplumber.org>",
        "X-Received": "by 2002:a17:902:5381:: with SMTP id\n\tc1-v6mr18155011pli.137.1532466542762; \n\tTue, 24 Jul 2018 14:09:02 -0700 (PDT)",
        "References": "<20180724210853.22767-1-stephen@networkplumber.org>",
        "X-Original-To": "patchwork@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>",
        "Errors-To": "dev-bounces@dpdk.org",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "Delivered-To": "patchwork@dpdk.org",
        "Date": "Tue, 24 Jul 2018 14:08:50 -0700",
        "X-Mailman-Version": "2.1.15",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references;\n\tbh=pw16iFMvloPDZZFKtnXHtLMyrJCAFAY1nt2nTDVz3V0=;\n\tb=dm6KkdtXgi8a6n2a/Na/NgXJb7ucnbEx38A7i9dsz7H8XTbOKJsBA3oE2ShcztT/hK\n\tAknnkB7FuBfOPIQ/cLfCOXhkfh6w2ZPsUFMwpTOzkCx0QvgGb37ciwCbCJnXy8Q0v5GN\n\tQj1Q1RL/pOuDDcs0MpJ5LErPkBLfIvVFcyGwSxqM50wl+IbxhL1otnWgKFfvCGaa7+hP\n\tdRitXGkFOx0tIcNnfkoGFKEYAINJfDxZ8dMBT+zjuoJzLPrdJhn7QUEiVfp0MddxlEPd\n\tI4q4BYHqhwt5nGlQJsZ2+omx1IXypgtKh26bb4oX5hW3FX5yT2YjZM5Hb+p2b6718lKh\n\tFxKg=="
    },
    "content": "Increase the size of the ring used to hold mbuf's received\nbut not processed.  The default is now based off the size\nof thw receive mbuf pool not the number of sections from the host.\n\nSigned-off-by: Stephen Hemminger <sthemmin@microsoft.com>\n---\n drivers/net/netvsc/hn_rxtx.c | 24 +++++++-----------------\n 1 file changed, 7 insertions(+), 17 deletions(-)",
    "diff": "diff --git a/drivers/net/netvsc/hn_rxtx.c b/drivers/net/netvsc/hn_rxtx.c\nindex 6d2f41c4c011..9a2dd9cb1beb 100644\n--- a/drivers/net/netvsc/hn_rxtx.c\n+++ b/drivers/net/netvsc/hn_rxtx.c\n@@ -728,18 +728,12 @@ hn_dev_rx_queue_setup(struct rte_eth_dev *dev,\n \t\t      struct rte_mempool *mp)\n {\n \tstruct hn_data *hv = dev->data->dev_private;\n-\tuint32_t qmax = hv->rxbuf_section_cnt;\n \tchar ring_name[RTE_RING_NAMESIZE];\n \tstruct hn_rx_queue *rxq;\n \tunsigned int count;\n-\tsize_t size;\n-\tint err = -ENOMEM;\n \n \tPMD_INIT_FUNC_TRACE();\n \n-\tif (nb_desc == 0 || nb_desc > qmax)\n-\t\tnb_desc = qmax;\n-\n \tif (queue_idx == 0) {\n \t\trxq = hv->primary;\n \t} else {\n@@ -749,14 +743,9 @@ hn_dev_rx_queue_setup(struct rte_eth_dev *dev,\n \t}\n \n \trxq->mb_pool = mp;\n-\n-\tcount = rte_align32pow2(nb_desc);\n-\tsize = sizeof(struct rte_ring) + count * sizeof(void *);\n-\trxq->rx_ring = rte_malloc_socket(\"RX_RING\", size,\n-\t\t\t\t\t RTE_CACHE_LINE_SIZE,\n-\t\t\t\t\t socket_id);\n-\tif (!rxq->rx_ring)\n-\t\tgoto fail;\n+\tcount = rte_mempool_avail_count(mp) / dev->data->nb_rx_queues;\n+\tif (nb_desc == 0 || nb_desc > count)\n+\t\tnb_desc = count;\n \n \t/*\n \t * Staging ring from receive event logic to rx_pkts.\n@@ -765,9 +754,10 @@ hn_dev_rx_queue_setup(struct rte_eth_dev *dev,\n \t */\n \tsnprintf(ring_name, sizeof(ring_name),\n \t\t \"hn_rx_%u_%u\", dev->data->port_id, queue_idx);\n-\terr = rte_ring_init(rxq->rx_ring, ring_name,\n-\t\t\t    count, 0);\n-\tif (err)\n+\trxq->rx_ring = rte_ring_create(ring_name,\n+\t\t\t\t       rte_align32pow2(nb_desc),\n+\t\t\t\t       socket_id, 0);\n+\tif (!rxq->rx_ring)\n \t\tgoto fail;\n \n \tdev->data->rx_queues[queue_idx] = rxq;\n",
    "prefixes": [
        "1/4"
    ]
}