All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wolfgang Grandegger <wg@grandegger.com>
To: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
Cc: Xenomai@xenomai.org
Subject: Re: [Xenomai] Sharing memory between rt-posix and standard-posix apps
Date: Tue, 19 Jun 2012 11:29:57 +0200	[thread overview]
Message-ID: <4FE04695.4020609@grandegger.com> (raw)
In-Reply-To: <4FE040A1.80400@xenomai.org>

On 06/19/2012 11:04 AM, Gilles Chanteperdrix wrote:
> On 06/19/2012 10:52 AM, Wolfgang Grandegger wrote:
>> On 06/19/2012 10:50 AM, Gilles Chanteperdrix wrote:
>>> On 06/19/2012 10:49 AM, Wolfgang Grandegger wrote:
>>>> On 06/19/2012 10:33 AM, Gilles Chanteperdrix wrote:
>>>>> On 06/19/2012 10:25 AM, Wolfgang Grandegger wrote:
>>>>>> Hello,
>>>>>>
>>>>>> the shared memory support of Xenomai's POSIX skin currently only support
>>>>>> shared memory between rt processes.
>>>>>
>>>>> These services are for sharing memory between user-space and
>>>>> kernel-space. In order to share memory between user-space processes, you
>>>>> can use plain linux shared memories.
>>>>
>>>> But then I will get mode switches due to page faults, right?
>>>
>>> No, there should not be any page fault.
>>
>> But that's what we observe on a i.MX53 and i.MX6Q board. IIRC, the first
>> access usually results in a page fault.
> 
> And you do not get the same behaviour with posix skin shared memories ?

Right, and that's because do_pagefault() is called somewhere in the
initialization, IIRC. But I will redo my tests now.

Anyway, if I use the POSIX skin the shared memory functions in there
will be used automatically. But I could use  __real_shm_open and
__real_mmap, right? ... and access the page once per page in the
initialization phase. Then no more page faults should happen.

Wolfgang.




  reply	other threads:[~2012-06-19  9:29 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-19  8:25 [Xenomai] Sharing memory between rt-posix and standard-posix apps Wolfgang Grandegger
2012-06-19  8:33 ` Gilles Chanteperdrix
2012-06-19  8:49   ` Wolfgang Grandegger
2012-06-19  8:50     ` Gilles Chanteperdrix
2012-06-19  8:52       ` Wolfgang Grandegger
2012-06-19  9:04         ` Gilles Chanteperdrix
2012-06-19  9:29           ` Wolfgang Grandegger [this message]
2012-06-19  9:38             ` Gilles Chanteperdrix
2012-06-20  7:33               ` Wolfgang Grandegger
2012-06-20  9:18                 ` Gilles Chanteperdrix

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=4FE04695.4020609@grandegger.com \
    --to=wg@grandegger.com \
    --cc=Xenomai@xenomai.org \
    --cc=gilles.chanteperdrix@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.