Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/28038/?format=api
https://patches.dpdk.org/api/patches/28038/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/20170828214622.133314-1-seth.howell@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": "<20170828214622.133314-1-seth.howell@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20170828214622.133314-1-seth.howell@intel.com", "date": "2017-08-28T21:46:22", "name": "[dpdk-dev,v2] eal/linuxapp: check mmap return value MAP_FAILED", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "1501382e8afaabef2bfdb4791c2c88bcb3c49cbd", "submitter": { "id": 809, "url": "https://patches.dpdk.org/api/people/809/?format=api", "name": "Seth Howell", "email": "seth.howell@intel.com" }, "delegate": null, "mbox": "https://patches.dpdk.org/project/dpdk/patch/20170828214622.133314-1-seth.howell@intel.com/mbox/", "series": [], "comments": "https://patches.dpdk.org/api/patches/28038/comments/", "check": "warning", "checks": "https://patches.dpdk.org/api/patches/28038/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 [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id E25461B53;\n\tMon, 28 Aug 2017 23:46:33 +0200 (CEST)", "from mga02.intel.com (mga02.intel.com [134.134.136.20])\n\tby dpdk.org (Postfix) with ESMTP id 3A9E011C5\n\tfor <dev@dpdk.org>; Mon, 28 Aug 2017 23:46:31 +0200 (CEST)", "from orsmga003.jf.intel.com ([10.7.209.27])\n\tby orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t28 Aug 2017 14:46:30 -0700", "from sethhowe-desk.ch.intel.com ([143.182.137.63])\n\tby orsmga003.jf.intel.com with ESMTP; 28 Aug 2017 14:46:30 -0700" ], "X-ExtLoop1": "1", "X-IronPort-AV": "E=Sophos; i=\"5.41,442,1498546800\"; d=\"scan'208\";\n\ta=\"1008554696\"", "From": "Seth Howell <seth.howell@intel.com>", "To": "dev@dpdk.org", "Cc": "Seth Howell <seth.howell@intel.com>", "Date": "Mon, 28 Aug 2017 14:46:22 -0700", "Message-Id": "<20170828214622.133314-1-seth.howell@intel.com>", "X-Mailer": "git-send-email 2.9.5", "In-Reply-To": "<20170815205336.9266-1-seth.howell@intel.com>", "References": "<20170815205336.9266-1-seth.howell@intel.com>", "Subject": "[dpdk-dev] [PATCH v2] eal/linuxapp: check mmap return value\n\tMAP_FAILED", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<http://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": "<http://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": "If mmap fails, it will return the value MAP_FAILED. Checking for this\nreturn code allows us to properly identify mmap failures and report\nthem as such to the calling function.\n\nSigned-off-by: Seth Howell <seth.howell@intel.com>\n---\n lib/librte_eal/linuxapp/eal/eal_memory.c | 2 ++\n 1 file changed, 2 insertions(+)", "diff": "diff --git a/lib/librte_eal/linuxapp/eal/eal_memory.c b/lib/librte_eal/linuxapp/eal/eal_memory.c\nindex 5279128..ba76b02 100644\n--- a/lib/librte_eal/linuxapp/eal/eal_memory.c\n+++ b/lib/librte_eal/linuxapp/eal/eal_memory.c\n@@ -716,6 +716,8 @@ create_shared_memory(const char *filename, const size_t mem_size)\n \t}\n \tretval = mmap(NULL, mem_size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0);\n \tclose(fd);\n+\tif (retval == MAP_FAILED)\n+\t return NULL;\n \treturn retval;\n }\n \n", "prefixes": [ "dpdk-dev", "v2" ] }{ "id": 28038, "url": "