This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: [PATCH 1/1] stp: rt: replace spin_lock with stp style lock and use STP_ALLOC_FLAGS
- From: fche at redhat dot com (Frank Ch. Eigler)
- To: David Smith <dsmith at redhat dot com>
- Cc: yzhu1 <Yanjun dot Zhu at windriver dot com>, systemtap at sourceware dot org
- Date: Tue, 27 Oct 2015 09:52:51 -0400
- Subject: Re: [PATCH 1/1] stp: rt: replace spin_lock with stp style lock and use STP_ALLOC_FLAGS
- Authentication-results: sourceware.org; auth=none
- References: <1445499965-23777-1-git-send-email-yanjun dot zhu at windriver dot com> <56290FFC dot 3030407 at redhat dot com> <562D9BAA dot 7040704 at windriver dot com> <562E9AE0 dot 6030501 at redhat dot com>
dsmith wrote:
> [...]
> Here's the big question - on the realtime kernel, is it ever safe to sleep?
> If the answer to the previous question is "no", then your change
> [switching to STP_ALLOC_FLAGS] is correct. [...]
But even then, not in general. If we use atomic memory allocation flags only,
we may suffer unnecessary alloc failures on normal kernels. If we do this
switch, perhaps it needs to be done rt-conditionally. It might be as simple
as to "#define STP_ALLOC_SLEEP_FLAGS ..." differently on rt (CONFIG_*...).
- FChE