get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 38739,
    "url": "https://patches.dpdk.org/api/patches/38739/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/1524518942-1998-8-git-send-email-arnon@qwilt.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": "<1524518942-1998-8-git-send-email-arnon@qwilt.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1524518942-1998-8-git-send-email-arnon@qwilt.com",
    "date": "2018-04-23T21:28:58",
    "name": "[dpdk-dev,v5,07/11] eal: replace rte_panic instances in hugepage_info",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "bc3c850062b20414f7036fdda67fb8331f85d4e5",
    "submitter": {
        "id": 986,
        "url": "https://patches.dpdk.org/api/people/986/?format=api",
        "name": "Arnon Warshavsky",
        "email": "arnon@qwilt.com"
    },
    "delegate": {
        "id": 1,
        "url": "https://patches.dpdk.org/api/users/1/?format=api",
        "username": "tmonjalo",
        "first_name": "Thomas",
        "last_name": "Monjalon",
        "email": "thomas@monjalon.net"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/1524518942-1998-8-git-send-email-arnon@qwilt.com/mbox/",
    "series": [],
    "comments": "https://patches.dpdk.org/api/patches/38739/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/38739/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 55C6A2BA4;\n\tMon, 23 Apr 2018 23:29:33 +0200 (CEST)",
            "from mta.qwilt.com (mta.qwilt.com [52.9.191.255])\n\tby dpdk.org (Postfix) with ESMTP id 69A922965\n\tfor <dev@dpdk.org>; Mon, 23 Apr 2018 23:29:29 +0200 (CEST)",
            "from localhost (localhost [127.0.0.1])\n\tby mta.qwilt.com (Postfix) with ESMTP id CF6B080C4CF;\n\tMon, 23 Apr 2018 21:29:28 +0000 (UTC)",
            "from mta.qwilt.com ([127.0.0.1])\n\tby localhost (mta.qwilt.com [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id Wa4JfybqlcAf; Mon, 23 Apr 2018 21:29:28 +0000 (UTC)",
            "from rd01.it.qwilt.com.qwilt.com (80.179.204.39.cable.012.net.il\n\t[80.179.204.39])\n\tby mta.qwilt.com (Postfix) with ESMTPSA id 588E580C4D5;\n\tMon, 23 Apr 2018 21:29:26 +0000 (UTC)"
        ],
        "X-Virus-Scanned": "amavisd-new at qwilt.com",
        "From": "Arnon Warshavsky <arnon@qwilt.com>",
        "To": "thomas@monjalon.net, anatoly.burakov@intel.com, wenzhuo.lu@intel.com,\n\tdeclan.doherty@intel.com, jerin.jacob@caviumnetworks.com,\n\tbruce.richardson@intel.com, ferruh.yigit@intel.com",
        "Cc": "dev@dpdk.org,\n\tarnon@qwilt.com",
        "Date": "Tue, 24 Apr 2018 00:28:58 +0300",
        "Message-Id": "<1524518942-1998-8-git-send-email-arnon@qwilt.com>",
        "X-Mailer": "git-send-email 1.8.3.1",
        "In-Reply-To": "<1524518942-1998-1-git-send-email-arnon@qwilt.com>",
        "References": "<1524518942-1998-1-git-send-email-arnon@qwilt.com>",
        "Subject": "[dpdk-dev] [PATCH v5 07/11] eal: replace rte_panic instances in\n\thugepage_info",
        "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://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<https://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "replace panic calls with log and return value.\n\nSigned-off-by: Arnon Warshavsky <arnon@qwilt.com>\n---\n lib/librte_eal/linuxapp/eal/eal_hugepage_info.c | 37 +++++++++++++++++--------\n 1 file changed, 26 insertions(+), 11 deletions(-)",
    "diff": "diff --git a/lib/librte_eal/linuxapp/eal/eal_hugepage_info.c b/lib/librte_eal/linuxapp/eal/eal_hugepage_info.c\nindex db5aabd..797b8fa 100644\n--- a/lib/librte_eal/linuxapp/eal/eal_hugepage_info.c\n+++ b/lib/librte_eal/linuxapp/eal/eal_hugepage_info.c\n@@ -145,8 +145,8 @@\n \treturn num_pages;\n }\n \n-static uint64_t\n-get_default_hp_size(void)\n+static int\n+get_default_hp_size(uint64_t *result)\n {\n \tconst char proc_meminfo[] = \"/proc/meminfo\";\n \tconst char str_hugepagesz[] = \"Hugepagesize:\";\n@@ -155,8 +155,11 @@\n \tunsigned long long size = 0;\n \n \tFILE *fd = fopen(proc_meminfo, \"r\");\n-\tif (fd == NULL)\n-\t\trte_panic(\"Cannot open %s\\n\", proc_meminfo);\n+\tif (fd == NULL) {\n+\t\tRTE_LOG(CRIT, EAL, \"%s(): Cannot open %s\\n\",\n+\t\t\t\t__func__, proc_meminfo);\n+\t\treturn -1;\n+\t}\n \twhile(fgets(buffer, sizeof(buffer), fd)){\n \t\tif (strncmp(buffer, str_hugepagesz, hugepagesz_len) == 0){\n \t\t\tsize = rte_str_to_size(&buffer[hugepagesz_len]);\n@@ -164,9 +167,13 @@\n \t\t}\n \t}\n \tfclose(fd);\n-\tif (size == 0)\n-\t\trte_panic(\"Cannot get default hugepage size from %s\\n\", proc_meminfo);\n-\treturn size;\n+\tif (size == 0) {\n+\t\tRTE_LOG(CRIT, EAL, \"%s(): Cannot get default hugepage size from %s\\n\",\n+\t\t\t\t\t\t __func__, proc_meminfo);\n+\t\treturn -1;\n+\t}\n+\t*result = size;\n+\treturn 0;\n }\n \n static int\n@@ -191,11 +198,19 @@\n \tint retval = -1;\n \n \tFILE *fd = fopen(proc_mounts, \"r\");\n-\tif (fd == NULL)\n-\t\trte_panic(\"Cannot open %s\\n\", proc_mounts);\n+\tif (fd == NULL) {\n+\t\tRTE_LOG(CRIT, EAL, \"%s(): Cannot open %s\\n\",\n+\t\t\t\t__func__, proc_mounts);\n+\t\treturn -ENOENT;\n+\t}\n \n-\tif (default_size == 0)\n-\t\tdefault_size = get_default_hp_size();\n+\tif (default_size == 0) {\n+\t\tretval = get_default_hp_size(&default_size);\n+\t\tif (retval) {\n+\t\t\tfclose(fd);\n+\t\t\treturn retval;\n+\t\t}\n+\t}\n \n \twhile (fgets(buf, sizeof(buf), fd)){\n \t\tif (rte_strsplit(buf, sizeof(buf), splitstr, _FIELDNAME_MAX,\n",
    "prefixes": [
        "dpdk-dev",
        "v5",
        "07/11"
    ]
}