Shared Memory?
Looking at the Xenomai documentation, I can't see how to do shared memory communication between a realtime and non-realtime userland task. Do I just use regular Linux shared memory, but somehow lock it down?
Thanks,
-kb
Quoted 5 lines · Kent Borg
Looking at the Xenomai documentation, I can't see how to do shared memory communication between a realtime and non-realtime userland task. Do I just use regular Linux shared memory, but somehow lock it down?
Use mixed RT/non-RT threads and you will have shared mem for free, use processes and you only have to ask linux for some shared fragments. In any case don't forget to mlockall() your RT-processes!
Jan
PS: You only need "special" Xenomai services for allocating mem when you want to shared it between kernel and user land.
Quoted 3 lines · Jan Kiszka
Use mixed RT/non-RT threads and you will have shared mem for free, use processes and you only have to ask linux for some shared fragments. In any case don't forget to
mlockall()your RT-processes!
So does that mean regular shmget() to set up the shared memory, and mlockall() in the RT process? I was thinking mlock(), but you have a point that mlockall() would be better!
I haven't done shared memroy before, but it looks pretty easy.
Thanks,
-kb