get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 44050,
    "url": "http://patches.dpdk.org/api/patches/44050/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1535642492-21831-4-git-send-email-alejandro.lucero@netronome.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": "<1535642492-21831-4-git-send-email-alejandro.lucero@netronome.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1535642492-21831-4-git-send-email-alejandro.lucero@netronome.com",
    "date": "2018-08-30T15:21:30",
    "name": "[3/5] bus/pci: use IOVAs check when setting IOVA mode",
    "commit_ref": null,
    "pull_url": null,
    "state": "not-applicable",
    "archived": true,
    "hash": "5aed03b0fa9cecaca4f0c56fbe99c8cb73d640a3",
    "submitter": {
        "id": 270,
        "url": "http://patches.dpdk.org/api/people/270/?format=api",
        "name": "Alejandro Lucero",
        "email": "alejandro.lucero@netronome.com"
    },
    "delegate": null,
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/1535642492-21831-4-git-send-email-alejandro.lucero@netronome.com/mbox/",
    "series": [
        {
            "id": 1117,
            "url": "http://patches.dpdk.org/api/series/1117/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=1117",
            "date": "2018-08-30T15:21:27",
            "name": "use IOVAs check based on DMA mask",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/1117/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/44050/comments/",
    "check": "fail",
    "checks": "http://patches.dpdk.org/api/patches/44050/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 99BE65323;\n\tThu, 30 Aug 2018 17:22:36 +0200 (CEST)",
            "from netronome.com (host-79-78-33-110.static.as9105.net\n\t[79.78.33.110]) by dpdk.org (Postfix) with ESMTP id 2F87C4CBD;\n\tThu, 30 Aug 2018 17:22:28 +0200 (CEST)",
            "from netronome.com (localhost [127.0.0.1])\n\tby netronome.com (8.14.4/8.14.4/Debian-4.1ubuntu1) with ESMTP id\n\tw7UFLZIP021919; Thu, 30 Aug 2018 16:21:35 +0100",
            "(from alucero@localhost)\n\tby netronome.com (8.14.4/8.14.4/Submit) id w7UFLZXb021918;\n\tThu, 30 Aug 2018 16:21:35 +0100"
        ],
        "From": "Alejandro Lucero <alejandro.lucero@netronome.com>",
        "To": "dev@dpdk.org",
        "Cc": "stable@dpdk.org",
        "Date": "Thu, 30 Aug 2018 16:21:30 +0100",
        "Message-Id": "<1535642492-21831-4-git-send-email-alejandro.lucero@netronome.com>",
        "X-Mailer": "git-send-email 1.9.1",
        "In-Reply-To": "<1535642492-21831-1-git-send-email-alejandro.lucero@netronome.com>",
        "References": "<1535642492-21831-1-git-send-email-alejandro.lucero@netronome.com>",
        "Subject": "[dpdk-dev] [PATCH 3/5] bus/pci: use IOVAs check when setting IOVA\n\tmode",
        "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": "Although VT-d emulation currently only supports 39 bits, it could\nbe iovas being within that supported range. This patch allows\nIOVA mode in such a case.\n\nIndeed, memory initialization code can be modified for using lower\nvirtual addresses than those used by the kernel for 64 bits processes\nby default, and therefore memsegs iovas can use 39 bits or less for\nmost system. And this is likely 100% true for VMs.\n\nSigned-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>\n---\n drivers/bus/pci/linux/pci.c | 15 ++++++++++-----\n 1 file changed, 10 insertions(+), 5 deletions(-)",
    "diff": "diff --git a/drivers/bus/pci/linux/pci.c b/drivers/bus/pci/linux/pci.c\nindex 04648ac..215dc10 100644\n--- a/drivers/bus/pci/linux/pci.c\n+++ b/drivers/bus/pci/linux/pci.c\n@@ -588,10 +588,11 @@\n \tfclose(fp);\n \n \tmgaw = ((vtd_cap_reg & VTD_CAP_MGAW_MASK) >> VTD_CAP_MGAW_SHIFT) + 1;\n-\tif (mgaw < X86_VA_WIDTH)\n-\t\treturn false;\n \n-\treturn true;\n+\tif (!rte_eal_check_dma_mask(mgaw))\n+\t\treturn true;\n+\telse\n+\t\treturn false;\n }\n #elif defined(RTE_ARCH_PPC_64)\n static bool\n@@ -615,13 +616,17 @@\n {\n \tstruct rte_pci_device *dev = NULL;\n \tstruct rte_pci_driver *drv = NULL;\n+\tint iommu_dma_mask_check_done = 0;\n \n \tFOREACH_DRIVER_ON_PCIBUS(drv) {\n \t\tFOREACH_DEVICE_ON_PCIBUS(dev) {\n \t\t\tif (!rte_pci_match(drv, dev))\n \t\t\t\tcontinue;\n-\t\t\tif (!pci_one_device_iommu_support_va(dev))\n-\t\t\t\treturn false;\n+\t\t\tif (!iommu_dma_mask_check_done) {\n+\t\t\t\tif (!pci_one_device_iommu_support_va(dev))\n+\t\t\t\t\treturn false;\n+\t\t\t\tiommu_dma_mask_check_done  = 1;\n+\t\t\t}\n \t\t}\n \t}\n \treturn true;\n",
    "prefixes": [
        "3/5"
    ]
}