get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 74630,
    "url": "https://patches.dpdk.org/api/patches/74630/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20200723053801.3616928-1-patrick.fu@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": "<20200723053801.3616928-1-patrick.fu@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20200723053801.3616928-1-patrick.fu@intel.com",
    "date": "2020-07-23T05:38:01",
    "name": "[v1] vhost: fix vring disable fail in async transfer",
    "commit_ref": null,
    "pull_url": null,
    "state": "rejected",
    "archived": true,
    "hash": "43e3c6b526500db34fc76b6d0a534639220cbf0a",
    "submitter": {
        "id": 1781,
        "url": "https://patches.dpdk.org/api/people/1781/?format=api",
        "name": "Patrick Fu",
        "email": "patrick.fu@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/20200723053801.3616928-1-patrick.fu@intel.com/mbox/",
    "series": [
        {
            "id": 11245,
            "url": "https://patches.dpdk.org/api/series/11245/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=11245",
            "date": "2020-07-23T05:38:01",
            "name": "[v1] vhost: fix vring disable fail in async transfer",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/11245/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/74630/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/74630/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 889C9A0526;\n\tThu, 23 Jul 2020 07:40:38 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id CE45B1BF94;\n\tThu, 23 Jul 2020 07:40:37 +0200 (CEST)",
            "from mga18.intel.com (mga18.intel.com [134.134.136.126])\n by dpdk.org (Postfix) with ESMTP id A4CF01BE90\n for <dev@dpdk.org>; Thu, 23 Jul 2020 07:40:36 +0200 (CEST)",
            "from orsmga002.jf.intel.com ([10.7.209.21])\n by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 22 Jul 2020 22:40:34 -0700",
            "from npg-dpdk-patrickfu-casc2.sh.intel.com ([10.67.119.92])\n by orsmga002.jf.intel.com with ESMTP; 22 Jul 2020 22:40:33 -0700"
        ],
        "IronPort-SDR": [
            "\n LeP8qf1M+1nyqDqK6LDZHzIKt3slcChSGdPubOzLEf4a27YZbEK6BhU2DCoRtZEfXl1+MR8Dol\n OYNZMdANUQug==",
            "\n uzRNZ/k0dG6JZ1erY51FxC5KrW1tBN6ReQAxMQ4iWm9Nbv+GtCnLwudtK0wJybsM4nAG0kh7ts\n fHQQUyJ2XJHw=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9690\"; a=\"137967597\"",
            "E=Sophos;i=\"5.75,385,1589266800\"; d=\"scan'208\";a=\"137967597\"",
            "E=Sophos;i=\"5.75,385,1589266800\"; d=\"scan'208\";a=\"302189972\""
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "From": "patrick.fu@intel.com",
        "To": "dev@dpdk.org,\n\tmaxime.coquelin@redhat.com,\n\tchenbo.xia@intel.com",
        "Cc": "Patrick Fu <patrick.fu@intel.com>",
        "Date": "Thu, 23 Jul 2020 13:38:01 +0800",
        "Message-Id": "<20200723053801.3616928-1-patrick.fu@intel.com>",
        "X-Mailer": "git-send-email 2.18.4",
        "Subject": "[dpdk-dev] [PATCH v1] vhost: fix vring disable fail in async\n\ttransfer",
        "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": "From: Patrick Fu <patrick.fu@intel.com>\n\nAsync inflight packets is checked when front end virtio requests to\ndisable vring. If inflight packets exists, vring disabling will fail.\nHowever, there is no good way for application to get notified before\nvring is disabled and properly complete inflight packets. This patch\nmoves the inflight packets check from vring disabling time to the vring\nenabling time, so that applications have chances to drain out pending\npackets.\n\nFixes: 78639d54563a (\"vhost: introduce async enqueue registration API\")\n\nSigned-off-by: Patrick Fu <patrick.fu@intel.com>\n---\n lib/librte_vhost/vhost_user.c | 4 ++--\n 1 file changed, 2 insertions(+), 2 deletions(-)",
    "diff": "diff --git a/lib/librte_vhost/vhost_user.c b/lib/librte_vhost/vhost_user.c\nindex 9ddeae362..36da1380a 100644\n--- a/lib/librte_vhost/vhost_user.c\n+++ b/lib/librte_vhost/vhost_user.c\n@@ -2038,9 +2038,9 @@ vhost_user_set_vring_enable(struct virtio_net **pdev,\n \t\t\"set queue enable: %d to qp idx: %d\\n\",\n \t\tenable, index);\n \n-\tif (!enable && dev->virtqueue[index]->async_registered) {\n+\tif (enable && dev->virtqueue[index]->async_registered) {\n \t\tif (dev->virtqueue[index]->async_pkts_inflight_n) {\n-\t\t\tVHOST_LOG_CONFIG(ERR, \"failed to disable vring. \"\n+\t\t\tVHOST_LOG_CONFIG(ERR, \"failed to enable vring. \"\n \t\t\t\"async inflight packets must be completed first\\n\");\n \t\t\treturn RTE_VHOST_MSG_RESULT_ERR;\n \t\t}\n",
    "prefixes": [
        "v1"
    ]
}