From: Thomas Monjalon <thomas.monjalon@6wind.com>
To: david.marchand@6wind.com
Cc: dev@dpdk.org
Subject: [dpdk-dev] [PATCH] eal/linux: fix build with glibc < 2.12
Date: Sun, 19 Jun 2016 23:11:10 +0200 [thread overview]
Message-ID: <1466370670-20981-1-git-send-email-thomas.monjalon@6wind.com> (raw)
In-Reply-To: <2401799.KuipojHmpA@xps13>
The function rte_thread_setname needs glibc 2.12,
otherwise it returns -1 without using any parameter.
The macro RTE_SET_USED avoids an "unused parameter" warning.
Fixes: 3901ed99c2f8 ("eal: fix thread naming on FreeBSD")
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
---
lib/librte_eal/linuxapp/eal/eal_thread.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lib/librte_eal/linuxapp/eal/eal_thread.c b/lib/librte_eal/linuxapp/eal/eal_thread.c
index 8c3bf03..9f88530 100644
--- a/lib/librte_eal/linuxapp/eal/eal_thread.c
+++ b/lib/librte_eal/linuxapp/eal/eal_thread.c
@@ -206,5 +206,7 @@ int rte_thread_setname(pthread_t id, const char *name)
ret = pthread_setname_np(id, name);
#endif
#endif
+ RTE_SET_USED(id);
+ RTE_SET_USED(name);
return ret;
}
--
2.7.0
next prev parent reply other threads:[~2016-06-19 21:11 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-17 15:25 [dpdk-dev] [PATCH] eal: fix thread naming on FreeBSD Thomas Monjalon
2016-06-17 15:56 ` David Marchand
2016-06-17 16:02 ` [dpdk-dev] [PATCH v2] " Thomas Monjalon
2016-06-17 16:04 ` David Marchand
2016-06-17 16:04 ` Thomas Monjalon
2016-06-19 21:11 ` Thomas Monjalon [this message]
2016-06-20 8:51 ` [dpdk-dev] [PATCH] eal/linux: fix build with glibc < 2.12 Thomas Monjalon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1466370670-20981-1-git-send-email-thomas.monjalon@6wind.com \
--to=thomas.monjalon@6wind.com \
--cc=david.marchand@6wind.com \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).