get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 56053,
    "url": "http://patches.dpdk.org/api/patches/56053/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1562204319-15833-1-git-send-email-andy.pei@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": "<1562204319-15833-1-git-send-email-andy.pei@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1562204319-15833-1-git-send-email-andy.pei@intel.com",
    "date": "2019-07-04T01:38:39",
    "name": "[v4] net/i40e: fix core dumped when setting txq or rxq to 0 in VF",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "b1575fa7dd352b9af6e5a7e677e40dcfcf628db2",
    "submitter": {
        "id": 1185,
        "url": "http://patches.dpdk.org/api/people/1185/?format=api",
        "name": "Pei, Andy",
        "email": "andy.pei@intel.com"
    },
    "delegate": {
        "id": 1540,
        "url": "http://patches.dpdk.org/api/users/1540/?format=api",
        "username": "qzhan15",
        "first_name": "Qi",
        "last_name": "Zhang",
        "email": "qi.z.zhang@intel.com"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/1562204319-15833-1-git-send-email-andy.pei@intel.com/mbox/",
    "series": [
        {
            "id": 5322,
            "url": "http://patches.dpdk.org/api/series/5322/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=5322",
            "date": "2019-07-04T01:38:39",
            "name": "[v4] net/i40e: fix core dumped when setting txq or rxq to 0 in VF",
            "version": 4,
            "mbox": "http://patches.dpdk.org/series/5322/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/56053/comments/",
    "check": "fail",
    "checks": "http://patches.dpdk.org/api/patches/56053/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 DA704235;\n\tThu,  4 Jul 2019 03:45:31 +0200 (CEST)",
            "from mga17.intel.com (mga17.intel.com [192.55.52.151])\n\tby dpdk.org (Postfix) with ESMTP id 00359235;\n\tThu,  4 Jul 2019 03:45:29 +0200 (CEST)",
            "from fmsmga005.fm.intel.com ([10.253.24.32])\n\tby fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t03 Jul 2019 18:45:23 -0700",
            "from dipei-st-npg.sh.intel.com ([10.67.110.220])\n\tby fmsmga005.fm.intel.com with ESMTP; 03 Jul 2019 18:45:21 -0700"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.63,449,1557212400\"; d=\"scan'208\";a=\"362814304\"",
        "From": "Andy Pei <andy.pei@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "andy.pei@intel.com, helin.zhang@intel.com, stable@dpdk.org,\n\troy.fan.zhang@intel.com, qi.z.zhang@intel.com, jingjing.wu@intel.com, \n\tbeilei.xing@intel.com, ferruh.yigit@intel.com, rosen.xu@intel.com,\n\txiaolong.ye@intel.com",
        "Date": "Thu,  4 Jul 2019 09:38:39 +0800",
        "Message-Id": "<1562204319-15833-1-git-send-email-andy.pei@intel.com>",
        "X-Mailer": "git-send-email 1.8.3.1",
        "In-Reply-To": "<1561108988-217617-1-git-send-email-andy.pei@intel.com>",
        "References": "<1561108988-217617-1-git-send-email-andy.pei@intel.com>",
        "Subject": "[dpdk-dev] [PATCH v4] net/i40e: fix core dumped when setting txq or\n\trxq to 0 in VF",
        "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": "Testpmd would stuck and result in core dump when user specifies an\ninvalid VF queue number, for example when setting txq or rxq to 0.\nWhen txq or rxq is set to 0, pointer of pointer rxq or txq in\nfunction i40evf_configure_vsi_queues is NULL. The usage of txq[i]\nor rxq[0] is valid. This patch fixes this issue.\n\nFixes: d6b19729093e (\"i40evf: support configurable crc stripping\")\nCc: helin.zhang@intel.com\nCc: stable@dpdk.org\n\nSigned-off-by: Andy Pei <andy.pei@intel.com>\n---\nv4:\n* use \"txq ? txq[i] : txq\" to avoid some duplicate.\n* a more specific description of the issue in the commit message.\n\nv3:\n* no need to use a new line for each parameter when call envoke a\n  function. A new line comes when the current line is more than\n  80 characters.\n\n    v2:\n* modify commit meaasage so one line contains not more than 72\n  characters.\n* delete unnecessary parentheses around 'queue_id < nb_txq'\n* delete unnecessary parentheses around 'queue_id < nb_rxq'\n\nCc: roy.fan.zhang@intel.com\nCc: qi.z.zhang@intel.com\nCc: jingjing.wu@intel.com\nCc: beilei.xing@intel.com\nCc: ferruh.yigit@intel.com\nCc: rosen.xu@intel.com\nCc: xiaolong.ye@intel.com\n\n drivers/net/i40e/i40e_ethdev_vf.c | 9 +++++----\n 1 file changed, 5 insertions(+), 4 deletions(-)",
    "diff": "diff --git a/drivers/net/i40e/i40e_ethdev_vf.c b/drivers/net/i40e/i40e_ethdev_vf.c\nindex d922a84..5be32b0 100644\n--- a/drivers/net/i40e/i40e_ethdev_vf.c\n+++ b/drivers/net/i40e/i40e_ethdev_vf.c\n@@ -573,7 +573,7 @@ struct rte_i40evf_xstats_name_off {\n {\n \ttxq_info->vsi_id = vsi_id;\n \ttxq_info->queue_id = queue_id;\n-\tif (queue_id < nb_txq) {\n+\tif (queue_id < nb_txq && txq) {\n \t\ttxq_info->ring_len = txq->nb_tx_desc;\n \t\ttxq_info->dma_ring_addr = txq->tx_ring_phys_addr;\n \t}\n@@ -590,7 +590,7 @@ struct rte_i40evf_xstats_name_off {\n \trxq_info->vsi_id = vsi_id;\n \trxq_info->queue_id = queue_id;\n \trxq_info->max_pkt_size = max_pkt_size;\n-\tif (queue_id < nb_rxq) {\n+\tif (queue_id < nb_rxq && rxq) {\n \t\trxq_info->ring_len = rxq->nb_rx_desc;\n \t\trxq_info->dma_ring_addr = rxq->rx_ring_phys_addr;\n \t\trxq_info->databuffer_size =\n@@ -623,10 +623,11 @@ struct rte_i40evf_xstats_name_off {\n \n \tfor (i = 0, vc_qpi = vc_vqci->qpair; i < nb_qp; i++, vc_qpi++) {\n \t\ti40evf_fill_virtchnl_vsi_txq_info(&vc_qpi->txq,\n-\t\t\tvc_vqci->vsi_id, i, dev->data->nb_tx_queues, txq[i]);\n+\t\t\tvc_vqci->vsi_id, i, dev->data->nb_tx_queues,\n+\t\t\ttxq ? txq[i] : NULL);\n \t\ti40evf_fill_virtchnl_vsi_rxq_info(&vc_qpi->rxq,\n \t\t\tvc_vqci->vsi_id, i, dev->data->nb_rx_queues,\n-\t\t\t\t\tvf->max_pkt_len, rxq[i]);\n+\t\t\tvf->max_pkt_len, rxq ? rxq[i] : NULL);\n \t}\n \tmemset(&args, 0, sizeof(args));\n \targs.ops = VIRTCHNL_OP_CONFIG_VSI_QUEUES;\n",
    "prefixes": [
        "v4"
    ]
}