get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 42975,
    "url": "http://patches.dpdk.org/api/patches/42975/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20180712140144.18146-3-qi.z.zhang@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": "<20180712140144.18146-3-qi.z.zhang@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20180712140144.18146-3-qi.z.zhang@intel.com",
    "date": "2018-07-12T14:01:42",
    "name": "[2/4] bus/pci: fix PCI address compare",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "c4483b993ec3b3a255a142e0dedc48a0ece617c5",
    "submitter": {
        "id": 504,
        "url": "http://patches.dpdk.org/api/people/504/?format=api",
        "name": "Qi Zhang",
        "email": "qi.z.zhang@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/20180712140144.18146-3-qi.z.zhang@intel.com/mbox/",
    "series": [
        {
            "id": 549,
            "url": "http://patches.dpdk.org/api/series/549/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=549",
            "date": "2018-07-12T14:01:40",
            "name": "couple hotplug fix",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/549/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/42975/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/42975/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 715531B463;\n\tThu, 12 Jul 2018 16:01:15 +0200 (CEST)",
            "from mga04.intel.com (mga04.intel.com [192.55.52.120])\n\tby dpdk.org (Postfix) with ESMTP id 347261B43E;\n\tThu, 12 Jul 2018 16:01:09 +0200 (CEST)",
            "from orsmga008.jf.intel.com ([10.7.209.65])\n\tby fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t12 Jul 2018 07:01:08 -0700",
            "from dpdk51.sh.intel.com ([10.67.110.190])\n\tby orsmga008.jf.intel.com with ESMTP; 12 Jul 2018 07:01:07 -0700"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.51,343,1526367600\"; d=\"scan'208\";a=\"56361037\"",
        "From": "Qi Zhang <qi.z.zhang@intel.com>",
        "To": "thomas@monjalon.net, anatoly.burakov@intel.com, gaetan.rivet@6wind.com",
        "Cc": "dev@dpdk.org,\n\tQi Zhang <qi.z.zhang@intel.com>,\n\tstable@dpdk.org",
        "Date": "Thu, 12 Jul 2018 22:01:42 +0800",
        "Message-Id": "<20180712140144.18146-3-qi.z.zhang@intel.com>",
        "X-Mailer": "git-send-email 2.13.6",
        "In-Reply-To": "<20180712140144.18146-1-qi.z.zhang@intel.com>",
        "References": "<20180712140144.18146-1-qi.z.zhang@intel.com>",
        "Subject": "[dpdk-dev] [PATCH 2/4] bus/pci: fix PCI address compare",
        "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": "When use memcmp to compare two PCI address, sizeof(struct rte_pci_addr)\nis 4 bytes aligned, and it is 8. While only 7 byte of struct rte_pci_addr\nis valid. So compare the 8th byte will cause the unexpected result, which\nhappens when repeatedly attach/detach a device.\n\nFixes: 94c0776b1bad (\"vfio: support hotplug\")\nCc: stable@dpdk.org\n\nSigned-off-by: Qi Zhang <qi.z.zhang@intel.com>\n---\n drivers/bus/pci/linux/pci_vfio.c | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)",
    "diff": "diff --git a/drivers/bus/pci/linux/pci_vfio.c b/drivers/bus/pci/linux/pci_vfio.c\nindex aeeaa9ed8..933b95540 100644\n--- a/drivers/bus/pci/linux/pci_vfio.c\n+++ b/drivers/bus/pci/linux/pci_vfio.c\n@@ -642,7 +642,7 @@ pci_vfio_unmap_resource(struct rte_pci_device *dev)\n \tvfio_res_list = RTE_TAILQ_CAST(rte_vfio_tailq.head, mapped_pci_res_list);\n \t/* Get vfio_res */\n \tTAILQ_FOREACH(vfio_res, vfio_res_list, next) {\n-\t\tif (memcmp(&vfio_res->pci_addr, &dev->addr, sizeof(dev->addr)))\n+\t\tif (rte_pci_addr_cmp(&vfio_res->pci_addr, &dev->addr))\n \t\t\tcontinue;\n \t\tbreak;\n \t}\n",
    "prefixes": [
        "2/4"
    ]
}