Skip to contentSkip to conversation

shm_open returns errno 38 - function not implemented

Xenomai-help Yigal Goldberger 2 participants 4 messages Oct 15, 2009 – Oct 16, 2009

lore
Share & tools
lore
#0 lore raw

Hi again,

I'm trying to create a shared memory area .
The system is a powerpc based board running linux kernel 2.6.29.4 and Xenomai 2.4.8 .
When I call shm_open from user space I get error 38 - function not implemented .

Thanks for the help,

Yigal Goldberger .

#1 lore raw
Quoted 6 lines · Yigal Goldberger

Hi again,

I'm trying to create a shared memory area .
The system is a powerpc based board running linux kernel 2.6.29.4 and Xenomai 2.4.8 .
When I call shm_open from user space I get error 38 - function not implemented .

Normally, xenomai's shm_open tries to use the xenomai posix skin service first, and if it fails (because the shared memory option was not enabled in the posix skin configuration), falls back to linux service.

You get this error because:
- Xenomai posix skin's shared memory services are not enabled;
- your glibc does not support posix shared memory services (you can check this in xenomai's config.log, there is a test detecting it).

Now, Xenomai posix skins's shared memory services are to be used if you want to share memory between a kernel-space real-time posix application, and a user-space real-time posix application.

So, if this is what you want to do, enable the xenomai posix skin shared memory services in the kernel configuration (and please upgrade to xenomai 2.4.9.1, because some bugs in the shared memory support were fixed recently). If you want to share memory between two user-space applications, you can also use xenomai shared memory services, but you are probably better of upgrading your glibc to a glibc which support posix shared memories.

Signature · 1 line
                                          Gilles
#2 lore raw

Gilles,
Thanks for the answer.

I need shared memory only between user space applications , so I do prefer the second option. (our system is stable and we're satisfied from the performance , so we'd like to make as little changes as possible at this mature stage of the project ). Can you advise me how to get the right version of the glibc (is it a stand alone change , simply replacing the glibc file , or do I need to make other changes ?)

Thanks again to the Xenomai operation , and to you personaly for your support ! Yigal Goldberger .

Quoted 56 lines · Gilles Chanteperdrix

From: Gilles Chanteperdrix <[email protected]>
Subject: Re: [Xenomai-help] shm_open returns errno 38 - function not implemented
To: "Yigal Goldberger" <[email protected]>
Cc: [email protected]
Date: Friday, October 16, 2009, 12:00 PM

Quoted 4 lines · Yigal Goldberger

Hi again,

I'm trying to create a shared memory area .
The system is a powerpc based board running linux

kernel 2.6.29.4

Quoted 2 lines

and Xenomai 2.4.8 .
When I call shm_open from user space I get error 38 -

function not implemented .

Normally, xenomai's shm_open tries to use the xenomai posix skin service
first, and if it fails (because the shared memory option was not enabled
in the posix skin configuration), falls back to linux service.

You get this error because:
- Xenomai posix skin's shared memory services are not enabled;
- your glibc does not support posix shared memory services (you can
check this in xenomai's config.log, there is a test detecting it).

Now, Xenomai posix skins's shared memory services are to be used if you
want to share memory between a kernel-space real-time posix application,
and a user-space real-time posix application.

So, if this is what you want to do, enable the xenomai posix skin shared
memory services in the kernel configuration (and please upgrade to
xenomai 2.4.9.1, because some bugs in the shared memory support were
fixed recently). If you want to share memory between two user-space
applications, you can also use xenomai shared memory services, but you
are probably better of upgrading your glibc to a glibc which support
posix shared memories.

Signature · 3 lines
               
               
          Gilles
#3 lore raw
Quoted 8 lines · Yigal Goldberger

Gilles,
Thanks for the answer.

I need shared memory only between user space applications , so I do prefer the second option. (our system is stable and we're satisfied from the performance , so we'd like to make as little changes as possible at this mature stage of the project ). Can you advise me how to get the right version of the glibc (is it a stand alone change , simply replacing the glibc file , or do I need to make other changes ?)

Thanks again to the Xenomai operation , and to you personaly for your support ! Yigal Goldberger .

Any reasonably recent version of the glibc should do, but:
- you may be using the glibc from your toolchain, so changing glibc may mean changing toolchain;
- well, the glibc is a bit the heart of the user-space support. It has more than one files. And changing them may change a lot of things.

So, I think, the simpler thing for you is to use xenomai shared memories.

Signature · 1 line
                                          Gilles