get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 11002,
    "url": "http://patches.dpdk.org/api/patches/11002/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1456953598-40449-1-git-send-email-jasvinder.singh@intel.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": "<1456953598-40449-1-git-send-email-jasvinder.singh@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1456953598-40449-1-git-send-email-jasvinder.singh@intel.com",
    "date": "2016-03-02T21:19:58",
    "name": "[dpdk-dev] librte_port: fix segmentation fault for ring writer nodrop",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "c54c5ec5c37b9d79d5b03594653b56355e0dbfb7",
    "submitter": {
        "id": 285,
        "url": "http://patches.dpdk.org/api/people/285/?format=api",
        "name": "Jasvinder Singh",
        "email": "jasvinder.singh@intel.com"
    },
    "delegate": {
        "id": 1,
        "url": "http://patches.dpdk.org/api/users/1/?format=api",
        "username": "tmonjalo",
        "first_name": "Thomas",
        "last_name": "Monjalon",
        "email": "thomas@monjalon.net"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/1456953598-40449-1-git-send-email-jasvinder.singh@intel.com/mbox/",
    "series": [],
    "comments": "http://patches.dpdk.org/api/patches/11002/comments/",
    "check": "pending",
    "checks": "http://patches.dpdk.org/api/patches/11002/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 8282B29D1;\n\tWed,  2 Mar 2016 22:13:45 +0100 (CET)",
            "from mga11.intel.com (mga11.intel.com [192.55.52.93])\n\tby dpdk.org (Postfix) with ESMTP id 73A752949\n\tfor <dev@dpdk.org>; Wed,  2 Mar 2016 22:13:44 +0100 (CET)",
            "from orsmga003.jf.intel.com ([10.7.209.27])\n\tby fmsmga102.fm.intel.com with ESMTP; 02 Mar 2016 13:13:43 -0800",
            "from sie-lab-212-251.ir.intel.com (HELO\n\tsilpixa00381635.ir.intel.com) ([10.237.212.251])\n\tby orsmga003.jf.intel.com with ESMTP; 02 Mar 2016 13:13:42 -0800"
        ],
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.22,530,1449561600\"; d=\"scan'208\";a=\"756976615\"",
        "From": "Jasvinder Singh <jasvinder.singh@intel.com>",
        "To": "dev@dpdk.org",
        "Date": "Wed,  2 Mar 2016 21:19:58 +0000",
        "Message-Id": "<1456953598-40449-1-git-send-email-jasvinder.singh@intel.com>",
        "X-Mailer": "git-send-email 2.5.0",
        "Subject": "[dpdk-dev] [PATCH] librte_port: fix segmentation fault for ring\n\twriter nodrop",
        "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": "Error log:\n [APP] Initializing PIPELINE0 ...\n pipeline> [APP] Initializing PIPELINE1 ...\n [PIPELINE1] Pass-through\n [APP] Initializing PIPELINE2 ...\n [PIPELINE2] Pass-through\n Segmentation fault (core dumped)\n\nFixes: 5f4cd47309d6 (\"port: add ring writer nodrop\")\nFixes: d58f69c54172 (\"port: add ring multi reader or writer\")\n\nSigned-off-by: Jasvinder Singh <jasvinder.singh@intel.com>\n---\n lib/librte_port/rte_port_ring.c | 16 ++++++++++++----\n 1 file changed, 12 insertions(+), 4 deletions(-)",
    "diff": "diff --git a/lib/librte_port/rte_port_ring.c b/lib/librte_port/rte_port_ring.c\nindex 755dfc1..b847fea 100644\n--- a/lib/librte_port/rte_port_ring.c\n+++ b/lib/librte_port/rte_port_ring.c\n@@ -520,16 +520,20 @@ send_burst_nodrop(struct rte_port_ring_writer_nodrop *p)\n \t\t\t\tp->tx_buf_count);\n \n \t/* We sent all the packets in a first try */\n-\tif (nb_tx >= p->tx_buf_count)\n+\tif (nb_tx >= p->tx_buf_count) {\n+\t\tp->tx_buf_count = 0;\n \t\treturn;\n+\t}\n \n \tfor (i = 0; i < p->n_retries; i++) {\n \t\tnb_tx += rte_ring_sp_enqueue_burst(p->ring,\n \t\t\t\t(void **) (p->tx_buf + nb_tx), p->tx_buf_count - nb_tx);\n \n \t\t/* We sent all the packets in more than one try */\n-\t\tif (nb_tx >= p->tx_buf_count)\n+\t\tif (nb_tx >= p->tx_buf_count) {\n+\t\t\tp->tx_buf_count = 0;\n \t\t\treturn;\n+\t\t}\n \t}\n \n \t/* We didn't send the packets in maximum allowed attempts */\n@@ -549,16 +553,20 @@ send_burst_mp_nodrop(struct rte_port_ring_writer_nodrop *p)\n \t\t\t\tp->tx_buf_count);\n \n \t/* We sent all the packets in a first try */\n-\tif (nb_tx >= p->tx_buf_count)\n+\tif (nb_tx >= p->tx_buf_count) {\n+\t\tp->tx_buf_count = 0;\n \t\treturn;\n+\t}\n \n \tfor (i = 0; i < p->n_retries; i++) {\n \t\tnb_tx += rte_ring_mp_enqueue_burst(p->ring,\n \t\t\t\t(void **) (p->tx_buf + nb_tx), p->tx_buf_count - nb_tx);\n \n \t\t/* We sent all the packets in more than one try */\n-\t\tif (nb_tx >= p->tx_buf_count)\n+\t\tif (nb_tx >= p->tx_buf_count) {\n+\t\t\tp->tx_buf_count = 0;\n \t\t\treturn;\n+\t\t}\n \t}\n \n \t/* We didn't send the packets in maximum allowed attempts */\n",
    "prefixes": [
        "dpdk-dev"
    ]
}