From: Philippe Gerum <rpm@xenomai.org>
To: "arethe.rtai" <arethe.rtai@domain.hid>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai-core] I suspect the shared memory of Xenomai has bug.
Date: Thu, 19 May 2011 10:03:43 +0200 [thread overview]
Message-ID: <1305792223.2118.22.camel@domain.hid> (raw)
In-Reply-To: <201105191537542034180@domain.hid>
On Thu, 2011-05-19 at 15:37 +0800, arethe.rtai wrote:
>
> I solved the problem of the shared memory cannot be allocated in the
> user space.
> Because the shared memory space are allocated from the kheap, but the
> kheap is not a mapped heap, i.e. its pages are not reserved.
> I init the kheap by xnheap_init_mapped rather than xnheap_init. The
> problem is solved.
>
You have just turned the global system heap to a shared heap, which is
badly wrong. If anywhere, the issue is in create_new_heap(), or in the
_compat_shm_alloc() interface in userland, or a combination of both.
As Gilles told you already, such a 100% reproducible allocation/mapping
issue can not be a generic one, involving the core heap system,
otherwise no skin would ever work. We do depend on the system heap
internally, for almost everything in the system. It is much more likely
a local RTAI skin bug, because this code has bit rot over time, due to
lack of interest and users.
PS: Please keep the list CCed.
> Qin Chenggang
>
> 2011-05-19
>
> ______________________________________________________________________
> arethe.rtai
>
> ______________________________________________________________________
> 发件人: Philippe Gerum
> 发送时间: 2011-05-13 14:50:06
> 收件人: arethe rtai
> 抄送: Xenomai-core
> 主题: Re: [Xenomai-core] I suspect the shared memory of Xenomai has
> bug.
>
> On Fri, 2011-05-13 at 09:25 +0800, arethe rtai wrote:
> > HI all:
> > I always got null while I request a shared memory through RTAI
> > skins in the user space.
> > Some bugs maybe exist in the sub-system. I traced the execution
> > stream of rt_shm_alloc, and found the mmap() operation always return
> > -22. I suspect the problem should be same while we use other skins,
> > because the mmap operation is implemented in /ksrc/nucleus/heap.c.
> > Is there anyone encountered this problem?
>
> No. The fact is that the RTAI skin has not been actively maintained for
> years now, so a local bug there is possible. Due to the lack of users
> and interest, this skin was removed from the upcoming 2.6.x series.
>
> > Regards Arethe.
> >
> > _______________________________________________
> > Xenomai-core mailing list
> > Xenomai-core@domain.hid
> > https://mail.gna.org/listinfo/xenomai-core
>
> --
> Philippe.
>
>
--
Philippe.
prev parent reply other threads:[~2011-05-19 8:03 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-13 1:25 [Xenomai-core] I suspect the shared memory of Xenomai has bug arethe rtai
2011-05-13 5:08 ` Gilles Chanteperdrix
2011-05-13 6:50 ` Philippe Gerum
[not found] ` <201105191537542034180@domain.hid>
2011-05-19 8:03 ` Philippe Gerum [this message]
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=1305792223.2118.22.camel@domain.hid \
--to=rpm@xenomai.org \
--cc=arethe.rtai@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.