Thread (16 messages) 16 messages, 3 authors, 2019-06-25

Re: [PATCH 3/6] rt-tests: deadline: Remove duplicated gettid() code

From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Date: 2019-06-25 13:52:22

On 2019-06-25 11:29:28 [+0200], John Kacur wrote:

On Mon, 24 Jun 2019, Sebastian Andrzej Siewior wrote:
quoted
On 2019-06-19 17:48:09 [+0200], John Kacur wrote:
quoted
If anyone objects because they are actively using systems that don't have 
gettid() in the library, please speak-up, for now this is in 
unstable/devel/latest-devel
ehm. gettid() is defined in
	src/lib/rt-utils.c

so how should someone not have that one on his system?
The sentence does say, systems that don't have gettid() in the LIBRARY.

That being said, Kurt, would like to come up with a smarter patch that 
uses the glibc version if detected else falls back on this one?

Then you need to clean it up everywhere, not just for the deadline tests.

Consider this patch NAKed for now. (it's only in the latest-devel not the 
latest version anyway)
=>
- The #define macro for gettid is used in rt-tests since day one. This
  includes cyclictest.c among other files.

- In commit 7efada9d5be26 ("rt-utils: Add gettid()") (which is 0.9)
  tall Daniel introduced a fucntion which can be used instead of the
  define. Based in the grep in my current checkout I don't see any users
  except for pi_stress

- Kurt tried to use the function from rt-tests instead of the define.

Based on what I see you can today use it everywhere. It is not that
simple to use it from glibc because you don't have a compile check to
check for that libc function.

Sebastian
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help