Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/130454/?format=api
https://patches.dpdk.org/api/patches/130454/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/20230817042820.137957-7-okaya@kernel.org/", "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": "<20230817042820.137957-7-okaya@kernel.org>", "list_archive_url": "https://inbox.dpdk.org/dev/20230817042820.137957-7-okaya@kernel.org", "date": "2023-08-17T04:28:17", "name": "[v5,06/10] eal_memory: skip initialization", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "ae9c24e683d96110851f53887614e48211250223", "submitter": { "id": 2903, "url": "https://patches.dpdk.org/api/people/2903/?format=api", "name": "Sinan Kaya", "email": "okaya@kernel.org" }, "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/20230817042820.137957-7-okaya@kernel.org/mbox/", "series": [ { "id": 29258, "url": "https://patches.dpdk.org/api/series/29258/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=29258", "date": "2023-08-17T04:28:11", "name": "support reinit flow", "version": 5, "mbox": "https://patches.dpdk.org/series/29258/mbox/" } ], "comments": "https://patches.dpdk.org/api/patches/130454/comments/", "check": "success", "checks": "https://patches.dpdk.org/api/patches/130454/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 mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id EC6A84308A;\n\tThu, 17 Aug 2023 06:29:04 +0200 (CEST)", "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 6A0B74324E;\n\tThu, 17 Aug 2023 06:28:33 +0200 (CEST)", "from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217])\n by mails.dpdk.org (Postfix) with ESMTP id 678DF43259\n for <dev@dpdk.org>; Thu, 17 Aug 2023 06:28:28 +0200 (CEST)", "from smtp.kernel.org (relay.kernel.org [52.25.139.140])\n (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n key-exchange X25519 server-signature RSA-PSS (2048 bits))\n (No client certificate requested)\n by dfw.source.kernel.org (Postfix) with ESMTPS id E8D05619BF;\n Thu, 17 Aug 2023 04:28:27 +0000 (UTC)", "by smtp.kernel.org (Postfix) with ESMTPSA id 04539C433C9;\n Thu, 17 Aug 2023 04:28:26 +0000 (UTC)" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org;\n s=k20201202; t=1692246507;\n bh=OXNlVatoTAEiGwl0ebmeGaLh2BTIaoaMpzWHCOXaN7M=;\n h=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n b=lCZbDGdHWKM7GE8h+SqI6fSzfNkOpjG48pQAIKchGJhglMLT+kSBDaYaTYUdvENJi\n ytlQbjRIIKGpHAP0T35mnzqQygbKbJgcnJAVC/zXKBsFfElLjf9v+4B30WzlfTSS+q\n S6s0307qZvevk90L3iAIVqje3LiaOceilK31pGlHjCPdiJPjsCPpQDI0MFqmxbT6gO\n y91xfB0nY/UTX9kaA+4rCLQed9Eypn150/1EgA/DkwiKYL+cyzOUzv6HdZs4z9BMEl\n s/dqsiGwkwiqO/GNcLfC8CDJKFl0/IhQibOOuaSVPFZd5atKDv5qVgoSvcQD0a8nKv\n k5p1AqKVEPYOQ==", "From": "okaya@kernel.org", "To": "Anatoly Burakov <anatoly.burakov@intel.com>", "Cc": "dev@dpdk.org,\n\tSinan Kaya <okaya@kernel.org>", "Subject": "[PATCH v5 06/10] eal_memory: skip initialization", "Date": "Thu, 17 Aug 2023 00:28:17 -0400", "Message-Id": "<20230817042820.137957-7-okaya@kernel.org>", "X-Mailer": "git-send-email 2.25.1", "In-Reply-To": "<20230817042820.137957-1-okaya@kernel.org>", "References": "<20230817042820.137957-1-okaya@kernel.org>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.29", "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" }, "content": "From: Sinan Kaya <okaya@kernel.org>\n\nInitialize heap area just once.\n\nSigned-off-by: Sinan Kaya <okaya@kernel.org>\n---\n lib/eal/common/eal_common_memory.c | 6 ++++++\n lib/eal/common/malloc_heap.c | 7 +++++++\n 2 files changed, 13 insertions(+)", "diff": "diff --git a/lib/eal/common/eal_common_memory.c b/lib/eal/common/eal_common_memory.c\nindex d9433db623..1ba2007f76 100644\n--- a/lib/eal/common/eal_common_memory.c\n+++ b/lib/eal/common/eal_common_memory.c\n@@ -1083,6 +1083,10 @@ rte_eal_memory_init(void)\n \tconst struct internal_config *internal_conf =\n \t\teal_get_internal_configuration();\n \tint retval;\n+\tstatic bool run_once;\n+\n+\tif (run_once)\n+\t\treturn 0;\n \n \tRTE_LOG(DEBUG, EAL, \"Setting up physically contiguous memory...\\n\");\n \n@@ -1101,6 +1105,8 @@ rte_eal_memory_init(void)\n \tif (internal_conf->no_shconf == 0 && rte_eal_memdevice_init() < 0)\n \t\tgoto fail;\n \n+\trun_once = true;\n+\n \treturn 0;\n fail:\n \treturn -1;\ndiff --git a/lib/eal/common/malloc_heap.c b/lib/eal/common/malloc_heap.c\nindex 6b6cf9174c..5f01735520 100644\n--- a/lib/eal/common/malloc_heap.c\n+++ b/lib/eal/common/malloc_heap.c\n@@ -31,6 +31,7 @@\n #define CONST_MAX(a, b) (a > b ? a : b) /* RTE_MAX is not a constant */\n #define EXTERNAL_HEAP_MIN_SOCKET_ID (CONST_MAX((1 << 8), RTE_MAX_NUMA_NODES))\n \n+\n static unsigned\n check_hugepage_sz(unsigned flags, uint64_t hugepage_sz)\n {\n@@ -1409,6 +1410,10 @@ rte_eal_malloc_heap_init(void)\n \tunsigned int i;\n \tconst struct internal_config *internal_conf =\n \t\teal_get_internal_configuration();\n+\tstatic bool run_once;\n+\n+\tif (run_once)\n+\t\treturn 0;\n \n \tif (internal_conf->match_allocations)\n \t\tRTE_LOG(DEBUG, EAL, \"Hugepages will be freed exactly as allocated.\\n\");\n@@ -1435,6 +1440,8 @@ rte_eal_malloc_heap_init(void)\n \t\treturn -1;\n \t}\n \n+\trun_once = true;\n+\n \treturn 0;\n }\n \n", "prefixes": [ "v5", "06/10" ] }{ "id": 130454, "url": "