lkml.org 
[lkml]   [2008]   [Jul]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Suggestion: LKM should be able to add system call for itself
On Mon, Jul 7, 2008 at 4:40 AM, Bart Van Assche
<bart.vanassche@gmail.com> wrote:
> On Mon, Jul 7, 2008 at 7:09 AM, Jinkai Gao <mickeygjk@gmail.com> wrote:
>> LKM(loadable kernel module) was first introduced for drivers. Users
>> rarely need to talk to the modules directly. If does, several methods
>> are available now, such as /proc file, interruption, etc. However,
>> these interfaces are predefined, which makes the communication between
>> user space and kernel space quite restricted.
>
> Did you already have a look at e.g. http://lwn.net/Kernel/LDD3/ for
> suggestions of alternatives for communication between userspace and
> kernel modules ? Alternatives to system calls are e.g. ioctl's, memory
> mapped I/O and sockets.

Yes, all kinds of alternatives exist. But they are alternatives
anyway, which are tricky ways to do things when you can't find a
reasonable ways. Actually,to communication between userspace and
kernel modules, all I need is a interface with two parameters, all the
system calls can be implemented out of that. So basically you can
write every system call using something like ioctl. But ioctl is not
designed for generic purpose after all.

Why the number of system calls is growing? because the kernel is
growing. why we don't use the alternatives to implement the new need
for system calls? Because it doesn't make any sense. We can't ignore
the kernel modules' need for system calls just because they are
loadable.


\
 
 \ /
  Last update: 2008-07-07 14:39    [W:1.683 / U:0.096 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site