On Sat, 27 Mar 1999, Pierre Cloutier wrote:

>   USER SPACE         SHMEM.                 RTL KERNEL
> 
>     stuff the buffer   ---->
>     soft int xx
[...]
>                                                                       int
> With this approach, ipc would bypass Linux completely.

Aaa, this is really clever...

Yes, RT-handler is not allowed to interfere with the rest of the kernel, so
most of standard checks done on syscall could be omitted. I first thought you
would end up copying most of syscall stuff, so why not use syscall which is
quite fast anyway (order of 2 us).

But: if the only thing you can do in RT-handler is doing some IO and
modifying some data in memory, why not do it in user space? You can get all
permissions to IO ports (iopl) and memory (mmap), you can ensure atomicity by
using hard cli() sti() in user space. I understand that operating in
unrestricted kernel environment is more convinient (you do not need to mmap
every data structure you want to change), but in principle the only thing
which _has_ to be done in kernel is servicing hardware interrupts (e.g.
periodic tasks). 

So, if you put all your RT module data structures in shared memory, and get
permission to ports you can do everything not entering the kernel at all. The
price would be code duplication and, some would say, less elegent solution. 

Your solution would work as well, but needs an expert to write software
interrupt support layer for RT-Linux first. But I do not know this side of
Linux kernel, so may be it is easier.

Best regards,
--
Tomek

--- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
----
For more information on Real-Time Linux see:
http://www.rtlinux.org/~rtlinux/

Reply via email to