From: Philippe Gerum <rpm@xenomai.org>
To: Jan Kiszka <jan.kiszka@domain.hid>
Cc: xenomai@xenomai.org, xenomai@xenomai.org
Subject: [Xenomai-core] Re: [Xenomai-help] Panic in rt_queue_create: bug or misuse?
Date: Tue, 04 Apr 2006 15:52:38 +0200 [thread overview]
Message-ID: <44327A26.8010003@domain.hid> (raw)
In-Reply-To: <44326FBB.9070405@domain.hid>
Jan Kiszka wrote:
> Brian L. wrote:
>
>>How could I forget mlockall? I've been calling it in rtai forever...Is
>>there any other neccessary boilerplate?
>
>
> This is a very frequently made mistake. Philippe, is there a chance add
> some simple debug check for this situation? Something to check when the
> first shadow thread is created for a process?
The following patch would cause SIGXCPU to be sent to emerging real-time
threads from a non-fully mlocked program (i.e. not including
MCL_FUTURE). We should make this conditionally compiled too. I'm not
sure that we would not introduce problems when dealing with mmio areas
mapped in user-space at least for older kernel revisions (the VM_IO
issue might have been fixed in recent kernels, though), this is why I
would tend to make it easy to work around this check by simply ignoring
the signal, for handling specific init configurations for which people
know what they are doing.
--- ksrc/nucleus/shadow.c (revision 875)
+++ ksrc/nucleus/shadow.c (working copy)
@@ -754,6 +754,9 @@
current->pid,
xnthread_base_priority(thread));
+ if (!(current->mm->def_flags & VM_LOCKED))
+ send_sig(SIGXCPU,current,1);
+
current->cap_effective |=
CAP_TO_MASK(CAP_IPC_LOCK)|
CAP_TO_MASK(CAP_SYS_RAWIO)|
--
Philippe.
next prev parent reply other threads:[~2006-04-04 13:52 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-04-04 6:04 [Xenomai-help] Panic in rt_queue_create: bug or misuse? Brian L.
2006-04-04 7:53 ` Philippe Gerum
2006-04-04 8:18 ` Jan Kiszka
2006-04-04 12:53 ` Brian L.
2006-04-04 13:08 ` Jan Kiszka
2006-04-04 13:52 ` Philippe Gerum [this message]
2006-04-04 12:56 ` Philippe Gerum
2006-04-04 13:06 ` Philippe Gerum
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=44327A26.8010003@domain.hid \
--to=rpm@xenomai.org \
--cc=jan.kiszka@domain.hid \
--cc=xenomai@xenomai.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.