Show a patch.

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

{
    "id": 74514,
    "url": "https://patches.dpdk.org/api/patches/74514/",
    "web_url": "https://patches.dpdk.org/patch/74514/",
    "project": {
        "id": 1,
        "url": "https://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": "<20200721033557.3372262-1-patrick.fu@intel.com>",
    "date": "2020-07-21T03:35:57",
    "name": "[v2] vhost: fix missing virtqueue status check in async path",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "88d9845f2d3478adaaae70c0de19cecf6a6bf0e7",
    "submitter": {
        "id": 1781,
        "url": "https://patches.dpdk.org/api/people/1781/",
        "name": "Patrick Fu",
        "email": "patrick.fu@intel.com"
    },
    "delegate": {
        "id": 319,
        "url": "https://patches.dpdk.org/api/users/319/",
        "username": "fyigit",
        "first_name": "Ferruh",
        "last_name": "Yigit",
        "email": "ferruh.yigit@intel.com"
    },
    "mbox": "https://patches.dpdk.org/patch/74514/mbox/",
    "series": [
        {
            "id": 11185,
            "url": "https://patches.dpdk.org/api/series/11185/",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=11185",
            "date": "2020-07-21T03:35:57",
            "name": "[v2] vhost: fix missing virtqueue status check in async path",
            "version": 2,
            "mbox": "https://patches.dpdk.org/series/11185/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/74514/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/74514/checks/",
    "tags": {},
    "headers": {
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>",
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9688\"; a=\"168196719\"",
            "E=Sophos;i=\"5.75,377,1589266800\"; d=\"scan'208\";a=\"168196719\"",
            "E=Sophos;i=\"5.75,377,1589266800\"; d=\"scan'208\";a=\"487936819\""
        ],
        "IronPort-SDR": [
            "\n xLdo/JvfiffLPSI5AbBrGOOWIt38QiwGu7FMQoTiOsB4BTUw7RROOnKUA8lyHe07W25LUVTh0S\n Lj8SZ0MP9h5g==",
            "\n oPRk03PgfeKDv/fGxn/NHBPFnLcjrJTH6tgXTE4pO24dVqsQShkGJTgdUrfALU8Ov/ppI3v1Ud\n kn1n1WqBBI/w=="
        ],
        "X-Amp-File-Uploaded": "False",
        "Precedence": "list",
        "X-Mailman-Version": "2.1.15",
        "X-Original-To": "patchwork@inbox.dpdk.org",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "X-BeenThere": "dev@dpdk.org",
        "References": "<20200716153010.2894802-1-patrick.fu@intel.com>",
        "Subject": "[dpdk-dev] [PATCH v2] vhost: fix missing virtqueue status check in\n\tasync path",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>",
        "Delivered-To": "patchwork@inbox.dpdk.org",
        "Received": [
            "from dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 728DEA0526;\n\tTue, 21 Jul 2020 05:38:01 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id E6CEE1C012;\n\tTue, 21 Jul 2020 05:37:59 +0200 (CEST)",
            "from mga01.intel.com (mga01.intel.com [192.55.52.88])\n by dpdk.org (Postfix) with ESMTP id 930CF1C00D\n for <dev@dpdk.org>; Tue, 21 Jul 2020 05:37:58 +0200 (CEST)",
            "from fmsmga005.fm.intel.com ([10.253.24.32])\n by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 20 Jul 2020 20:37:57 -0700",
            "from npg-dpdk-patrickfu-casc2.sh.intel.com ([10.67.119.92])\n by fmsmga005.fm.intel.com with ESMTP; 20 Jul 2020 20:37:56 -0700"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "X-Mailer": "git-send-email 2.18.4",
        "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "X-ExtLoop1": "1",
        "Date": "Tue, 21 Jul 2020 11:35:57 +0800",
        "To": "dev@dpdk.org,\n\tmaxime.coquelin@redhat.com,\n\tchenbo.xia@intel.com",
        "From": "patrick.fu@intel.com",
        "In-Reply-To": "<20200716153010.2894802-1-patrick.fu@intel.com>",
        "Cc": "Patrick Fu <patrick.fu@intel.com>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Message-Id": "<20200721033557.3372262-1-patrick.fu@intel.com>",
        "Return-Path": "<dev-bounces@dpdk.org>"
    },
    "content": "From: Patrick Fu <patrick.fu@intel.com>\n\nVring should not be touched if vq is disabled. This patch adds the vq\nstatus check in async enqueue polling to avoid accessing to a disabled\nqueue.\n\nFixes: cd6760da1076 (\"vhost: introduce async enqueue for split ring\")\n\nSigned-off-by: Patrick Fu <patrick.fu@intel.com>\n---\nv2:\n revise commit title\n\n lib/librte_vhost/virtio_net.c | 8 +++++---\n 1 file changed, 5 insertions(+), 3 deletions(-)",
    "diff": "diff --git a/lib/librte_vhost/virtio_net.c b/lib/librte_vhost/virtio_net.c\nindex 1d0be3dd4..b197d76d3 100644\n--- a/lib/librte_vhost/virtio_net.c\n+++ b/lib/librte_vhost/virtio_net.c\n@@ -1686,9 +1686,11 @@ uint16_t rte_vhost_poll_enqueue_completed(int vid, uint16_t queue_id,\n \n \tif (n_pkts_put) {\n \t\tvq->async_pkts_inflight_n -= n_pkts_put;\n-\t\t__atomic_add_fetch(&vq->used->idx, n_descs, __ATOMIC_RELEASE);\n-\n-\t\tvhost_vring_call_split(dev, vq);\n+\t\tif (likely(vq->enabled && vq->access_ok)) {\n+\t\t\t__atomic_add_fetch(&vq->used->idx,\n+\t\t\t\t\tn_descs, __ATOMIC_RELEASE);\n+\t\t\tvhost_vring_call_split(dev, vq);\n+\t\t}\n \t}\n \n \tif (start_idx + n_pkts_put <= vq_size) {\n",
    "prefixes": [
        "v2"
    ]
}