Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/10496/?format=api
https://patches.dpdk.org/api/patches/10496/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/1455399524-3252-2-git-send-email-mhall@mhcomputing.net/", "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": "<1455399524-3252-2-git-send-email-mhall@mhcomputing.net>", "list_archive_url": "https://inbox.dpdk.org/dev/1455399524-3252-2-git-send-email-mhall@mhcomputing.net", "date": "2016-02-13T21:38:43", "name": "[dpdk-dev,2/3] eal_interrupts: mark EAL interrupt thread as a daemon thread", "commit_ref": null, "pull_url": null, "state": "rejected", "archived": true, "hash": "0dd0be3642d71fde07d1505203c2ba2da4e73adb", "submitter": { "id": 37, "url": "https://patches.dpdk.org/api/people/37/?format=api", "name": "Matthew Hall", "email": "mhall@mhcomputing.net" }, "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/1455399524-3252-2-git-send-email-mhall@mhcomputing.net/mbox/", "series": [], "comments": "https://patches.dpdk.org/api/patches/10496/comments/", "check": "pending", "checks": "https://patches.dpdk.org/api/patches/10496/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 2A18495DE;\n\tSat, 13 Feb 2016 22:38:55 +0100 (CET)", "from mail.mhcomputing.net (master.mhcomputing.net [74.208.228.170])\n\tby dpdk.org (Postfix) with ESMTP id ECC678D3B\n\tfor <dev@dpdk.org>; Sat, 13 Feb 2016 22:38:51 +0100 (CET)", "from mvs-01.mhcomputing.net\n\t(99-34-229-174.lightspeed.sntcca.sbcglobal.net [99.34.229.174])\n\tby mail.mhcomputing.net (Postfix) with ESMTPSA id 214CA772;\n\tSat, 13 Feb 2016 13:38:51 -0800 (PST)" ], "From": "Matthew Hall <mhall@mhcomputing.net>", "To": "dev@dpdk.org", "Date": "Sat, 13 Feb 2016 13:38:43 -0800", "Message-Id": "<1455399524-3252-2-git-send-email-mhall@mhcomputing.net>", "X-Mailer": "git-send-email 2.5.0", "In-Reply-To": "<1455399524-3252-1-git-send-email-mhall@mhcomputing.net>", "References": "<1455399524-3252-1-git-send-email-mhall@mhcomputing.net>", "Subject": "[dpdk-dev] [PATCH 2/3] eal_interrupts: mark EAL interrupt thread as\n\ta daemon thread", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "patches and discussions about DPDK <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": "This thread should not be stuck in an active state when the application is\nshutting down.\n\nSigned-off-by: Matthew Hall <mhall@mhcomputing.net>\n---\n lib/librte_eal/linuxapp/eal/eal_interrupts.c | 39 +++++++++++++++++++++-------\n 1 file changed, 30 insertions(+), 9 deletions(-)", "diff": "diff --git a/lib/librte_eal/linuxapp/eal/eal_interrupts.c b/lib/librte_eal/linuxapp/eal/eal_interrupts.c\nindex aa332a1..c999cb6 100644\n--- a/lib/librte_eal/linuxapp/eal/eal_interrupts.c\n+++ b/lib/librte_eal/linuxapp/eal/eal_interrupts.c\n@@ -867,6 +867,7 @@ rte_eal_intr_init(void)\n {\n \tint ret = 0, ret_1 = 0;\n \tchar thread_name[RTE_MAX_THREAD_NAME_LEN];\n+\tpthread_attr_t thread_attr;\n \n \t/* init the global interrupt source head */\n \tTAILQ_INIT(&intr_sources);\n@@ -878,20 +879,40 @@ rte_eal_intr_init(void)\n \tif (pipe(intr_pipe.pipefd) < 0)\n \t\treturn -1;\n \n+\tret = pthread_attr_init(&thread_attr);\n+\tif (ret != 0) {\n+\t\tRTE_LOG(ERR, EAL,\n+\t\t\t\"Failed to init interrupt handling thread attributes\\n\");\n+\t\treturn -ret;\n+\t}\n+\n+\tret = pthread_attr_setdetachstate(&thread_attr, PTHREAD_CREATE_DETACHED);\n+\tif (ret != 0) {\n+\t\tRTE_LOG(ERR, EAL,\n+\t\t\t\"Failed to set interrupt handling thread attributes\\n\");\n+\t\treturn -ret;\n+\t}\n+\n \t/* create the host thread to wait/handle the interrupt */\n-\tret = pthread_create(&intr_thread, NULL,\n+\tret = pthread_create(&intr_thread, &thread_attr,\n \t\t\teal_intr_thread_main, NULL);\n \tif (ret != 0) {\n \t\tRTE_LOG(ERR, EAL,\n \t\t\t\"Failed to create thread for interrupt handling\\n\");\n-\t} else {\n-\t\t/* Set thread_name for aid in debugging. */\n-\t\tsnprintf(thread_name, RTE_MAX_THREAD_NAME_LEN,\n-\t\t\t\"eal-intr-thread\");\n-\t\tret_1 = rte_thread_setname(intr_thread, thread_name);\n-\t\tif (ret_1 != 0)\n-\t\t\tRTE_LOG(ERR, EAL,\n-\t\t\t\"Failed to set thread name for interrupt handling\\n\");\n+\t\treturn -ret;\n+\t}\n+\n+\t/* Set thread_name for aid in debugging. */\n+\tsnprintf(thread_name, RTE_MAX_THREAD_NAME_LEN,\n+\t\t\"eal-intr-thread\");\n+\tret_1 = rte_thread_setname(intr_thread, thread_name);\n+\tif (ret_1 != 0) {\n+\t\tRTE_LOG(ERR, EAL,\n+\t\t\"Failed to set thread name for interrupt handling\\n\");\n+\t}\n+\n+\treturn -ret;\n+}\n \n int\n rte_eal_intr_exit(void)\n", "prefixes": [ "dpdk-dev", "2/3" ] }{ "id": 10496, "url": "