get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 64127,
    "url": "https://patches.dpdk.org/api/patches/64127/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20191225142445.66106-1-jin.yu@intel.com/",
    "project": {
        "id": 1,
        "url": "https://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": "<20191225142445.66106-1-jin.yu@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20191225142445.66106-1-jin.yu@intel.com",
    "date": "2019-12-25T14:24:45",
    "name": "vhost: add protocol feature check",
    "commit_ref": null,
    "pull_url": null,
    "state": "rejected",
    "archived": true,
    "hash": "a69cbfea8ee04c6185023a40a476908d527829ab",
    "submitter": {
        "id": 1265,
        "url": "https://patches.dpdk.org/api/people/1265/?format=api",
        "name": "Jin Yu",
        "email": "jin.yu@intel.com"
    },
    "delegate": {
        "id": 2642,
        "url": "https://patches.dpdk.org/api/users/2642/?format=api",
        "username": "mcoquelin",
        "first_name": "Maxime",
        "last_name": "Coquelin",
        "email": "maxime.coquelin@redhat.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20191225142445.66106-1-jin.yu@intel.com/mbox/",
    "series": [
        {
            "id": 7945,
            "url": "https://patches.dpdk.org/api/series/7945/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=7945",
            "date": "2019-12-25T14:24:45",
            "name": "vhost: add protocol feature check",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/7945/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/64127/comments/",
    "check": "fail",
    "checks": "https://patches.dpdk.org/api/patches/64127/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@inbox.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 7881DA04F8;\n\tWed, 25 Dec 2019 07:46:03 +0100 (CET)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 9CF711BE8A;\n\tWed, 25 Dec 2019 07:46:02 +0100 (CET)",
            "from mga06.intel.com (mga06.intel.com [134.134.136.31])\n by dpdk.org (Postfix) with ESMTP id 92F3F1BE85;\n Wed, 25 Dec 2019 07:46:00 +0100 (CET)",
            "from orsmga008.jf.intel.com ([10.7.209.65])\n by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n 24 Dec 2019 22:45:59 -0800",
            "from storage36.sh.intel.com ([10.67.110.177])\n by orsmga008.jf.intel.com with ESMTP; 24 Dec 2019 22:45:58 -0800"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.69,353,1571727600\"; d=\"scan'208\";a=\"212053288\"",
        "From": "Jin Yu <jin.yu@intel.com>",
        "To": "Maxime Coquelin <maxime.coquelin@redhat.com>,\n Tiwei Bie <tiwei.bie@intel.com>, Zhihong Wang <zhihong.wang@intel.com>",
        "Cc": "dev@dpdk.org,\n\tJin Yu <jin.yu@intel.com>,\n\tstable@dpdk.org",
        "Date": "Wed, 25 Dec 2019 22:24:45 +0800",
        "Message-Id": "<20191225142445.66106-1-jin.yu@intel.com>",
        "X-Mailer": "git-send-email 2.17.2",
        "Subject": "[dpdk-dev] [PATCH] vhost: add protocol feature check",
        "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 <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 <mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "Add VHOST_USER_PROTOCOL_F_INFLIGHT_SHMFD check in\ngetting inflight ring functions.\n\nFixes: 4d891f77ddfa (\"vhost: add APIs to get inflight ring\")\nCc: stable@dpdk.org\n\nSigned-off-by: Jin Yu <jin.yu@intel.com>\n---\n lib/librte_vhost/vhost.c | 8 ++++++++\n 1 file changed, 8 insertions(+)",
    "diff": "diff --git a/lib/librte_vhost/vhost.c b/lib/librte_vhost/vhost.c\nindex 1cbe948f7..dfb71732b 100644\n--- a/lib/librte_vhost/vhost.c\n+++ b/lib/librte_vhost/vhost.c\n@@ -862,6 +862,10 @@ rte_vhost_get_vhost_ring_inflight(int vid, uint16_t vring_idx,\n \tif (unlikely(!dev))\n \t\treturn -1;\n \n+\tif (unlikely(!(dev->protocol_features &\n+\t    (1ULL << VHOST_USER_PROTOCOL_F_INFLIGHT_SHMFD))))\n+\t\treturn 0;\n+\n \tif (vring_idx >= VHOST_MAX_VRING)\n \t\treturn -1;\n \n@@ -1431,6 +1435,10 @@ rte_vhost_get_vring_base_from_inflight(int vid,\n \tif (dev == NULL || last_avail_idx == NULL || last_used_idx == NULL)\n \t\treturn -1;\n \n+\tif (unlikely(!(dev->protocol_features &\n+\t    (1ULL << VHOST_USER_PROTOCOL_F_INFLIGHT_SHMFD))))\n+\t\treturn 0;\n+\n \tif (!vq_is_packed(dev))\n \t\treturn -1;\n \n",
    "prefixes": []
}